Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
NayC
Starting Member
3 Posts |
Posted - 2009-06-04 : 04:38:05
|
Hi,I have been battling this for a few days now, lots of research etc, but to no prevail...I have a report with a main table and a little summary table, each with their own dataset, that returns all "contracts" and it requires a number of parameters. One of these parameters is a "multivalue" parameter which is for selecting particular contracts.There are 6 contracts (P1, P2, P3, P4, P5 &P6-9). When I run the report for induvidual contracts (one at a time) for the P3 or P4 contracts I get the two different error messages.P3 - Query Execution Failed. String or Binary data would be truncated.P4 - Query Execution Failed. Operation cancelled by user.Sometimes when I run P3 though, I get the same error message as P4. Now, my problem. All of the P1 - P6-9 contract have the same data formats and layout and everything, just different data. For just those two to fail is beyond me. When the reports are run for more than one contract, any of them can be run, so P3 and P4 could be run at the same time and have no problems whatsoever. Niether of the two tables will work on their own when trying to induvidually execute P3/P4 (remove one from the report, then try the other). This testing goes on and on.After running SQL Profiler, it doesn't have any signs of why it shouldn't work. It brings up execsql [Managed_Serv.....] then the code. If you take this into sql server it works fine. In the query designer in vs2008, no problems. Its only in the report itself. (Oh and FYI, I'm running text in the query designer becuase you cant use 'multivalue' parameters with a stored proc)After a lot of research there is nothing that seems to relate to me for these errors. Nothing useful found on "Operation Cancelled By User" (which most results are along the lines of SP permissions etc, which is not a problem) and for "String or Binary data would be truncated" moreso seems aimed at problems trying to put varchar(20) in to varchar(10) and errors along those lines.Sorry for the waffle. But does anyone have any ideas why I would get this? Anything new for me to try? Do you need any information about something?This has been bugging me and my senior for a few days...Thank you! (even for reading this much!) |
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2009-06-04 : 05:37:42
|
This error "P3 - Query Execution Failed. String or Binary data would be truncated." indicates you are trying to insert data into a table where a column can't hold the inserted data. E 12°55'05.63"N 56°04'39.26" |
|
|
NayC
Starting Member
3 Posts |
Posted - 2009-06-04 : 06:19:15
|
Exactly what I thought. And as I say, this is not a problem in SQL server, nor is this a problem in the query designer. Only a problem when trying to preview the report.But if i try preview the report showing me more than one contract at the same time, there is no problem. Only when P3 or P4 are previewed induvidually is there a problem. |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-06-04 : 13:42:46
|
are you using temporary tables in your query behind? it would be better if you could check them and see if they all have correct lengths specified for fields to hold data coming in |
|
|
|
|
|
|
|