Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
i have written if condition in the script , while debugging with 10000 load i am not getting error, but while i am doing full load i am getting error as invalid expression , Can anyon eplease help where i am going wrong
Thanks
then try to calculate the same in variables.
You need to include the PERSID ,NEW_STATUS, OLD_STATUS in the Group by Your forgetting the basic here
group by is a clause used for defining over which fields the data should be aggregated (grouped). The aggregation fields should be included in some way in the expressions loaded. No other fields than the aggregation fields may be used outside aggregation functions in the loaded expressions.
groupbyfieldlist ::= (fieldname { ,fieldname } )
Try this,
pre:
Load
Sum(If(NEW_STATUS='RE', Dur)) - Sum(If(WildMatch(NEW_STATUS,'SUPS','OP','CL',), Dur)) as Total_Resolved_Duration,
Sum(If(OLD_STATUS='OP' and NEW_STATUS ='ACK', Dur) as Response Time
Resident GRP
Group by PERSID;
Next time post your script in text format not as picture.
if i am writing the Group by with
i am getting the duplicate values, how to do
The incident is repeating as you can see in the screenshot start time and endtime ,old status and new status is repeating twice if am taking Group by PERSID, NEW_STATUS, OLD_STATUS;
You always share only half of the information , I feel Group by is working fine but Duplication might be because of your join condition or the way you have associated the tables are wrong ..you need to share the complete script and app then only we can debug the issue
Did you try my suggestion?
pre:
Load
Sum(If(NEW_STATUS='RE', Dur)) - Sum(If(WildMatch(NEW_STATUS,'SUPS','OP','CL',), Dur)) as Total_Resolved_Duration,
Sum(If(OLD_STATUS='OP' and NEW_STATUS ='ACK', Dur) as Response Time
Resident GRP
Group by PERSID;
I have 2 tables with first asignment group and seconassignment group with fields as
PERSID i have linked with one more table which is having incident no's
thas the logic i have applied in the datamodel
remove the REF_NUM column and add PERSID and check the data set once ..share your app