CHeighlund
Programmer
I have a rather unusual problem with a webform I'm working on, and I'm hoping someone here can point me to what it is I'm doing wrong.
Code segment going weird:
$KEY is the value of a foreign key, generated earlier in the page then immediately called back up to fill the variable.
I have a database set up to receive the results of the page. I'm getting constant 'could not complete query' errors when I try to submit the information, but I have no problem inserting it into the database when I manually copy it from the page (the reason for the echo line).
structure of int_form:
Would someone please suggest what I might be doing here that's causing these problems, or at least something I can look into on them?
Code segment going weird:
Code:
$SQL_INTERIOR = "insert into int_form values ('$KEY', '$IntScore', $T1X1, $T1X2, $T1X3, $T1X4, $T1X5, $T1X6, $T1X7, default, default);";
echo "<br/>$SQL_INTERIOR<br/>";
$result1 = @pg_query($connect,$SQL_INTERIOR) or die("could not complete query interior");
$KEY is the value of a foreign key, generated earlier in the page then immediately called back up to fill the variable.
I have a database set up to receive the results of the page. I'm getting constant 'could not complete query' errors when I try to submit the information, but I have no problem inserting it into the database when I manually copy it from the page (the reason for the echo line).
structure of int_form:
Code:
Column | Type | Modifiers
----------+----------------------+---------------
rcrd_key | integer |
score | character varying(3) |
item1 | boolean | default false
item2 | boolean | default false
item3 | boolean | default false
item4 | boolean | default false
item5 | boolean | default false
item6 | boolean | default false
item7 | boolean | default false
item8 | boolean | default false
item9 | boolean | default false
Foreign-key constraints:
"int_form_rcrd_key_fkey" FOREIGN KEY (rcrd_key) REFERENCES survey_form(form_key)
Would someone please suggest what I might be doing here that's causing these problems, or at least something I can look into on them?