PDA

View Full Version : مشکل در بروز رسانی



msafvati
دوشنبه 24 دی 1386, 15:32 عصر
با سلام
من در بروز رسانی مقادیر موجود در دیتابیسم دچار مشکل شدم و با این هشدار روبه رو شدم.
دوستان اگه امکان داره راهنمایی کنند
با تشکر



<?php
$new_Edu=$_GET['txt1'];
$new_Back=$_GET['txt2'];
$new_Otherskiils=$_GET['txt3'];
$new_Age=$_GET['txt4'];
$new_Tell=$_GET['txt5'];
$SqlUpdate="UPDATE tblReguser SET Background = '$new_Back' , Otherskills = '$new_Otherskiils' , Age = '$new_Age' , Tell = '$new_Tell' where Edu = '$new_Edu'";
$connectionstring=odbc_connect("user","","");
odbc_do($Sqlupdate,$connectionstring) or die("Error".odbc_errormsg());
echo "Record successfully updated!";
odbc_close($connectionstring);

?>


warning is:
Warning: odbc_do(): supplied argument is not a valid ODBC-Link resource in D:\MAS\Prj2\Local path\MASUdate\Update.php on line 249
Error

cybercoder
دوشنبه 24 دی 1386, 16:18 عصر
$SqlUpdate!=$Sqlupdate

علاوه بر اون وقتی از سینگل کوتیشن استفاده کنی باید رشته ها رو به هم ملحق کنی


"UPDATE tblReguser SET Background = '".$new_Back."...

msafvati
دوشنبه 24 دی 1386, 16:54 عصر
با سلام
ممنونم از راهنماییتون اما کد اولی رو که نوشتین من متوجه نشدم امکان داره بیشتر توضیح بدین؟

musiox
دوشنبه 24 دی 1386, 18:20 عصر
resource odbc_do ( resource conn_id, string query )
اشکال اینه