Ceriwis  

Go Back   Ceriwis > HOBI > Komputer & Teknologi > Programming

Programming Share, tanya jawab, saling bantu antar programmer dengan berbagai macam bahasa pemrograman.

Reply
 
Thread Tools
  #1  
Old 20th November 2011
Linuxmania Linuxmania is offline
Ceriwiser
 
Join Date: Nov 2011
Posts: 392
Rep Power: 15
Linuxmania mempunyai hidup yang Normal
Default [Help] Oracle ada yang tau?

gan nanya... ada yang tau ini kenapa?


Code:

create or replace procedure saldo_dep_mitra(
cust_id in customer.cust_id
)is
curr_deposit double precision;
gtu_deposit double precision;
vsetor double precision;
vambil double precision;
result sys_refcursor;
result2 sys_refcursor;
begin
/* Procedure SALDO_DEP_MITRA */
/* Hitung Saldo Berjalan dari tabel Penjualan */
select
sum(jml_setor)
into vsetor
from penjualan
where cust_id=cust_id;
select
sum(jml_ambil)
into vambil
from penjualan
where cust_id=cust_id;

dbms_output.put_line(vsetor||' , '||vambil);

end;
/

testernya ini...(itu yang biru kodenya sama kan??, tapi hasilnya kok beda)


Code:

select
sum(jml_setor)
from penjualan
where cust_id='AR1538';
select
sum(jml_ambil)
from penjualan

where cust_id='AR1538';
execute saldo_dep_mitra('AR1538');

outputannya:

SUM(JML_SETOR)

400000

SUM(JML_AMBIL)

105000

400000 , 95123200

PL/SQL procedure successfully completed.









itu kenapa yang merah beda??





</div>
Reply With Quote
Reply


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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Terkait
Thread Thread Starter Forum Replies Last Post
[Logika Learning Center - Oracle Training] Membuka Program Oracle BootCamps masbro1 Programming 4 8th October 2013 11:15 AM
TES TERTULIS ORACLE MASUK PERUSAHAAN BESAR[Yang Ngerti ORACLE MASUK] Linuxmania Programming 0 20th November 2011 10:13 AM
koneksi oracle form developer 10g ke oracle db 10g Guesuper Programming 0 20th November 2011 10:12 AM
migrasi data dari oracle ke oracle Darkc0der Programming 0 20th November 2011 01:14 AM
Ada yang punya tutorial oracle g dopblack Programming 1 10th November 2011 02:46 PM

 


All times are GMT +7. The time now is 05:36 PM.