Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
is it possible to integrate an IF function into an Inline Load?
Following scenario:
I have different kind of dates, i.e. created, modified, start, end etc.
I want to concatenate all these into one "calendar" (see below)
Month(Date(Date#(ows_Modified,'YYYY-MM-DD hh:mm:ss'),'MM/YYYY')) as DateMonth,
Month(Date(Date#(ows_Created,'YYYY-MM-DD hh:mm:ss'),'MM/YYYY')) as DateMonth
...
Problem: If I select "May" I see the right reportname, but I don't know if it is the modified or created date.
So I thought of creating an inline table like this below (pseudocode):
INPUT:
LOAD * Inline [
heading
IF(StartDate<>0,start,"")
IF(CreateDate<>0,created,"")
IF(ModifiedDate<>0,modified,"")
IF(EndDate<>0,end,"")
IF(CompleteDate<>0,completed,"")
];
Perhaps my thoughts are too complicated and there is an easier solution?!
Thankful for any help,
Dave
Hi,
I dont know with what way you are concatenating the master calanders. But you can try something shown below.
All you have to do is create a flag, which says from where the respective data has came.
For example.
MasterCal:
Load StartDate as Date,
'Start Date' as Flag
Resident ABC;
Concatenate
Load EndDate as Date,
'End Date' as Flag
Resident PQR;
Concatenate
Load Create_Date as Date,
'Create Date' as Flag
Resident XYZ;
And so on.
Hope this is clear to you.
Regards,
Kaushik Solanki
Hi,
I dont know with what way you are concatenating the master calanders. But you can try something shown below.
All you have to do is create a flag, which says from where the respective data has came.
For example.
MasterCal:
Load StartDate as Date,
'Start Date' as Flag
Resident ABC;
Concatenate
Load EndDate as Date,
'End Date' as Flag
Resident PQR;
Concatenate
Load Create_Date as Date,
'Create Date' as Flag
Resident XYZ;
And so on.
Hope this is clear to you.
Regards,
Kaushik Solanki
try like this using if condition throgh inline load
load IF(StartDate<>0,start,"") ,* inline [
StartDate,Start
];
Thanks to you! Both solutions are working but Kaushik' s one is the best for my problem!