Click here to Skip to main content
15,888,968 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I need to write a setup program for MySQL Server instillation and configuration using Inno script.

Here all other tasks works properly expect loading database!

C#
Filename: "msiexec.exe"; Parameters: "/i ""E:\Projects\mysql-5.5.11-win32.msi""/qn"; WorkingDir: {app}; StatusMsg: Please wait while we install Mysql 5.5.11;

Filename: "C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysqld.exe"; Parameters:" --install";WorkingDir: {app};StatusMsg: Installing MySQL Service;Flags: runhidden

Filename:net.exe; Parameters: start mysql; StatusMsg: Starting MySQL server; Description: Starting MySQL Server; Flags: runhidden

Filename:"C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysql.exe"; Parameters: "-e ""update mysql.user set password=PASSWORD('admin') where user='root';"" -u root"; WorkingDir: {app}; StatusMsg: Configuring MYSQL ; Flags: runhidden

Filename:"C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysql.exe"; Parameters:"mysql -uroot -e ""GRANT ALL PRIVILEGES ON *.* TO 'my03'@'localhost' IDENTIFIED BY '003' WITH GRANT OPTION""";StatusMsg:Create user account; Flags: runhidden waituntilterminated; 

Filename:"C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysql.exe"; Parameters: "-uroot -padmin -h localhost -e ""SOURCE C:\Users\Downloads\Sample-SQL-File-10-Rows.sql"""; WorkingDir: {app}; StatusMsg: Loading Database; Flags: runhidden


Please any one correct this! Thanks in Advance!

What I have tried:

Filename:"C:\Program Files (x86)\MySQL\MySQL Server 5.5\bin\mysql.exe"; Parameters: "-uroot -padmin -h localhost -e ""SOURCE C:\Users\Downloads\Sample-SQL-File-10-Rows.sql"""; WorkingDir: {app}; StatusMsg: Loading Database; Flags: runhidden


This the command for Loading Database what I have tried!
Posted
Updated 4-Apr-16 16:59pm
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900