Restore Mysql Database

shuvo009

New member
Joined
Nov 9, 2009
Messages
1
Programming Experience
Beginner
i am tried to restore mysql database using vb.net 2008. i am try this command in mysql command line it work well.
"mysql -u username -ppassword < C:\test.sql"
but when i do it vb.net when i got error. Here is code that i use



Dim process As New Process
process.StartInfo.FileName = "C:\Program Files\MySQL\MySQL Server 5.1\bin\mysql.exe"
process.StartInfo.Arguments = "-u root -p123456 < c:\player.sql"
process.StartInfo.UseShellExecute = False
process.StartInfo.RedirectStandardInput = True
process.StartInfo.RedirectStandardOutput = True

process.StartInfo.CreateNoWindow = True
process.Start()
process.StandardInput.Write("root")
TextBox1.Text = process.StandardOutput.ReadToEnd
process.WaitForExit()

please help me. i am not good in english. than u
 
Back
Top