469,610 Members | 1,494 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

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

How To Retrieve ADO Recordset from Oracle Function Through ASP?+

I have a lot of Oracle function in packages and i would like use it in my ASP
pages.
With Oracle procedure it's all right.
Sample like this
....
set cn = Server.CreateObject("ADODB.Connection")
connString = "Provider=MSDAORA.1;Data Source=<>;User ID=<>;Password=<>"
cn.Open connString
SQL = "{call test.test_asp({resultset 0, cResult})}"
Set cmd = Server.CreateObject ("ADODB.Command")
Set cmd.ActiveConnection = cn
cmd.CommandText = SQL
cmd.CommandType = 1 'adCmdText
Set rs = Server.CreateObject ("ADODB.RecordSet")
Set rs = cmd.Execute
If NOT (rs.BOF and rs.EOF) Then
Do while NOT rs.EOF
<%=rs("dfcountry")%>
<%=rs("dfname")%>
rs.MoveNext
LOOP
End if
......
And in package TEST i have
PROCEDURE TEST_ASP(cResult IN OUT ResultCursor)
IS
BEGIN
OPEN cResult FOR
SELECT *
FROM tcountry;
END TEST_ASP;"

I Hope You help me with similar call a function!!!
--------------------------------------------------------
For example, this is one
FUNCTION test_fun
RETURN resultcursor
IS
vres resultcursor;
BEGIN
OPEN vres FOR
SELECT *
FROM tcountry;
RETURN vres;
END test_fun;
Nov 28 '06 #1
0 1820

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Tony Marston | last post: by
reply views Thread by devrayhaan | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.