Web Wiz - Solar Powered Eco Web Hosting

  New Posts New Posts RSS Feed - how to use stored function in asp
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

how to use stored function in asp

 Post Reply Post Reply
Author
maneeshkrverma View Drop Down
Newbie
Newbie
Avatar

Joined: 12 August 2007
Location: India
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote maneeshkrverma Quote  Post ReplyReply Direct Link To This Post Topic: how to use stored function in asp
    Posted: 12 August 2007 at 1:43pm

hi all Smile

i hav created a function in oracle 9i. like

create or replace function selrec(un varchar2, pass varchar2) return number is
begin
 select 'x' from user_info where id=un and pass=pass;

 return 1;
exception
 when no_data_found then
 return 0;
end;
/

now how should i use this function in asp to move the user to another page after login if the user is registered user.

thanx in advance
maneesh

Back to Top
Dilipv View Drop Down
Newbie
Newbie
Avatar

Joined: 11 February 2008
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote Dilipv Quote  Post ReplyReply Direct Link To This Post Posted: 13 February 2008 at 10:10am
hi there,

   i saw your quote. so why don't you use response.redirect method.
  as soon as the user logs in, if condition will check the values in database. and if the condition is true then response.direct the user to the desired page.

Hope this will solve your query.

Thank you
jitesh
Programmer

Back to Top
emily12 View Drop Down
Newbie
Newbie


Joined: 08 August 2008
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote emily12 Quote  Post ReplyReply Direct Link To This Post Posted: 17 September 2008 at 8:17am
I'm new to asp.net and I have an oracle stored function with 3 input parameters that returns a string. The function is one that validates a user. I want to validate my users from Oracle. I'm trying to use the sqldatasource component to interact with my stored procedure but I can't seem to find the right syntax.
Back to Top
jamie.townsend View Drop Down
Groupie
Groupie


Joined: 07 December 2007
Location: England
Status: Offline
Points: 114
Post Options Post Options   Thanks (0) Thanks(0)   Quote jamie.townsend Quote  Post ReplyReply Direct Link To This Post Posted: 17 September 2008 at 9:31am
Back to Top
vikas View Drop Down
Newbie
Newbie
Avatar

Joined: 23 January 2009
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote vikas Quote  Post ReplyReply Direct Link To This Post Posted: 17 February 2009 at 9:43am
I know how to call the stored procedure from asp..And the code is:

<%Dim objConn, sqlInsName, FName, LName
FName = "Benny"
LName = "Alexander"
set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open "DSN=macdb;uid=test;pwd=test"
sqlInsName = "sp_InsName '" & FName & "', '" & LName & "'"
objConn.Execute(sqlInsName) %>


but i am not sure about that the code will useful for you..I just wanted to help you out that's why i typed the code..
Back to Top
SNK111 View Drop Down
Newbie
Newbie


Joined: 02 June 2010
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote SNK111 Quote  Post ReplyReply Direct Link To This Post Posted: 14 July 2010 at 6:41am
Check this article HOW TO: SQL in JAVA & C# for details on how to connect to SQL Server database from C#.NET database applications as well as Java database applications. It also describes how to pass embedded SQL queries (SELECT, INSERT, UPDATE, DELETE), calling stored procedures, pass parameters etc.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.07
Copyright ©2001-2024 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Policy

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2024 Web Wiz Ltd. All rights reserved.