acname actype amount
ac1 credit 300
ac2 credit 4000
ac1 debit 4000
ac2 debit 455
ac1 credit 500
how to get sum of credit and sum of debit for each account
Answer Posted / amit kumar
select sum(amount) amt , acname, actype from table group by
acname , actype
| Is This Answer Correct ? | 6 Yes | 2 No |
Post New Answer View All Answers
Why do we use bulk collect in oracle?
How to concatenate two text values in oracle?
What are joins, explain all types of joins?
How to sort the query output in oracle?
State the difference between a primary key and foreign key?
How does propagation differ between Advanced Replication and Snapshot Replication (read-only)?
What is the implicit cursor in oracle?
How many types of synonyms in Oracle?
How to connect the oracle server as sysdba?
ABOUT IDENTITY?
> CREATE OR REPLACE FUNCTION FACTORIAL_1(factstr varchar2 ) 2 RETURN NUMBER AS 3 new_str VARCHAR2(4000) := factstr||'*' ; 4 fact number := 1 ; 5 BEGIN 6 7 WHILE new_str IS NOT NULL 8 LOOP 9 fact := fact * TO_NUMBER(SUBSTR(new_str,1,INSTR(new_str,'*')-1)); 10 new_str := substr( new_str,INSTR(new_str,'*')+1); 11 END LOOP; 12 13 RETURN fact; 14 15 END; explanation Above program?
What is an oracle user role?
How can you tell how much space is left on a given file system and how much space each of the file systems subdirectories take-up?
Differentiate between function and procedure in oracle.
what is difference between sql plus and sql*plus? (not sql and sql plus).