--測试数据 create table tb([DB-ID] varchar(10),ENTITY varchar(10),DATE varchar(10),[CUST-NO] int,AMOUNT decimal(10,2),TAX decimal(10,2)) insert tb select 'RCHQ','001','2004-11-10',200000,100.00,17.00 union all select 'RCHQ','001','2004-11-10',200000,200.