must remember to turn debugging on...

: )

  ----- Original Message -----
  From: Barney Boisvert
  To: CF-Talk
  Sent: Friday, December 05, 2003 12:01 PM
  Subject: RE: Debugging CFQUERYPARAM

  The complete SQL (along with the paramter values) is shown in the debugging
  output.  The SQL (without params) is shown in the default CF error message
  if the query causes a database error.

  The combination of the two parts happens inside the database, long after the
  SQL has been parsed and turned into whatever the DB uses internally to
  represent query instructions.  That's one of the benefits of using query
  parameters, because it means that the SQL only has to be parsed once, rather
  than every time you pass different variables.

  Cheers,
  barneyb

  > -----Original Message-----
  > From: Charlie Griefer [mailto:[EMAIL PROTECTED]
  > Sent: Friday, December 05, 2003 10:46 AM
  > To: CF-Talk
  > Subject: Re: Debugging CFQUERYPARAM
  >
  > The benefits of <cfqueryparam> are worth the few drawbacks, IMO.  
  > But I do agree that it would be VERY nice if there were some
  > way to dump the SQL to see exactly what's being passed to the
  > database.
  >
  > At least without cfqueryparam you could throw your SQL
  > statement into a <cfoutput> block.  AFAIK, there's no real
  > way to get a peek at the 'raw' SQL that's going to the DB
  > whilst using <cfqueryparam> :(
  >
  > charlie
  >
  >   ----- Original Message -----
  >   From: Rick Root
  >   To: CF-Talk
  >   Sent: Friday, December 05, 2003 11:32 AM
  >   Subject: Re: Debugging CFQUERYPARAM
  >
  >
  >   Charlie Griefer wrote:
  >
  >   > The thread Tom's referring to can be found at
  >   >
  > http://www.mail-archive.com/[EMAIL PROTECTED]/msg157166.html
  >   >
  >   > Based on that, Sam Neff was good enough to put together
  > the following
  >   > page, http://www.blinex.com/~sam/CF_SQL_TYPES.cfm , that displays
  >   > cfsqltypes with their corresponding datatypes in various
  > databases.
  >
  >   DAmn, and no mention of MySQL (except where someone said
  > MySQL users
  >   would bitch about it).  And since I'm using CF 5.0 still,
  > I'm not using
  >   JDBC drivers either.
  >
  >   > As far as your error message, below...the obvious
  > question to ask (and
  >   > sorry to do it, but you know it has to be asked) is...you
  > have a few
  >   > empty values.  does your database accept null
  > values/empty strings for
  >   > those columns?
  >
  >   As someone else has mentioned... MySQL doesn't enforce NOT NULL...
  >   (which I didn't even know)... but the columns do all allow
  > NULL values...
  >
  >   So it looks like the only way of debuggin this is to go through the
  >   query... field by field... and see which one it is failing
  > on.  Durn it.
  >     That's pretty lame.
  >
  >   Coldfusion is supposed to protect us from having
  > database-specific code
  >   in our applications, and yet it seems like CF_SQL_TYPE is
  > very database
  >   specific.
  >
  >     - Rick
  >
  >
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to