Code
Warning: mssql_query() [function.mssql-query]: message: Disallowed implicit conversion from data type varchar to data type money, table 'myLibrary.dbo.Lib_Transact', column 'Id_No'. Use the CONVERT function to run this query. (severity 16) in D:\AppServ\www\I_Library_Prajen\insertreserva.php on line 50
Warning: mssql_query() [function.mssql-query]: message: Disallowed implicit conversion from data type varchar to data type money, table 'myLibrary.dbo.Lib_Transact', column 'B8601'. Use the CONVERT function to run this query. (severity 16) in D:\AppServ\www\I_Library_Prajen\insertreserva.php on line 50
Warning: mssql_query() [function.mssql-query]: message: Disallowed implicit conversion from data type varchar to data type money, table 'myLibrary.dbo.Lib_Transact', column 'R8601'. Use the CONVERT function to run this query. (severity 16) in D:\AppServ\www\I_Library_Prajen\insertreserva.php on line 50
Warning: mssql_query() [function.mssql-query]: Query failed in D:\AppServ\www\I_Library_Prajen\insertreserva.php on line 50
Error Save [INSERT INTO Lib_Transact (TrnStatus,Category,Id_No,Title,Tme,MemberID,Clss,Rm,OfYear,OfMonth,B8601,R8601,BorrowDateC,ReturnDateC,OverDue,Remark,Lev,MemStatus) VALUES ('จอง','600','convert(money,33)','100 ความลับกับลมฟ้าอากาศ','','1977','','','2554','10','20111014','','14 ต.ค. 54','','','','','S')]
Code
$strSQL = "INSERT INTO Lib_Transact ";
$strSQL .="(TrnStatus,Category,Id_No,Title,Tme,MemberID,Clss,Rm,OfYear,OfMonth,B8601,R8601,BorrowDateC,ReturnDateC,OverDue,Remark,Lev,MemStatus) ";
$strSQL .="VALUES ";
$strSQL .="('$TrnStatus','$Category','$Id_No','$title','','$MemberID','','','$OfYear','$OfMonth','$B8601','','$BorrowDateC','','','','','$MemStatus')";
$objQuery = mssql_query($strSQL);Code (PHP)
Tag : PHP