Solved

Multiplevel parameter using Splitlist error

Posted on 2011-03-23
2
621 Views
Last Modified: 2012-05-11
in my stored procedure i use splitlist.  but for some multiple selections it gives result. but if clicks select all it gives  error INVALID LENGTH PARAMETER  PASSED TO LEFT or SUBSTRING FUNCTION.

and (itemgroupid in (SELECT FieldName FROM SplitList(@itemgroupid,',')) and  (salesoriginid in (SELECT FieldName FROM SplitList(@salesoriginid,',')) and (CustomerCode in (SELECT FieldName FROM SplitList(@Cust,','))
and (dimension2_ in (SELECT FieldName FROM SplitList(@CC,','))
and (dimension3_ in (SELECT FieldName FROM SplitList(@Purpose,','))
0
Comment
Question by:AnnaJames77
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 16

Accepted Solution

by:
Imran Javed Zia earned 250 total points
ID: 35196911
It seems,  you are passing null or empty string, or make sure your parameter data is not ending or starting with "," comma.
Thanks
0
 
LVL 3

Assisted Solution

by:Emenizer
Emenizer earned 250 total points
ID: 35196919
Check this post on problems with this function: http://www.tek-tips.com/viewthread.cfm?qid=1563833&page=1
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Naughty Me. While I was changing the database name from DB1 to DB_PROD1 (yep it's not real database name ^v^), I changed the database name and notified my application fellows that I did it. They turn on the application, and everything is working. A …
A recent question popped up and the discussion heated up regarding updating a COMMENTS (TXT) field in a table using SSRS. http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/MS-SQL_Reporting/Q_27475269.html?cid=1572#a37227028 (htt…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question