problem with mysql export to file in c# -



have problem mysql+c# in mysql export operation.

folderbrowserdialog fol=new folderbrowserdialog(); if (fol.showdialog() == dialogresult.ok) {    string path= fol.selectedpath;    string sql = "select * outfile '" + path+ "\person.csv' fields terminated by',' optionally enclosed '\"' lines terminated '\n' tpers ";    mysqlcommand daa = new mysqlcommand(sql, conn);    conn.open();    daa.executenonquery();    conn.close();                               } 

for example
path = "c:\export"
when execute code doesnt export person.csv intended path.
creates "c:export\person.csv" file , creates file in mysql/data folder..
can u explain problem, , how fix it...

i solved problem..

string path = fol.selectedpath; path = path.replace("\\","/"); ... 

after program works correctly...


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -