Topic
  • 4 replies
  • Latest Post - ‏2014-05-28T19:58:28Z by rolandq
rolandq
rolandq
3 Posts

Pinned topic Receiving Error Writing String to Database.

‏2014-05-27T19:13:47Z |

I'm receiving error:

Description Resource Path Location Type
Database error (state=22001 code=0): [Microsoft][SQL Server Native Client 10.0]String data, right truncation, near "Results". 1828fromDB.dat /MBOPilot 24:126-127 C:\Users\Roland\opl\MBOPilot\1828fromDB.dat OPL Problem Marker

Results here is a set of tuples where two components are strings.

Results = {<d,c,k,e,Assigned[<d,c,k,e>]> | <d,c,k,e> in DCKE};  

If I remove the string values, OPL will write the integer and float values to a database without a hiccup. And I've seen in similar threads that some people resolved the issue by setting dbUpdateBatchSize to 1, but this does not work for me.

It looks like the issue was resolved offline for a couple users:

https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014962178&ps=25

https://www.ibm.com/developerworks/community/forums/html/topic?id=d9123a90-48e3-4bb0-91b2-6a1c96dafc39&ps=25 

I'd rather avoid the roundabout technique of enumerating each of the strings and running with all ints since we are trying to keep our preprocessing of the data to a minimum. 
Could someone please help with a solution to this issue? Your help would be much appreciated, thank you.

 

Updated on 2014-05-27T19:17:42Z at 2014-05-27T19:17:42Z by rolandq
  • AlexFleischer
    AlexFleischer
    1708 Posts
    ACCEPTED ANSWER

    Re: Receiving Error Writing String to Database.

    ‏2014-05-28T19:49:35Z  
    • rolandq
    • ‏2014-05-28T16:11:46Z

    Hi Alex,

    I'm running through the IDE CPLEX Studio version 12.3.0 64-bit on Windows 7 

     

    Thank you

     

     

    Hi

    so you should move from 12.3 to 12.6

    regards

  • AlexFleischer
    AlexFleischer
    1708 Posts

    Re: Receiving Error Writing String to Database.

    ‏2014-05-28T07:11:02Z  

    Hi,

    which CPLEX version are you using ?

    regards

  • rolandq
    rolandq
    3 Posts

    Re: Receiving Error Writing String to Database.

    ‏2014-05-28T16:11:46Z  

    Hi,

    which CPLEX version are you using ?

    regards

    Hi Alex,

    I'm running through the IDE CPLEX Studio version 12.3.0 64-bit on Windows 7 

     

    Thank you

     

     

    Updated on 2014-05-28T16:26:50Z at 2014-05-28T16:26:50Z by rolandq
  • AlexFleischer
    AlexFleischer
    1708 Posts

    Re: Receiving Error Writing String to Database.

    ‏2014-05-28T19:49:35Z  
    • rolandq
    • ‏2014-05-28T16:11:46Z

    Hi Alex,

    I'm running through the IDE CPLEX Studio version 12.3.0 64-bit on Windows 7 

     

    Thank you

     

     

    Hi

    so you should move from 12.3 to 12.6

    regards

  • rolandq
    rolandq
    3 Posts

    Re: Receiving Error Writing String to Database.

    ‏2014-05-28T19:58:28Z  

    Hi

    so you should move from 12.3 to 12.6

    regards

    Cool, thanks