469,156 Members | 2,172 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,156 developers. It's quick & easy.

LOAD DATA LOCAL INFILE and Perl DBI/DBD

HI all,

For the past several months we have been using LOAD DATA LOCAL INFILE to bulk load tables within
Perl modules.

Recently, someone thought it would be a good idea to upgrade the Solaris machines - I'm thinking it
wasn't that good an idea :-(

We are now running MySQL 4.0.18 and the DBI version is 1.35. Now, our scripts are failing with the
dreaded "The used command is not allowed with this MySQL version" message. Here's what I know at
the moment:

1. mysqld has local infile enabled.
2. mysql client can perform a LOAD DATA LOCAL INFILE
3. dbimon cannot perform a LOAD DATA LOCAL INFILE (same message as above).

So as I understand this, DBI is somehow not allowing the local option. I tried adding the
local_infile=1 option on the DSN, but that didn't help (if there was an error, it was silently
ignored).

Two questions:
1. How can I get the LOCAL option working?
2. How can I identify the source of the problem better so we don't waste more time in the future?

Thanks!

Jami

Jul 20 '05 #1
1 3793
As a workaround, we had to code the module to shell out to mysql and execute each of the (100)
commands. Obviously this is really slow because each command establishes a connection, executes,
then closes the connection.

Does anyone have any suggestions how we can get back to using DBI, this is driving me crazy :-)

Thanks!

Jami
On Wed, 23 Jun 2004 08:40:09 -0600, Jami Bradley <jb******@isa-og.com> wrote:
HI all,

For the past several months we have been using LOAD DATA LOCAL INFILE to bulk load tables within
Perl modules.

Recently, someone thought it would be a good idea to upgrade the Solaris machines - I'm thinking it
wasn't that good an idea :-(

We are now running MySQL 4.0.18 and the DBI version is 1.35. Now, our scripts are failing with the
dreaded "The used command is not allowed with this MySQL version" message. Here's what I know at
the moment:

1. mysqld has local infile enabled.
2. mysql client can perform a LOAD DATA LOCAL INFILE
3. dbimon cannot perform a LOAD DATA LOCAL INFILE (same message as above).

So as I understand this, DBI is somehow not allowing the local option. I tried adding the
local_infile=1 option on the DSN, but that didn't help (if there was an error, it was silently
ignored).

Two questions:
1. How can I get the LOCAL option working?
2. How can I identify the source of the problem better so we don't waste more time in the future?

Thanks!

Jami


Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Pieter Van Waeyenberge | last post: by
14 posts views Thread by Bruce A. Julseth | last post: by
3 posts views Thread by Otto | last post: by
reply views Thread by Donald Tyler | last post: by
reply views Thread by Rajesh Kapur | last post: by
1 post views Thread by Mortomer39 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.