I would like to be able to run a query that checks for a certian amount of characters in a field. Here is the psuedo code.
select *
from table1
where field1 contains less then 5 characters.
The DATALENGTH function counts all characters in the column.
select *
from table1
where datalength(field1)>=5
The LEN function will not count the trailing spaces.
select *
from table1
where len(field1)>=5 Terry L. Broadbent FAQ183-874 contains tips for posting questions in these forums.
NOTE: Reference to the FAQ is not directed at any individual.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.