DECLARE @totalDue money
DECLARE @totalDue1 money
DECLARE @totalDue2 money
set @totalDue=(select sum(balance) from Chart_Of_Accounts
where account like '11%'and [ShortDescription]like 'La Jolla%'
group by [ShortDescription])
set @totalDue1=(select sum (balance) from Chart_Of_Accounts
where account like '11%'and [ShortDescription]='Del Mar'group by [ShortDescription])
set @totalDue2=(select sum (balance) from Chart_Of_Accounts
where account like '11%'and [ShortDescription]='Encinitas'group by [ShortDescription])
print 'The Total Balance for La Jolla is: $' + convert(varchar, @totalDue,1)
print ' '
print 'The Total Balance for Delmar is: $' + convert(varchar, @totalDue1,1)
print ' '
print 'The Total Balance for Encinitas is: $' + convert(varchar, @totalDue2,1)
print ' '
DECLARE @thisOne money
set @thisOne=(select sum(balance) from Chart_Of_Accounts
where account like '12%')
print 'The Inventory balances for La Jolla are as follows: $'+ convert(varchar,@thisOne,1)
2007-01-12
04:04:38
·
2 answers
·
asked by
Valencia E
1
in
Computers & Internet
➔ Programming & Design