Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I need to know how a can get the first date order from a list of several customer
Firts order date results:
Customer 1 = 12/apr/98
Customer 2 = 10/may/99
Thanks
Rib,
Could you please explain your requirement in details and post the same application with data.
If you want to look for first sorterd value then could look for firstsortedvalue() function.
-Sridhar
Hi Sridhar,
I have a list like below:
Customer_id Order_date Order_value
01 12/APR/10 100,00
02 13/APR/10 100,00
03 20/MAY/10 100,00
04 02/JUN/10 100,00
01 03/JUN/10 100,00
02 04/JUN/10 100,00
I need to know how is the first order date for each customer like the results below:
Customer_id First Order_date
01 12/APR/10
02 13/APR/10
I need to know also how is the last order date foe each customer
Customer_id Last Order_date
01 03/JUN/10
02 04/JUN/10
Thanks again
Let`s say that the first table is called ORDERS.
You can create two more tables like this:
MinMax:
load Customer_id, min(Order_date) as First_Order_date,
max(Order_date) as Last_Order_date
resident ORDERS;
Regards,
Erich
ok Erich Thanks.
Actually using the min(order_date) and max(order_date) I get the results than I need. Thanks again !