Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Answer: Why does my query work on the command line, but fail in my browser?

by cavac (Deacon)
on Jul 15, 2012 at 21:57 UTC ( #981937=categorized answer: print w/replies, xml ) Need Help??

Q&A > database programming > Why does my query work on the command line, but fail in my browser? - Answer contributed by cavac

The query

INSERT member (last, first) VALUES(NULL, "chromatic");
also uses double quotes. Most databases either don't accept that, or interpret it in some other way (like PostgreSQL, which uses it to indicate that column name or table name is case sensitive.

This is especially problematic when you just copy the whole string from whatever tool you use to test the queries into Perl.

  • Comment on Answer: Why does my query work on the command line, but fail in my browser?
  • Download Code
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (4)
As of 2018-06-20 02:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?



    Results (116 votes). Check out past polls.

    Notices?