php - phpMyAdmin SQL Error Unrecognized keyword near FIELDS -


i'm trying execute mysql import data csv file.

select * purchase purchase.po_date >= '1-1-2016' outfile "d:\\reports\\jan.csv" fields terminated ',' enclosed '"' lines terminated '\n' 

but i'm receiving output

static analysis:  11 errors found during analysis.      unrecognized keyword. (near "fields" @ position 99)     unrecognized keyword. (near "terminated" @ position 106)     unrecognized keyword. (near "by" @ position 117)     unexpected token. (near "','" @ position 120)     unrecognized keyword. (near "enclosed" @ position 125)     unrecognized keyword. (near "by" @ position 134)     unexpected token. (near "'"'" @ position 137)     unrecognized keyword. (near "lines" @ position 142)     unrecognized keyword. (near "terminated" @ position 148)     unrecognized keyword. (near "by" @ position 159)     unexpected token. (near "'\n'" @ position 162)  sql query: documentation  select * purchase purchase.po_date >= '1-1-2016' outfile "d:\\reports\\jan.csv" fields terminated ',' enclosed '"' lines terminated '\n'  

anyone knows how solve issue ?

the information regarding output file should specified between select , from clauses:

select * outfile "d:\reports\jan.csv" fields terminated ',' enclosed '"' lines terminated '\n'     purchase  purchase.po_date >= '1-1-2016' 

mysql 5.7 reference manual | load data infile syntax


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -