469,306 Members | 2,281 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,306 developers. It's quick & easy.

Asp using the Oracle procedure call error

My system is on a NT4 (w/SP6a) running IIS 4.
I am developing a page that query one record from my Oracle DB 8.1.6 on
a separate machine. I am using the MS ODBC for Oracle drive. In my
ASP page I have
(Connection object has been crreated.)

LnDetail = "{ call IPV$po.getPOLine(?,?, {resultset 1, "& _
" p_orderType, p_orderID, p_reqNum, p_nsn, "& _
" p_reqStatus, p_priceStatus, p_errFlag, p_errMsg})}"

Set poComm = Server.CreateObject("ADODB.Command")
Set poComm.ActiveConnection = connect
poComm.CommandText = Lndetail
poComm.CommandType = adCmdText
set poDetail = Server.CreateObject("ADODB.Recordset")
poDetail.CursorType = adOpenStatic
poDetail.LockType = adLockReadOnly
set poDetail.Source = poComm
poComm(0) = Trim(poID)
poComm(1) = Trim(poLine)

And my PL/SQL procedure called

p_poLine IN VARCHAR2,
p_orderType OUT po_lines.order_type%TYPE,
p_orderID OUT po_lines.order_id%TYPE,
p_reqNum OUT po_lines.req_num%TYPE,
p_reqStatus OUT
p_priceStatus OUT po_lines.price_status%TYPE,
p_errFlag OUT NUMBER,
p_errMsg OUT VARCHAR2);

While I run, I got the error of
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC driver for Oracle][Oracle]ORA-02005: implicit (-1)
length not valid for this bind or define datatype
/asp/POLnEdit.asp, line 150 <-- is the line of poDetail.Open
According to the Tom Kyte (Expert One-on-One), the oracle side is
perfectly accepting the datatype assignment and the error was likely
caused by the binding variable from the client side and have not set
some kind of length attribute. Since i am not using the PRO*C, his
suggestion is no help. Does anyone use such syntax and what did I miss
on ASP site? If I change the variable datatype in table typs reference
such as "p_orderID OUT NOCOPY tbl_orderID", where tbl_orderID is
a TYPE tbl_orderID IS TABLE OF po_lines.order_id%TYPE
INDEX BY BINARY_INTEGER; then there is no error.


C Chang

Jul 19 '05 #1
0 2877

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Steph | last post: by
reply views Thread by stephane.traumat | last post: by
reply views Thread by Error while executing SP | last post: by
1 post views Thread by C#_Beginner | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
1 post views Thread by Geralt96 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.