problems with SELECT * INTO OUTFILE

    Date: 02/08/06 (MySQL Communtiy)    Keywords: mysql, sql

    Hello,

    I am having problems with the SELECT * INTO OUTFILE

    I have already ensured that:
    1) I have file access
    2) the folder is chmod 777
    3) the file does not already exist

    My code looks like this:
    $query="SELECT * INTO OUTFILE 'backup/$date.txt' FIELDS TERMINATED BY '\t' LINES TERMINATED BY '\n' FROM journal";
    $result=mysql_query($query) or die(mysql_error());
    if ($result) { echo "Backup file was created successfully!"; }

    This is what I get when I run the script:
    Can't create/write to file 'backup/07022006.txt' (Errcode: 2)

    Any help would be greatly appreciated. Thanks!

    Source: http://community.livejournal.com/mysql/85179.html

« mySQL/PHP question || MySQL Version issue with... »


antivirus | apache | asp | blogging | browser | bugtracking | cms | crm | css | database | ebay | ecommerce | google | hosting | html | java | jsp | linux | microsoft | mysql | offshore | offshoring | oscommerce | php | postgresql | programming | rss | security | seo | shopping | software | spam | spyware | sql | technology | templates | tracker | virus | web | xml | yahoo | home