USE PUBS
SELECT MAX(DATALENGTH(title)) as TextLength FROM titles
In order to print the longest text in a descending order of the length of text, here's how to do so:
USE PUBS
SELECT title, DATALENGTH(title) as TextLength FROM titles
group by title
order by TextLength desc
Useful post.
ReplyDeleteRegards!
Agustin.