hello, We are using open source BI Helical Insight version 6.1.0.852 GA (Docker). We want to pass in the user’s time zone by fetching it dynamically from the user profile (profile[‘timeZone’]). Can we achieve this use case ?
Thanks,
Netta.
hello, We are using open source BI Helical Insight version 6.1.0.852 GA (Docker). We want to pass in the user’s time zone by fetching it dynamically from the user profile (profile[‘timeZone’]). Can we achieve this use case ?
Thanks,
Netta.
Hello Netta,
Yes, this can be achieved using the dynamic query option in metadata. You can fetch the user’s time zone from profiles using GroovyUsersSession and apply it in the SELECT clause
import com.helicalinsight.efw.utility.GroovyUsersSession
def profileName = GroovyUsersSession.getValue(’${profile[‘timeZone’]}’);
return “”“SELECT travel_date,travel_date AT TIME ZONE $profileName AS “User Time” FROM “travel_detaills””""

Thanks,
Helical Insight.