MySQL Forums
Forum List  »  Perl

What wrong with my DBI?
Posted by: luke Peng
Date: August 07, 2007 03:55PM

Hi All,
Can anyone give me a hand by finding where is the problem when call mysql from perl in a small program.

I just simply do the selection

$myquery = "SELECT * FROM $tablename";

it works fine. After I add the where clause

$myquery = "SELECT * FROM $tablename WHERE ligand_name = $l_name";

the $l_name = "UMT"; was defined.

A ERROR message pop out as follow

DBD::mysql::st execute failed: Unknown column 'UMT' in 'where clause' at /usr/lib/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi/Mysql.pm line 175.

Can anyone give me a hint what wrong?

Thanks

Luke



Edited 2 time(s). Last edit at 08/07/2007 04:02PM by luke Peng.

Options: ReplyQuote


Subject
Written By
Posted
What wrong with my DBI?
August 07, 2007 03:55PM
August 07, 2007 04:43PM
August 08, 2007 08:16AM
August 08, 2007 12:00PM
August 08, 2007 08:32AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.