Wednesday, July 8, 2009

Field Length

This formula may be necessary when you're dealing with a tool (e.g. Dashboard tool) that has limits to the character lengths that it can read. You may want to be proactive in identifying potential problems.

Using the SQL Server Northwind Traders Sample Database:

SELECT

ProductID,

ProductName,

FieldLength = len(ProductName)

FROM Northwind.dbo.Products

where len(ProductName) >57

No comments:

Post a Comment