.create or replace procedure balance as
acno number:=&acno;
txnno varchar2(20);
bdate date:=&bdate;
cou number;
cdno varchar(16);
cid number;
bal number;
begin
select count(*) into cou from customer_master where accno=acno;
select cin,balance into cid,bal from customer_master where accno=acno;
select cardno into cdno from card_master where cin=cid;
if(cou>0) then
select to_char(bdate,'ddmmyyyyhhmiss')||transeq.nextval into txnno from dual;
insert into daily_transactions values(cdno,bdate,bal,0,0,txnno);
commit;
dbms_output.put_line('Your Account Balance is '||bal);
else
dbms_output.put_line('Account Number Does Not Exist');
end if;
end;
/
Subscribe to:
Post Comments (Atom)
MY HIT COUNTER
Blog Archive
-
▼
2009
(38)
-
▼
November
(27)
- few programs on bank project
- customer identification number
- bank programs
- min balance program in oracle
- cards balance
- real time programs in bank project
- real time registration example
- Creation of tables in oracle
- practice quries
- quries
- reverse number
- throws exception
- throws exception
- divide by zero
- array index
- length of a string name
- no parameters to string
- print two parameters
- abstract class in core java
- inside area of rectangle
- area of rectangle
- three string parameters
- class b extends a
- incremeting numbers
- sum of three parameters
- box program
- strings
-
▼
November
(27)
Custom Search
No comments:
Post a Comment