List:General Discussion« Previous MessageNext Message »
From:Mark Matthews Date:October 26 2002 12:09am
Subject:Re: Mysql Innodb performance slow
View as plain text  
Jeff Mathis wrote:
> forgive me.
> i was initially using the perl DBI methods to load. I am not intimately
> familiar with the inner workings of DBI, but obviously it must be doing
> something if you say mysql does not support binding variables
> (i am using 4.0.4). This is significantly faster than creating a new
> prepared statement for every insert.
> I'm now using JDBC, and havne't explored this yet. I'm coming from the
> Oracle camp, and have only been using mysql for less than a month. so
> far, i find it very snappy. I do miss the ability to have stored
> procedures, triggers and views however.
> jeff 
> Dan Nelson wrote:
>>Note that mysql does not support bind variables.  If you think you're
>>using them, whatever API you are using is filling them in before
>>sending the statement to mysql.  Bind variables do solve quoting
>>problems, though, so if you use them, know why you're using them :)
>>        Dan Nelson
>>        dnelson@stripped

Dan speaks the truth. However, using bind variables also proves that 
you're forward-looking as MySQL-4.1 will have prepared statements with 
'real' bound parameters, so your code will run that much faster then.

The quoting problem is a valid point, and in fact I always prescribe it 
as dynamic SQL is the root of many an exploit in database applications, 
especially web-based ones.


For technical support contracts, visit

     __  ___     ___ ____  __
    /  |/  /_ __/ __/ __ \/ /  Mark Matthews <mark@stripped>
   / /|_/ / // /\ \/ /_/ / /__ MySQL AB, Full-Time Developer - JDBC/Java
  /_/  /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA

Mysql Innodb performance slowJeroen Geusebroek25 Oct
  • Re: Mysql Innodb performance slowRichard Clarke25 Oct
  • Re: Mysql Innodb performance slowJeff Mathis26 Oct
    • Re: Mysql Innodb performance slowDan Nelson28 Oct
  • Re: Mysql Innodb performance slowJeff Mathis26 Oct
    • Re: Mysql Innodb performance slowPaul DuBois27 Oct
  • Re: Mysql Innodb performance slowMark Matthews26 Oct
    • Re: Mysql Innodb performance slowDavid Lloyd26 Oct
  • Re: Mysql Innodb performance slowMark Matthews27 Oct
RE: Mysql Innodb performance slowJeroen Geusebroek26 Oct
  • Re: Mysql Innodb performance slowMark Matthews26 Oct