MySQL Forums :: Perl :: MYSQL and Perl

Advanced Search

Re: MYSQL and Perl
Posted by: Randy Clamons ()
Date: June 05, 2012 11:14AM

Hi Johannes,

That's because you are only requesting the id in your select statement. The piece of code that assigns a value to $line[1] is missing here. I'm guessing it contains the name of the columnn to return.

The easy way to get the whole row is:

SELECT * FROM mytable

I don't like doing that as the code is ambiguous. So I will normally list every column I wish to retrieve, even when I am requesting all columns from the table.

Good Luck!


Options: ReplyQuote

Subject Written By Posted
MYSQL and Perl Johannes Schuller 06/05/2012 05:21AM
Re: MYSQL and Perl Randy Clamons 06/05/2012 11:14AM

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.