in reply to Re: (jeffa) Re: weird DBI error re: parameter binding
in thread weird DBI error re: parameter binding

Sounds like your DBD doesn't handle [ and ] and so sees the ' as the start of a string literal and so doesn't consider the ? to be a placeholder.

                - tye
  • Comment on Re^3: weird DBI error re: parameter binding (guess)

Replies are listed 'Best First'.
Re: Re^3: weird DBI error re: parameter binding (guess)
by Grygonos (Chaplain) on Jul 30, 2003 at 19:14 UTC
    I tried escaping the ' but that didn't work. I agree it probably is the ' causing the problems. I know that Access can handle and because I use them all the time when people put spaces in field names i'm working with.

      Just to be clear, the DBD mostly doesn't need to "handle" [ and ] for them to just be passed along to the database to deal with and to "work".

      The problem is that the DBD code that looks for placeholder ?s knows to not grab ?s inside of quotes but doesn't (at appears) know that it should ignore quotes inside of square brackets.

      I doubt you can escape the single quote in a way that will both be understood by the DBD ?-finding code and correctly understood by the database. The DBD code needs to be enhanced to support this syntax.

                      - tye
        I think enhancing the code in such a way would support poor database naming conventions... I'm all for leaving it to break under those conditions.