Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
vikasmahajan

Field Level Trigger Variables table driven

Hi,

I have field level trigger  on %initiative  field ( On Select & On Change) following is my code , Is there any possibility whether we can store this values into table/excel and load into  field trigger automatically ?

= if(Initative='Backup Decom - Non PROD'     ,'[NonPrdBkp.Hostname]',  
  if(Initative='Backup Decom - PROD'         ,'[BackupProd.Hostname]',   
  if(Initative='SAN ReTier - DEV'            ,'[SANReTier.HostKey]',   
  if(Initative='SAN ReTier - Non DEV'        ,'[SANReTierNONDEV.HostKey]',
  if(Initative='Server Decom'                ,'[ServerDecom.HostKey]' ,
  if(Initative='Decom Server Charges'        ,'[DComServer.HostKey]' ,
  if(Initative='NAS ReTier - DEV'            ,'[NASReTierDEV.HostKey]' ,
  if(Initative='NAS ReTier - Non DEV'        ,'[NASReTierNonDEV.HostKey]' ,
  if(Initative='VSI Low Util'                ,'[VSILowUtil.HostKey]' ,
  if(Initative='Stale Job Decom'             ,'[StaleJobDecomDEV.HostKey]' ,
  if(Initative='Virtualization Resize'       ,'[VirtualizationResize.HostKey]' ,
  if(Initative='Cluster Reduction'           ,'[ClusterReduction.HostKey]' ,
  if(Initative='High RTO RPO To SAN Standard','[HRR_To_SAN_Std.HostKey]' ,
  if(Initative='SAN Dev To NAS'              ,'[SanDevToNAS.HostKey]' ,
  if(Initative='SAN QA To NAS'               ,'[SanQAToNAS.HostKey]' ,

  if(Initative='SAN UAT Premium To SAN Standard' ,'[SanUATPrmToSANStd.HostKey]' ,

  if(Initative='SAN Rightsize File Systems'  ,'[SAN_RightsizeFileSystems.HostKey]' ,
  if(Initative='NAS - Zero Utilized'         ,'[NASZeroUtilized.HostKey]' ,
  if(Initative='NAS Underutilized'           ,'[NASUnderutilized.HostKey]' ,
  if(Initative='Zero IO SAN'                 ,'[ZeroIOSAN.HostKey]' ,
  if(Initative='Unused Databases'            ,'[UnusedDatabases.HostKey]' ,

  if(Initative='RTO Greater Than 48 Remove DR'   ,'[RTOGR48REMDR.HostKey]' ,

  if(Initative='DB Dumps To NAS'             ,'[DBDumpsToNAS.HostKey]' ,

)))))))))))))))))))))))

Thanks

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
20 Replies
Kushal_Chawda

for eg .

vInitativeHost

if(Initative='Backup Decom - Non PROD','[NonPrdBkp.Hostname]',

You are storing the value in Variable [NonPrdBkp.Hostname] which is I guess the field name? rite? like wise you have created 20 Variables?  Where you are using this variable?

jonathandienst
Partner - Champion III
Partner - Champion III

I would not use variables for this approach. As you can already see, that gets complex when you have a lot of values. I would create a table (inline or from external txt/xlsx file) that associates the opportunity field with a display value, and then simply use the display value field.

If you insist on using variables, you could construct the search expression into another variable during the load (but you would probably still need a lookup of opportunity to display value).

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
vikasmahajan
Author

yes exactly

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
vikasmahajan
Author

thanks Jon , do you have some demo or sample for at least 2 or 3 .

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
vikasmahajan
Author

We are using this variables to show  totals , and other statistics using dynamic.

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
Kushal_Chawda

Can you create the Inline table like below and link to Initative field

Data:

LOAD * inline "

Initative, FieldName

Backup Decom - Non PROD ,[NonPrdBkp.Hostname]

Backup Decom - PROD ,  [BackupProd.Hostname]

....

SAN ReTier - DEV, [SANReTier.HostKey] ";

Select Initative you want ,

Now You can create the single variable vField , and call FieldName in variable

vField 

= FieldName

then you can call this variable to show totals

vikasmahajan
Author

Ok Thanks Kush I will try n get back.

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
vikasmahajan
Author

can you create one small qvw example to get rid.

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
Kushal_Chawda

I don't have QlikView in my system right now. I will try to create it once I reached home.

vikasmahajan
Author

Sure , Thanks

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.