From: One from One on 28 Nov 2006 01:51 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;
|
Pages: 1 Prev: Error 429 ActiveX component can't create object Next: sending mail with images |