Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi all,
I have a column named opening date for ex:
Temp2:
Load
[invoice no,]
[Opening date],
Charges
Quantity
Resident temp1;
store temp2 into C;/.......qvd
i need to have opening dates only for previous month..
As iam storing only in QVD ... i will nt be using any fron end expressions ...
nbeed solution on script level?
kindly suggest..
Hi
Do you just want to store only previous month?
Something like
Temp2:
Load
[invoice no,]
[Opening date],
Charges
Quantity
Resident temp1
WHERE MONTH([Opening date]) = ADDMONTHS(Today().-1) ;
store temp2 into C;/.......qvd
Mark
Hi,
Use where statement like Opening date <= Current month start date.
Thanks
Siva
Try using a where statement such as:
where [Opening date] between monthstart(addmonths(Today()-1)) and monthend(addmonths(Today()-1))
Haven't checked the syntax properly but something along those lines.
If you wanted all data up until the end of last month i would try the following:
Temp2:
Load
[invoice no,]
[Opening date],
Charges
Quantity
Resident temp1
where [Opening date] < date(monthstart(today())) ;
hi all,
i tried all the options it dos not work..mark suggestion gives no data
daniel suggestion gives complete data..
any other suggestions?
HI,
Try wrapping the opening date field in a date function to rule out formatting issues. If it isn't being picked up as a date field then month function won't work.
Mark
mark can you give me with an example...? my date format is 24-jan-2011 something like this
Why don't you filter the data according to the condition on 'Opening Date' when you load it into Temp1 ?
As Mark pointed out try something like:
where Date([Opening Date]) between monthstart(addmonths(Today()-1)) and monthend(addmonths(Today()-1))