I am new to php and have started some coding.I want to insert values in one table1 and update values of table2.
It worked for me last day..but today it doesnt work.I have hardly changed any code.i guess except fr deleting some comments in code..u plz tell me if this thing works.
//line1 $sql="UPDATE table1 SET col2=$p WHERE col1=$p AND col2 IS NULL"; //line2 $sql="INSERT INTO user(u_id,u_uname, u_fname, u_lname) VALUES ($q,'$username','$fname','$lname')"
i tried to see which statement works in sequence..i found that the line 2 statement works in any case even if u swap the statements..means line 1 statement will work if u swap it with line 2.It worked fine last day.insertion and updates were performed easily..plz help..y this happens? is it bcoz of same variable $sql used to catch return values?
Edited by diafol: Use code tags