﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / Integration Services / Data Warehousing  / String Expression 4000 characters limit / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Sat, 25 May 2013 21:17:23 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: String Expression 4000 characters limit</title><link>http://www.sqlservercentral.com/Forums/Topic1394667-364-1.aspx</link><description>Fortunately the 4000 character limit is an expression limitation, not a limitation of the number of characters in the string.  I have not done this personally but you might be able to break your expression down into parts and set a variable to each section.  For example Var1, Var2, Var3, SQLVar.  ThenVar1 = SELECT........Var2 = FROM.....Var3 = WHERE....SQLVar = Var1 + Var2 + Var3If that doesn't work the other way is to pull the query as suggested above from SQL built as a stored procedure, or from a column in a table that stores the entire query, and then set your variable value to the string returned.</description><pubDate>Tue, 11 Dec 2012 07:07:33 GMT</pubDate><dc:creator>Daniel Bowlin</dc:creator></item><item><title>RE: String Expression 4000 characters limit</title><link>http://www.sqlservercentral.com/Forums/Topic1394667-364-1.aspx</link><description>Replace the string expression with either a code object or a stored proceduring, depending on what you are trying to do with it.</description><pubDate>Mon, 10 Dec 2012 09:23:10 GMT</pubDate><dc:creator>GSquared</dc:creator></item><item><title>String Expression 4000 characters limit</title><link>http://www.sqlservercentral.com/Forums/Topic1394667-364-1.aspx</link><description>Hi all,   I have a query more than 4000 characters limit .I am setting with variables to the query.while i used the string expression i am getting error like string expression is limited to 4000 characters limit.Is any one have idea about how to eliminate the length limit in expression.</description><pubDate>Mon, 10 Dec 2012 08:50:48 GMT</pubDate><dc:creator>vasamsettipradeep</dc:creator></item></channel></rss>