I have one table with columns stamp_type and amount as follows
stamp_type | amount
--------------------------------------------------------------+--------
GENERAL STAMP | 11000
GENERAL STAMP | 25000
COURT FEE STAMP | 9800
SPECIAL ADHESIVE | 721000
GENERAL STAMP | 125000
COURT FEE STAMP | 21000
Now I want to display as follows:
stamp_type | amount
GENERAL STAMP 161000
COURT FEE STAMP 30800
SPECIAL ADHESIVE 721000
TOTAL:912800
I am unable to display the unique values. can any one give suggest me the query. I tried to use Distinct but dint work.
try this code::