Ticket #438 ( Closed )

Short Description ODBC
Entered By: gaucho When: 2000-02-07 12:20:54 Build: 2.0.7A GA
Categories Type: Question   Department: Product   Category: Not Categorized
Description
Hi Bill,

I'm having trouble doing an INSERT.  I'm trying to pull a 
record out of a DB and then insert data that relates to 
that particular record.

Here is my code:
*****
<TEDECLARE DBSELECT
	NAME="GetPerm"
	DBSOURCE="UserTracking"
	SQL="Select * from tbUserTracking where Perm = ?I">

<TEDECLARE DBCOMMAND
	NAME="InsertPerm"
	DBSOURCE="UserTracking"
	SQL="INSERT INTO tbUserTracking(Perm, Browser) 
values(?I, ?C(60))">	

<TEDECLARE DBCOMMAND
	NAME="InsertCounter"
	DBSOURCE="UserTracking"
	SQL="INSERT INTO tbUserTracking(LogonCounter) values
(?I) where Perm = PERM">
*******
<TEFETCH
	SELECT="GetPerm" PERM>
<TEIF GetPerm.SqlCode=0>
<TESHOW getperm.Perm> <TESHOW GetPerm.LogonCounter>
<TESET ADDCOUNTER=GetPerm.LogonCounter+1>
<TESHOW ADDCOUNTER>
<TEDBEXEC COMMAND="InsertCounter" ADDCOUNTER>
*******


THis is th