Wednesday, March 21, 2012

find the LENgth of a TEXT/NTEXT field

is this possible in T-SQL? (SQL Server 2000)
I want to find if the field is not null but empty (has no text in it).Use DATALENGTH.
--
Adam Machanic
Pro SQL Server 2005, available now
http://www.apress.com/book/bookDisplay.html?bID=457
--
"John Richardson" <j3richardson@.hotmail.com> wrote in message
news:eLQoiVWFGHA.4088@.TK2MSFTNGP10.phx.gbl...
> is this possible in T-SQL? (SQL Server 2000)
> I want to find if the field is not null but empty (has no text in it).
>
>|||thanks. can't believe I didn't see that.
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:ehe4oXWFGHA.344@.TK2MSFTNGP11.phx.gbl...
> Use DATALENGTH.
> --
> Adam Machanic
> Pro SQL Server 2005, available now
> http://www.apress.com/book/bookDisplay.html?bID=457
> --
>
> "John Richardson" <j3richardson@.hotmail.com> wrote in message
> news:eLQoiVWFGHA.4088@.TK2MSFTNGP10.phx.gbl...
>> is this possible in T-SQL? (SQL Server 2000)
>> I want to find if the field is not null but empty (has no text in it).
>>
>>
>

No comments:

Post a Comment