Greetings,

I am trying to read a message from MQ series in perl and want to
update SYbase with this message. Even though ,the update when directly
run from command line, works fine. However, if I try to execute my
perl script, I get an error saying "Database Error Message received
'DBD::Sybase
::st execute failed: Server message number=105 severity=15 state=2
line=1 server=S02TRS0 text=Unclosed quote before the character string
'231126407354223055'."

Below is the code snippet.


 my $msgDescRef = $MsgObj->MsgDesc;
        my $UniqMsgTag = $$msgDescRef{"CorrelId"};
        log ("UniqueTag is $UniqMsgTag"); # This variable has value
231126407354223055
$UniqTag ="$UniqMsgTag";
my $sql="update my_table set UniqueTag='$UniqMsgTag' where id=123";
RunSql("$sql"); # This a function which executes the query using DBI

Kindly suggest on how to resolve this issue.

TIA


-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to