I know the solution to my problem can be solved by using one of the JOINS. But my challenge is that my little brain is not just connecting me to the appropriate JOIN to use.
I tried using a CROSS JOIN but the errors thrown shows that i am not formulating the query properly at all.
Please help me.
thanks a lot
After asking so many questions, i finally succeeded in tweaking out a query that is correct.
it is as follows;
Select Customer, Count, Credit, Debit, Balance, Date from
Select Customer_ID as Customer, (count(Credit) + count(Debit)) as Count, sum(Credit) as Credit, sum(Debit) as Debit
from ThriftsTrans Where Transaction_Date Between'15/Dec/2013'And'18/Dec/2013'GroupBy Customer_ID
) as a leftjoin (
Select Customer_ID as Cust, Account_Balance as Balance,
Transaction_Date as Date From ThriftsTrans Where Transaction_Date In
(Select Max(Transaction_Date) From ThriftsTrans Where Transaction_Date
) as b on a.Customer = b.Cust
thanks to you all
Last Visit: 31-Dec-99 18:00 Last Update: 20-Dec-13 4:48