I'm not 100% familiar with the load data line, I've never had to do it (I
just write import proggies :)
I'd suggest a small little script like this (copy and paste this into a text
file on the server, give it execute permissions, and run it), please excuse
any wrapping:
#!/bin/sh
for file in *.txt; do
if [ -f $file]; then
mysql --user=someuser --password=somepassword --execute="LOAD DATA
INFILE '$file' INTO TABLE db.table2 FIELDS TERMINATED BY '\t';
fi;
done
----- Original Message -----
From: "Marcus Ouimet" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, March 21, 2001 10:42 AM
Subject: Wildcard in Load Data?
> I am trying to load data from several lists. This is what I was trying:
>
> LOAD DATA INFILE '*.*' INTO TABLE table2 FIELDS TERMINATED BY '\t';
>
> For a single file I would have used:
>
> LOAD DATA INFILE 'data.txt' INTO TABLE table2 FIELDS TERMINATED BY '\t';
>
> Any ideas? I have several files that all change names so it would be
easiest
> just to have all the files in the dir loaded.
>
>
> ---------------------------------------------------------------------
> Before posting, please check:
> http://www.mysql.com/manual.php (the manual)
> http://lists.mysql.com/ (the list archive)
>
> To request this thread, e-mail <[EMAIL PROTECTED]>
> To unsubscribe, e-mail <[EMAIL PROTECTED]>
> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
>
>
>
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php