Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: General / Classic ASP versions(v3.4.XX)
 How can I determine length of topic T_MESSAGE?
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

bbraman
New Member

55 Posts

Posted - 18 July 2003 :  19:51:22  Show Profile
Does anyone know the SQL syntax to determine what the longest T_MESSAGE field of table FORUM_TOPICS is?

I tried:
select len(T_MESSAGE) from FORUM_TOPICS

But got the error:
Server: Msg 8116, Level 16, State 2, Line 1
Argument data type text is invalid for argument 1 of len function.

My web hosting provider won't sell me any more SQL Server 2000 space and I need to determine what messages are my biggest space wasters.

bbraman
New Member

55 Posts

Posted - 18 July 2003 :  19:53:21  Show Profile
Found my answer here:
http://www.sqlteam.com/item.asp?ItemID=5054

The Datalength() function will return the length of any expression. This can be used on all data types including text, ntext, image and varbinary.
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 19 July 2003 :  02:09:31  Show Profile
You can also use

Topic_Size =  rsTopic("T_MESSAGE").ActualSize
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.25 seconds. Powered By: Snitz Forums 2000 Version 3.4.07