Oracle Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesOracle Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old April 14th, 2004, 11:06 AM
gary noble gary noble is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 6 gary noble User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
still having problems

i tried this but i get the following error: create or replace procedure(a_cust_id varchar2, new_address varchar2)
*
ERROR at line 1:
ORA-04050: invalid or missing procedure, function, or package name

create or replace procedure(a_cust_id varchar2, new_address varchar2)
is
begin
update customer
set address=new_address
where id= a_cust_id;
exception
when others then
null;
end;

Reply With Quote
  #2  
Old April 14th, 2004, 11:25 AM
hari2004 hari2004 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 1 hari2004 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
You have to specify the name for this:

create or replace procedure NAME (p1 in number ...

Reply With Quote
  #3  
Old April 14th, 2004, 11:33 AM
gary noble gary noble is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2004
Posts: 6 gary noble User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
i think this is what you mean but not sure

set serveroutput on
create or replace procedure change_address
(cust_id IN customer.customer_id%TYPE,
cust_id IN varchar2)
RETURN varchar2 IS
new_address varchar2;
begin
update customer
set address=new_address
where id=cust_id;
exception
when others then
null;
end;

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesOracle Development > still having problems


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway