How To Update oracle data from php, by using 'Commit' ? [message #541174] |
Sun, 29 January 2012 02:46 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
|
dear everybody,
I want to ask something that make me confuse. About work using PHP n Oracle together.
I want to update an existing data on oracle table. I use this script:
//connect to database
$conn=ora_logon("hr","hr");
$cur=ora_open($conn);
$no_dept=$_POST['no_dept'];
$nm_dept=$_POST['name_dept'];
ora_parse($cur, "update departement set nm_dept='$nm_dept' where no_dept='$no_dept'");
ora_exec($cur);
Going well, without error. But, when I go back to index.php which showing fetching data from department table. The data which I have updated doesn't change. I think it needs 'COMMIT'. But how I use it on PHP??
Please help your Junior.
Thanks for your response. ![Very Happy](images/smiley_icons/icon_biggrin.gif)
Regards,
widia.
|
|
|
|
|