Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 233511
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T20:06:25+00:00 2026-05-11T20:06:25+00:00

I am looking for good resources on Oracle Stored Procedure geared towards beginners. I

  • 0

I am looking for good resources on Oracle Stored Procedure geared towards beginners. I tried the Dev Shed Article and one from Oracle Documentation site but they did not meet my needs. The one form Oracle Documentation site had the overhead of Java example. I tried the Dev Shed one but I keep getting invalid SQL error when I try their example. Here is the basic one that I tried to run:

CREATE OR REPLACE PROCEDURE skeleton
IS
BEGIN
 NULL;
END;

EXECUTE skeleton;

Am I making a rookie mistake or is the syntax in the article out of date? I am working with Oracle 10g & PL/SQL Developer.

Thanks!

SOLUTION:

As per @curtisk’s suggestion, I tried a slightly more involved example:

CREATE OR REPLACE PROCEDURE p_getdate
IS
BEGIN
 dbms_output.put_line(TO_CHAR
    (SYSDATE, 'MM-DD-YYYY HH24:MI:SS'));
END;

When I tried to execute it like so:

EXECUTE p_getdate

I got ORA-00900: Invalid SQL statement error. I looked for why this would be the case & stumbled across this thread. I decided to give call a try so I tried the following:

CALL p_getdate;

but that did not work as well. I read the thread some more & skeptically tried:

CALL p_getdate();

and voila, I had the procedure being called properly. I do not have an answer as to why this works but the fact that it works allows me to move forward with my project. If there is anyone who can explain to me why this is, I would love to learn more on this.

Thanks once again to @curtisk for the help!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T20:06:26+00:00Added an answer on May 11, 2026 at 8:06 pm

    I wouldn’t use that example as a starting point…I’d make it do something here’s one to try

    CREATE OR REPLACE PROCEDURE p_getdate
    IS
    BEGIN
     dbms_output.put_line(TO_CHAR
        (SYSDATE, 'MM-DD-YYYY HH24:MI:SS'));
    END;
    

    Run that, it should compile successfully, then at the prompt….

    SQL> SET SERVEROUT ON;
    SQL> execute p_getdate;
     06-11-2009 12:29:54
    

    You should see the current date/time in the output. The example you used was too simple IMHO. Next step is to create a procedure that deals with declarations and parameters.

    As far as beginner resources, there’s a ton out there can’t really recommend any one in particular, and if nothing there’s always “Ask Tom”..should be some Q/A there that may help

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am looking for good resources on Stored Procedures. Particularly for Microsoft SQL server
I'm looking for an explanation or good free online resources about the organization of
I am looking for good beginners material on Prolog, both online and printed. I
Im looking for some good resources for MooTools. jQuery has a nice plugins site.
I'm looking for some good resources about network programming in .NET (c# preferably), I
Where are some good resources for looking at the pros/cons of different ways of
I am looking for good resources to learn to develop Firefox extensions. Resources can
I'm looking for a good set of resources to get starting on converting to
I am looking for some good resources of information about the CorDbg & Mdbg
I've been looking around the net trying to find good resources for learning PostgreSQL's

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.