I have a whopper of a problem here. I've been requested to have QlikView automatically assign priority levels in real-time, depending on the submit_date field. If a request was submitted more than 14 days ago, its priority needs to be elevated a level (LOW to STANDARD to CRITICAL). Here's the fields from the database itself:
priority_name (critical, low, high)
system_name (A, B, C, D, E, F, G)
Here's the inline table I had to create for the original TaskPriority table/chart :
TaskPriority:
LOAD
TaskPriority,
AutoNumber(priority_name & '-' & system_name) as priorityKey;
LOAD * INLINE [
priority_name, system_name, TaskPriority
Critical, A, 1
Critical, B, 2
Critical, C, 3
Critical, D, 4
Critical, E, 5
Critical, F, 6
Critical, G, 7
Standard, A, 8
Standard, B, 9
Standard, C, 10
Standard, D, 11
Standard, E, 12
Standard, F, 13
Standard, G, 14
];
This works fine. For the auto prioritization, I tried implementing a "flag" in the load statement:
Load *,If(add_date>Today()-14,1,0) as idle_request;
...and then I tried implementing the following change to the inline table:
But this gives me duplicate entries, like a request will be a TaskPriority value of both 2 AND 23. Given the task at hand, am I approaching this the wrong way? Any suggestions would help. Thank you all very much, this great community has never let me down before.