Microsoft
Software
Hardware
Network
Question : Query to find out greatest number of characters in a specified column
Can someone give me the syntax to write a query that will return the greatest number of characters in a specified column. Basically, I am in the process of converting a table's nChar fields and converting to nVarchar but want to check to make sure none of the columns I am converting are over nVarchar's max characters, 4000 characters.
Answer : Query to find out greatest number of characters in a specified column
select max(len(Field))
from table1
Substitur your field name in the "Field" place and then your table name instead of table1
Random Solutions
Help converting date format and pivot charting
"Grid Index out of range" errors at different screen resolutions
How do I force database mail in SQL Server 2005 to send e-mail in plain text instead of encoding it in base64?
How to create scheduled job using Query Analyzer
desktop settings
Verify input data from database via call to ASP
To httpd or to apachectl?? upgrade kills autostart
Assist Q. w/security: Deny Delete right on folder does not prevent deletion
Error about GETPLUSo.inf
Mrigrating from Exchange 2003 to Exchange 2007