as
begin
declare @pprice float
select @pprice=(BC+((@packkg-AC)*DC)/CC) from PPrice where PID=@PID and Express=@Express
return round(isnull(@pprice,0),0)
end
CREATE TABLE [dbo].[PPrice] (
[Gid] [int] IDENTITY (1, 1) NOT NULL ,
[PID] [varchar] (50) COLLATE Chinese_PRC_CI_AS NULL ,
[Express] [int] NULL ,
[AC] [float] NULL ,
[BC] [float] NULL ,
[CC] [float] NULL ,
[DC] [float] NULL ,
[Gdate] [datetime] NULL
) ON [PRIMARY]
GO