globalterminal
asked on
stored procedure
i am having trouble gettting a stored procedure to work. Using the following code i get this error:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E37)
[IBM][Client Access Express ODBC Driver (32-bit)][DB2/400 SQL]SQL7967 - PREPARE of statement QZ92D3E2CF9BFB1000 completed.
this is the code..its failing on the Execute statement.
Dim rsRETax,NewConnxRETax,NewC ommandxRET ax
set NewConnxRETax = server.CreateObject("ADODB .Connectio n")
NewConnxRETax.Open "test","gblodbc","odbcgbl"
set NewCommandxRETax = server.CreateObject ("ADODB.Command")
set NewCommandxRETax.ActiveCon nection = NewConnxRETax
NewCommandxRETax.CommandTe xt = "getOpenDvirByChassis"
NewCommandxRETax.CommandTy pe = 4
NewCommandxRETax.Parameter s.Append NewCommandxRETax.CreatePar ameter("te rm-code",2 00,1,30)
NewCommandxRETax.Parameter s.Append NewCommandxRETax.CreatePar ameter("ch assis-numb er",200,1, 30)
NewCommandxRETax("term-cod e") = "GBLDEV"
NewCommandxRETax("chassis- number") = "APLZ330211"
set rsRETax = NewCommandxRETax.Execute
set rsRETax = rsRETax.NextRecordset()
While not rsRETax.eof
Response.Write "*" & rsRETax(0) & "*" & rsRETax(1) & "<br>"
rsRETax.MoveNext
Wend
Microsoft OLE DB Provider for ODBC Drivers (0x80040E37)
[IBM][Client Access Express ODBC Driver (32-bit)][DB2/400 SQL]SQL7967 - PREPARE of statement QZ92D3E2CF9BFB1000 completed.
this is the code..its failing on the Execute statement.
Dim rsRETax,NewConnxRETax,NewC
set NewConnxRETax = server.CreateObject("ADODB
NewConnxRETax.Open "test","gblodbc","odbcgbl"
set NewCommandxRETax = server.CreateObject ("ADODB.Command")
set NewCommandxRETax.ActiveCon
NewCommandxRETax.CommandTe
NewCommandxRETax.CommandTy
NewCommandxRETax.Parameter
NewCommandxRETax.Parameter
NewCommandxRETax("term-cod
NewCommandxRETax("chassis-
set rsRETax = NewCommandxRETax.Execute
set rsRETax = rsRETax.NextRecordset()
While not rsRETax.eof
Response.Write "*" & rsRETax(0) & "*" & rsRETax(1) & "<br>"
rsRETax.MoveNext
Wend
You are connecting to an AS400?
ASKER
yes as400
ASKER
commenting out that line:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
[IBM][Client Access Express ODBC Driver (32-bit)][DB2/400 SQL]SQL0104 - Token GETOPENDVIRBYCHASSIS was not valid. Valid tokens: ( END GET SET CALL DROP FREE HOLD LOCK OPEN.
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
[IBM][Client Access Express ODBC Driver (32-bit)][DB2/400 SQL]SQL0104 - Token GETOPENDVIRBYCHASSIS was not valid. Valid tokens: ( END GET SET CALL DROP FREE HOLD LOCK OPEN.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
NewCommandxRETax.CommandTy