var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Populating Mysql Database multiple insert problem
I am trying to populate mysql database from an existing Access Database.
I have created a file like this :
Insert into Students (BS_Id,Firstname,Lastname,Username,Password,Nation ality,Email) Values (5,'???','???','???',PASSWORD('???'),'?????','');
Insert into Students (BS_Id,Firstname,Lastname,Username,Password,Nation ality,Email) Values (6,'???','???','???',PASSWORD('???'),'?????','');
now i have been tryng to run the file from php but without success !
I have used
$FILE = fopen($filennname,"r");
while ($query = fgets($FILE,4096))
echo "$query <p><p><p>";
#$result = func_query($query);
fclose($FILE); // close file
thought the query is correct only the first line is inserted
Can anyone help ?
Try using the following instead of the while loop you are currently using:
At the end the variable $query has all the commands in file and u can echo them, or whatever....
while (!feof ($FILE))
I guess may be the problem is with while loop's condition. I am not quite sure, but there's nothing to loose in trying And in case, I am right, do let me know