473,387 Members | 1,416 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

LOAD DATA LOCAL INFILE revisited

Hello

i *had* it working ... i have everything in place as all documentation and
fora stated.. but yet i AGAIN get the error:

"The used command is not allowed with this MySQL version" in
/home/foo/public_html/goo/import.load.items.php on line..

LOAD DATA LOW_PRIORITY LOCAL INFILE
'/home/foo/public_html/goo/import/file.txt' REPLACE INTO TABLE discipline
FIELDS TERMINATED BY '{_^^)' LINES TERMINATED BY '\r\n' (col1,col2)
The context:

- PHP Version 4.3.8
- MySql: version - 4.0.17
- FreeBSD 4.9-RELEASE-p4 FreeBSD 4.9-RELEASE-p4 #1: Sun i386

- MySql has LOCAL_INFILE = On
- I connect to mysql using CLIENT_LOCAL_FLAGS: mysql_connect($host, $usr,
$pwd, false, 128);
- the open base dir is set to '/home/foo/'
- the directory 'import' where i get the file from has max permissions
- what i do in the app is: move the HTTP uploaded file to
'/goo/import/file.txt' ... (which is NOT the upload_tmp_dir) .. and then
later in another script i use the above sql statement
Am i missing something? help would be appreciated ..

thnx in advance ..
Pieter Van Waeyenberge
Jul 17 '05 #1
2 6323
GoL
On Tue, 17 Aug 2004 16:00:30 +0200, "Pieter Van Waeyenberge"
<p@foo.com> wrote:
Hello

i *had* it working ... i have everything in place as all documentation and
fora stated.. but yet i AGAIN get the error:

"The used command is not allowed with this MySQL version" in
/home/foo/public_html/goo/import.load.items.php on line..

LOAD DATA LOW_PRIORITY LOCAL INFILE
'/home/foo/public_html/goo/import/file.txt' REPLACE INTO TABLE discipline
FIELDS TERMINATED BY '{_^^)' LINES TERMINATED BY '\r\n' (col1,col2)
The context:

- PHP Version 4.3.8
- MySql: version - 4.0.17
- FreeBSD 4.9-RELEASE-p4 FreeBSD 4.9-RELEASE-p4 #1: Sun i386

- MySql has LOCAL_INFILE = On
- I connect to mysql using CLIENT_LOCAL_FLAGS: mysql_connect($host, $usr,
$pwd, false, 128);
- the open base dir is set to '/home/foo/'
- the directory 'import' where i get the file from has max permissions
- what i do in the app is: move the HTTP uploaded file to
'/goo/import/file.txt' ... (which is NOT the upload_tmp_dir) .. and then
later in another script i use the above sql statement
Am i missing something? help would be appreciated ..

thnx in advance ..
Pieter Van Waeyenberge


It's local-infile=1, not local_infile = on
unless I'm mistaken...?
Additionally, both client and server needs local-infile enabled.

Jul 17 '05 #2
sorry for my late response

on or 1 .. both still fail me ...

and both client (PHP) and server (Mysql) have it enabled ... so it still
dont work

Worse yet .. i installed PhpMyAdmin and even there on the import file func i
get the same errors bor both methods:

with and without LOCAL !!!!!!

pieter van waeyenberge
"GoL" <^^@**.com> wrote in message
news:gf********************************@4ax.com...
On Tue, 17 Aug 2004 16:00:30 +0200, "Pieter Van Waeyenberge"
<p@foo.com> wrote:
Hello

i *had* it working ... i have everything in place as all documentation andfora stated.. but yet i AGAIN get the error:

"The used command is not allowed with this MySQL version" in
/home/foo/public_html/goo/import.load.items.php on line..

LOAD DATA LOW_PRIORITY LOCAL INFILE
'/home/foo/public_html/goo/import/file.txt' REPLACE INTO TABLE discipline
FIELDS TERMINATED BY '{_^^)' LINES TERMINATED BY '\r\n' (col1,col2)
The context:

- PHP Version 4.3.8
- MySql: version - 4.0.17
- FreeBSD 4.9-RELEASE-p4 FreeBSD 4.9-RELEASE-p4 #1: Sun i386

- MySql has LOCAL_INFILE = On
- I connect to mysql using CLIENT_LOCAL_FLAGS: mysql_connect($host, $usr,$pwd, false, 128);
- the open base dir is set to '/home/foo/'
- the directory 'import' where i get the file from has max permissions
- what i do in the app is: move the HTTP uploaded file to
'/goo/import/file.txt' ... (which is NOT the upload_tmp_dir) .. and then
later in another script i use the above sql statement
Am i missing something? help would be appreciated ..

thnx in advance ..
Pieter Van Waeyenberge


It's local-infile=1, not local_infile = on
unless I'm mistaken...?
Additionally, both client and server needs local-infile enabled.


Jul 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Pieter Van Waeyenberge | last post by:
Hello i have most recent php & mysql versions running on a linuxmachine i want to use LOAD DATA LOCAL INFILE and pass it from php to mysql. - the file i load is given with full path and the...
14
by: Bruce A. Julseth | last post by:
When I execute this SQL statement in my PHP code, I get an error "File '.\Address.txt' not found (Errcode: 2)" $File = addslashes(".\Address.txt"); $SQL = "Load Data InFile \"" . $File . "\"...
3
by: Otto | last post by:
Hello to all I have a problem how to write correctly a PHP string. I did the following import with the help of PHPMyAdmin: Nombre d'enregistrements insérés : 364 (traitement: 0.0553 sec.)...
0
by: Donald Tyler | last post by:
Then the only way you can do it that I can think of is to write a PHP script to do basically what PHPMyAdmin is trying to do but without the LOCAL in there. However to do that you would need to...
1
by: Jami Bradley | last post by:
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...
0
by: Rajesh Kapur | last post by:
Hello, I am running MySQL 4.0.16. I get the error 'The used command is not allowed with this MySQL version' when using the 'load data local infile' command. The local_infile is ON; the select *...
1
by: Ray in HK | last post by:
What are the differences between LOAD DATA INFILE and LOAD DATA LOCAL INFILE ? I found some web hosting company do not allow using LOAD DATA INFILE but allow LOAD DATA LOCAL INFILE. The reason...
3
by: nsh | last post by:
mailing.database.mysql, comp.lang.php subject: does "LOAD DATA" EVER work?!? I've tried EVERYTHING! version info: my isp is running my web page on a linux box with php ver. 4.4.1 according to...
1
by: Megi | last post by:
welcome, I input data form file to mysql with command: load data local infile.. The efect is that the data are duplicated or trippled..etc with every re-loading the script, but I need to load...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.