How can I filter this report with user name?

I am using below recipe to create a SAIL report. How can I filter this report with user name? Please note that I have added a column "Assign To" in the portal report that display's tp!owner information. I was able to add the user picker to the below recipe, but I am unable to filter the grid based on user that is being selected by the user picker control object.

forum.appian.com/.../SAIL_Recipes.html
Thank you for your help in advance!

OriginalPostID-147970

OriginalPostID-147970

  Discussion posts and replies are publicly visible

Parents
  • Hi zulfiqarp Though I haven't seen the recipe, here goes a few simple steps to add single query filter while querying the process analytics as desired by you:

    Step - 1: Execute the a!queryProcessAnalytics() (with/without filters).
    Ex: a!queryProcessAnalytics(
    report: <your report>,
    contextGroups: {},
    contextProcessIds: {},
    contextProcessModels: {
    <your process model>
    },
    contextUsers: {},
    query: a!query(
    logicalExpression: null,
    pagingInfo: a!pagingInfo(
    startIndex: 1,
    batchSize: 1
    )
    )
    )

    Step - 2: Observe the 'columnConfigs' attribute from the output obtained from Step - 1. Identify the desired field which you want to apply the filter on.

    For instance, [label:Owner,field:c3,drilldownField:dp3,configuredFormatting:NUMBER,configuredDrilldown:]; where label is the name of column in report and 'c3' is the corresponding field name which you should apply filter on.

    Step - 3: Build a query filter from the field identified in Step - 2 and a value desired by you. You can reflect the same structure in the logicalExpression parameter of a!queryProcessAnalytics() or you can save the following into a local variable when you select a user from pick list.

    Example: a!queryFilter(
    field: "c3",
    operator: "=",
    value: local!selectedUser
    )

    Step - 4: Integrate the Step - 3 in a!queryProcessAnalytics definition on conditional basis.

    Example:
    a!queryProcessAnalytics(
    report: <your report>,
    contextGroups: {},
    contextProcessIds: {},
    contextProcessModels: {
    <your process model>
    },
    contextUsers: {},
    query: a!query(
    logicalExpression: if(
                                                                          rule!APN_isEmpty(local!selectedUser),
                                                                          null,
                                                                          a!queryFilter(
                                                                                    field: "c3",
                                                                                    operator: "=",
                                                                                    value: local!selectedUser
                                                                          )
                                                                ),
    pagingInfo: a!pagingInfo(
                                                                startIndex: 1,
                                                                batchSize: -1
                                             )
    )
    )

    Please do let me know if you have any follow up questions.
Reply
  • Hi zulfiqarp Though I haven't seen the recipe, here goes a few simple steps to add single query filter while querying the process analytics as desired by you:

    Step - 1: Execute the a!queryProcessAnalytics() (with/without filters).
    Ex: a!queryProcessAnalytics(
    report: <your report>,
    contextGroups: {},
    contextProcessIds: {},
    contextProcessModels: {
    <your process model>
    },
    contextUsers: {},
    query: a!query(
    logicalExpression: null,
    pagingInfo: a!pagingInfo(
    startIndex: 1,
    batchSize: 1
    )
    )
    )

    Step - 2: Observe the 'columnConfigs' attribute from the output obtained from Step - 1. Identify the desired field which you want to apply the filter on.

    For instance, [label:Owner,field:c3,drilldownField:dp3,configuredFormatting:NUMBER,configuredDrilldown:]; where label is the name of column in report and 'c3' is the corresponding field name which you should apply filter on.

    Step - 3: Build a query filter from the field identified in Step - 2 and a value desired by you. You can reflect the same structure in the logicalExpression parameter of a!queryProcessAnalytics() or you can save the following into a local variable when you select a user from pick list.

    Example: a!queryFilter(
    field: "c3",
    operator: "=",
    value: local!selectedUser
    )

    Step - 4: Integrate the Step - 3 in a!queryProcessAnalytics definition on conditional basis.

    Example:
    a!queryProcessAnalytics(
    report: <your report>,
    contextGroups: {},
    contextProcessIds: {},
    contextProcessModels: {
    <your process model>
    },
    contextUsers: {},
    query: a!query(
    logicalExpression: if(
                                                                          rule!APN_isEmpty(local!selectedUser),
                                                                          null,
                                                                          a!queryFilter(
                                                                                    field: "c3",
                                                                                    operator: "=",
                                                                                    value: local!selectedUser
                                                                          )
                                                                ),
    pagingInfo: a!pagingInfo(
                                                                startIndex: 1,
                                                                batchSize: -1
                                             )
    )
    )

    Please do let me know if you have any follow up questions.
Children
No Data