use Leo
go

create proc dbo.proc_CreateTransaction (
  @date date, @description varchar(200), @amount decimal(11,2)
)
as
begin
  set @date = isnull(@date, getdate())

  insert into dbo.BUDGET_DETAIL (TrxDate, TrxDescription, TrxAmount)
  select @date, @description, @amount

  select SCOPE_IDENTITY()
end
go
