On sun, 2007-06-24 at 06:14 -0500, A. R. Van Hook wrote:
[ in the future, please avoid top-posting, as it is annoying
to have to rearrange lines when replying ]
> Ragnar wrote:
> > On lau, 2007-06-23 at 04:15 -0500, A. R. Van Hook wrote:
> >> Ragnar wrote:
> >>> On fim, 2007-06-21 at 08:46 -0500
Works great.
Can you enlighten me as why the deposit is divided by the number of rows?
thanks
Ragnar wrote:
On lau, 2007-06-23 at 04:15 -0500, A. R. Van Hook wrote:
Ragnar wrote:
On fim, 2007-06-21 at 08:46 -0500, A. R. Van Hook wrote:
If I try an inclusive query using the fol
On lau, 2007-06-23 at 04:15 -0500, A. R. Van Hook wrote:
> Ragnar wrote:
> > On fim, 2007-06-21 at 08:46 -0500, A. R. Van Hook wrote:
> >> If I try an inclusive query using the following:
> >> select
> >> sum(i.rowtot + i.tax) as tot,
> >> sum(v.deposit) as deposit
> >> from ca
What is the correct query???
thanks
Ragnar wrote:
On fim, 2007-06-21 at 08:46 -0500, A. R. Van Hook wrote:
if I query for the total deposit using
select sum(deposit)
from invoice
where cusid = 2128"
I also get 1179.24, also the correct amount
If I try an inclusive query using th
On fim, 2007-06-21 at 08:46 -0500, A. R. Van Hook wrote:
> if I query for the total deposit using
>select sum(deposit)
>from invoice
>where cusid = 2128"
>
> I also get 1179.24, also the correct amount
>
>
> If I try an inclusive query using the following:
> select
> sum(i
I have three tables relating to purchases
invoice - transaction data (customer id, deposit. etc)
invoiceitems - purachace items detail
cai - customer data
if I query for the total charges using
select sum(rowtot + tax)
from invoiceitems
where ivid in (select ivi
[Please don't top post as it makes the discussion more difficult to
follow, and please reply to the list so that others may benefit from
and participate in the discussion.]
On Jun 19, 2007, at 14:17 , A. R. Van Hook wrote:
Michael Glaesemann wrote:
On Jun 13, 2007, at 8:19 , A. R. Van Ho
There is not referenced table cai in from clausule.
A. R. Van Hook napsal(a):
> I have join problem:
> "select i.ivid, v.eventdate, v.deposit, v.invdate, cai.db,
> sum(i.tax) as tax,
> sum(i.tax + i.rowtot) as totalP,
> (sum(i.tax + i.rowtot) - v.dep
On Jun 13, 2007, at 8:19 , A. R. Van Hook wrote:
I have join problem:
"select i.ivid, v.eventdate, v.deposit, v.invdate, cai.db,
sum(i.tax) as tax,
sum(i.tax + i.rowtot) as totalP,
(sum(i.tax + i.rowtot) - v.deposit) as balance
from
You can do it like this:
select i.ivid, v.eventdate, v.deposit, v.invdate, cai.db,
sum(i.tax) as tax,
sum(i.tax + i.rowtot) as totalP,
(sum(i.tax + i.rowtot) - v.deposit) as balance
from invoice v
join cai on v.cusid = cai
A. R. Van Hook a écrit :
> I have join problem:
> "select i.ivid, v.eventdate, v.deposit, v.invdate, cai.db,
> sum(i.tax) as tax,
> sum(i.tax + i.rowtot) as totalP,
> (sum(i.tax + i.rowtot) - v.deposit) as balance
> from invoice v
>
I have join problem:
"select i.ivid, v.eventdate, v.deposit, v.invdate, cai.db,
sum(i.tax) as tax,
sum(i.tax + i.rowtot) as totalP,
(sum(i.tax + i.rowtot) - v.deposit) as balance
from invoice v
left outer join
12 matches
Mail list logo