Logo 
Search:

SQL Server Articles

Submit Article
Home » Articles » SQL Server » Configuration FunctionsRSS Feeds

@@TEXTSIZE - TEXTSIZE Function

Posted By: Sarita Patel     Category: SQL Server     Views: 1643

This article explains about @@TEXTSIZE function in sql server with examples.

@@TEXTSIZE function is used to get current value of TEXTSIZE option of the SET statement. It specifies maximum length of text or image data in bytes that a SELECT statement returns. The default size is 4096 bytes.


Syntax of @@TEXTSIZE Function :

@@TEXTSIZE

Return type of @@TEXTSIZE function is integer.



Examples of @@TEXTSIZE Function :

Example 1 : Use of @@TEXTSIZE function in select clause

SELECT @@TEXTSIZE

Output
2147483647

Above example returns max length of text or image data in bytes.



Example 2 : Use of @@TEXTSIZE function after setting TEXTSIZE variable value in select clause

SET TEXTSIZE 2147483640
SELECT @@TEXTSIZE

Output
2147483640

SET statement modifies TEXTSIZE variable value and @@TEXTSIZE displays it in select statement.
  
Share: 


Didn't find what you were looking for? Find more on @@TEXTSIZE - TEXTSIZE Function Or get search suggestion and latest updates.

Sarita Patel
Sarita Patel author of @@TEXTSIZE - TEXTSIZE Function is from United States.
 
View All Articles

Related Articles and Code:


 
Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

 
No Comment Found, Be the First to post comment!