in reply to Returning a single record

There is so much wrong with this question -- let us begin at the begine...

  1. Read formatting tips
  2. Don't include more code than necessary to ask the question.
  3. State the error properly
Now, wrt your question -- what error do you get? You say in a later email that you get more than one record. Well, then how about changing your SQL query so that it asks the database the correct question.

See, suddenly your question is no longer a Perl question but a SQL question... all that extra html code and DBI connection info is just confusing and takes up space. The long code line (you have likely used the <pre> tags instead of the code tags) is screwing up my browser window (I hate horizontal scroll bars).

--
when small people start casting long shadows, it is time to go to bed