Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
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 surveying the Monastery: (3)
As of 2016-12-06 03:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (98 votes). Check out past polls.