Skip to main content
Announcements
Accelerate Your Success: Fuel your data and AI journey with the right services, delivered by our experts. Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
daisy1438
Contributor III
Contributor III

help on below requirment?

Hi

I have table with below fields.

Tab:

RIskID

ControlID

Date

sattus;

The above table date field is there using that date field split into previous date and current date.

my requirement is when user select previous and current dates in dashboard count the RiskID.

Condition is risked not available in previous date and it is available in current date than count the RISKID.

how to write the script back end level as well as front end level.

please share the script.

Thanks

4 Replies
OmarBenSalem

Please try to put some effort into your questions; elaborate; attach some data with 4 5 lines of what u have and describe the desired output based on what u attach.

Create a table of the input and a table of the output; u can so easily do this.

Ur question has not been answered yet and the reason why? Everybody is too busy to try to answer an unclear question.

We do love to help qlikers, but we still have missions and jobs in parallel; time is money... so please, make ur questions clearer to facilitate our comprehension and thus have as many responses as you wish.

tomovangel
Partner - Specialist
Partner - Specialist

Hello, One way is to create 2 excel files both having only dates inside them formatted like your date field .. Like
01-01-2017

01-02-2017 etc.


But the files must have all dates for the years that you want to use.

The first excel file your field will be named DATE1

and the second excel file, the field will be DATE2

and then you create an expression like

Count(if Date>DATE1 and Date<DATE2,RiskID)

or you want something else?

daisy1438
Contributor III
Contributor III
Author

Hi Angel thanks for your reply.

I have only one excel data and only one date field.in that date field user select any two dates and compare those two dates one is previous date and other one is current date .what are the risk ID not available in previous date and available in current date than count the Risk ID.

Ex:

01-jan-2018

16-feb-2018

02-mar-2018

10-apr-2018

12-jun-2018 like that.

if user select 16-feb-2018 and 12-jun -2018 compare those two dates it means

16-feb-2018 date RiskID not available and 12-jun-2018 RiskID available count the that RIskIDs.

Thanks

tomovangel
Partner - Specialist
Partner - Specialist

Okay, i think you need to make a new field, in the load script, which counts the riskids for each date like

Count(RiskID) as RiskCount,

And then have an expression like

if(min(Date)<=0 and max(date)>0,RiskCount)