Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Oracle Functions
Message
From
14/11/2002 17:56:18
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Oracle Functions
Miscellaneous
Thread ID:
00722984
Message ID:
00722984
Views:
63
Oracle experts,
I need to know how to create a function and then how to call it.
I tried a couple of things and did not give me any errors but neither it created it. I copied
For now I want to find out how to do it from TOAD later on I will do it from VFP.
this is what I tried from MS site and did not work:

CREATE SEQUENCE PersonSN
INCREMENT BY 1
START WITH 100001
NOCACHE;

** Create a Server Function "FNext" to return the next sequence from
** Person.

CREATE OR REPLACE FUNCTION FNext RETURN NUMBER
IS
Count1 NUMBER(10,2);
BEGIN
SELECT PersonSN.nextval INTO Count1
FROM dual;
RETURN(Count1);
END;
/
		

Select FNext from dual


Thanks for your help
Next
Reply
Map
View

Click here to load this message in the networking platform