| | |
query executes and return correct value but cudnt save one value into db
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Dec 2008
Posts: 6
Reputation:
Solved Threads: 0
lines of code is:
whr query returns :
as u see 'Answer_Type' in query returns value 'Yes' but i cudnt see it into table...whr into databse 'Answer_Type' has datatype 'enum'
php Syntax (Toggle Plain Text)
$que_id = uniqid(); $que['Yes'] = No; $que['No'] = No; $que[$_POST['r1']] = Yes; $que_words1= $_POST['q1']; $sql = "INSERT INTO `tbl_CT_Questions` (`Question_ID`,`Questionnaire_ID`,`Question_Words`,`Answer_Type`) VALUES (0,'".$que_id."','".$que_words1."','".$que[$_POST['r1']]."')"; $result = mysql_query($sql) or die(mysql_error()) ; echo mysql_error(); echo $sql; echo "<br>";
whr query returns :
sql Syntax (Toggle Plain Text)
INSERT INTO `tbl_CT_Questions` (`Question_ID`,`Questionnaire_ID`,`Question_Words`,`Answer_Type`) VALUES (0,'494220e779547','Conflicts Questionnaire','Yes')
as u see 'Answer_Type' in query returns value 'Yes' but i cudnt see it into table...whr into databse 'Answer_Type' has datatype 'enum'
Last edited by peter_budo; Dec 12th, 2008 at 6:54 am. Reason: Keep It Organized - For easy readability, always wrap programming code within posts in [code] (code blocks) and [icode] (inline code) tags.
![]() |
Other Threads in the PHP Forum
- Previous Thread: download, install & redirect
- Next Thread: Some1 who know how can I put PTC site info into a banner???
| Thread Tools | Search this Thread |
advanced apache api array basics beginner binary broken cakephp check checkbox class cms code combobox cookies cron curl database date datepart display dynamic echo email error file files folder form forms function functions google head href htaccess html image include includingmysecondfileinthechain insert ip javascript job joomla js limit link login mail menu mlm mobile multiple mysql oop outofmemmory paging parse password paypal pdf php problem procedure query radio random recursion regex remote script search server sessions smarty sms soap source space sql stored syntax system table traffic tutorial unicode up-to-date update upload url validator variable video web webapplications xml youtube





