|
Posted by Slower Than You on 11/19/06 18:13
Razvan Socol wrote:
>
> Slower Than You wrote:
> > Razvan Socol wrote:
> >
> > > Consider the following sample data:
> > >
> > > INSERT INTO CustTransactions VALUES (1, 1000, 0)
> > > INSERT INTO CustTransactions VALUES (2, 1000, 1)
> > > INSERT INTO CustTransactions VALUES (2, 2500, 1)
> > > INSERT INTO CustTransactions VALUES (1, 1000, 1)
> > > INSERT INTO CustTransactions VALUES (1, 1000, 1)
> > > INSERT INTO CustTransactions VALUES (3, 30000, 1)
> > > INSERT INTO CustTransactions VALUES (3, 17000, 1)
> > >
> > > What is the expected result (the output of SELECT * FROM
> > > CustTransactions) ?
> >
> > Hi Razvan,
> >
> > Thanks for responding. The expected result for the above sample data
> > would be:-
> >
> > 1, 1000, 0
> > 2, 1000, 0
> > 2, 2500, 0
> > 1, 1000, 1
> > 1, 1000, 1
> > 3, 30000, 1
> > 3, 17000, 1
>
> The above result has a sum of 49000. From your narrative, I would
> expect a result which has a sum of 49500, for example this:
>
> 1, 1000, 0
> 2, 1000, 0
> 2, 2500, 1
> 1, 1000, 0
> 1, 1000, 0
> 3, 30000, 1
> 3, 17000, 1
>
> Which one is the correct result ?
You are absolutely right - I was a little to hasty in putting my
response together. The sum of 49500 is correct.
--
SlowerThanYou
Navigation:
[Reply to this message]
|