Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear Qlikview user
I have a pick(match statement which has a string of 6 fields/variables. Some of the outcomes will only fit 2 or 3 of the fields, so I am trying to fill the gaps with blanks
For Example $(e_Flow_Graph_Arrival_Colour_Ambu) only requires values for:
-$(v_Flow_Graph_Arrival_Colour_Show)
-Flow_Stage
-ED_Mode
-v_Summary_Flow_Graph_Stream_Colour_Show
So I have left a space for the blanks where the field is not applicable. However, my expression is not working.
Could someone kindly take a look and let me know how I can fill the gaps which are not applicable to this outcome
=Pick(Match($(v_Flow_Graph_Arrival_Colour_Show) &'-'& Flow_Stage &'-'& ED_Mode&'-'& Admission_Desc &'-'& $(v_Summary_Flow_Graph_Stream_Colour_Show) &'-'& Stream,
'1-Before Stream-Ambulance- -0- ')+1,
$(e_Flow_Graph_Line_Colours) ,
$(e_Flow_Graph_Arrival_Colour_Ambu))
Kind Regards
Helen
Have you tried without spaces?
=Pick(Match($(v_Flow_Graph_Arrival_Colour_Show) &'-'& Flow_Stage &'-'& ED_Mode&'-'& Admission_Desc &'-'& $(v_Summary_Flow_Graph_Stream_Colour_Show) &'-'& Stream,
'1-Before Stream-Ambulance--0-')+1,
$(e_Flow_Graph_Line_Colours) ,
$(e_Flow_Graph_Arrival_Colour_Ambu))
Alternatively, use Len(Trim()) to give it some value...
=Pick(Match(
If(Len(Trim($(v_Flow_Graph_Arrival_Colour_Show))) = 0, '@', $(v_Flow_Graph_Arrival_Colour_Show)) &'-'&
If(Len(Trim(Flow_Stage)) = 0, '@', Flow_Stage) &'-'&
If(Len(Trim(ED_Mode)) = 0, '@', ED_Mode) &'-'&
If(Len(Trim(Admission_Desc)) = 0, '@', Admission_Desc) &'-'&
If(Len(Trim($(v_Summary_Flow_Graph_Stream_Colour_Show))) = 0, '@', $(v_Summary_Flow_Graph_Stream_Colour_Show)) &'-'&
If(Len(Trim(Stream)) = 0, '@', Stream),
'1-Before Stream-Ambulance-@-0-@')+1,