Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
raadwiptec
Creator II
Creator II

current month

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..

Labels (1)
10 Replies
Mark_Little
Luminary
Luminary

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

Not applicable

Hi,

Use where statement like Opening date <= Current month start date.

Thanks

Siva

Anonymous
Not applicable

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.

danansell42
Creator III
Creator III

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())) ;

raadwiptec
Creator II
Creator II
Author

hi all,

i tried all the options it dos not work..mark suggestion gives no data

daniel suggestion gives complete data..

any other suggestions?

Mark_Little
Luminary
Luminary

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

raadwiptec
Creator II
Creator II
Author

mark can you give me with an example...? my date format is 24-jan-2011 something like this

pooja_sn
Creator
Creator

Why don't you filter the data according to the condition on 'Opening Date' when you load it into Temp1 ?

Anonymous
Not applicable

As Mark pointed out try something like:

where Date([Opening Date]) between monthstart(addmonths(Today()-1)) and monthend(addmonths(Today()-1))