Hitachi Vantara Pentaho Community Forums
Results 1 to 1 of 1

Thread: Build xaction Dropdown Filter List from Query

  1. #1
    Join Date
    Jan 2009
    Posts
    3

    Default Build xaction Dropdown Filter List from Query

    I'm trying to take a user variable from the session (which appears to be coming in alright) and use that to formulate a query to a JNDI datasource to populate a drop-down list for a user to select reporting filtering options.

    If I hard-code the selection into in input variable as a string-list, the options appear correctly in the filter. When I try to pull the list from a query, I get a text area without any information populated in it. When running the query, it returns the correct results.

    Any help would be greatly appreciated.


    Here are the code pieces:
    <inputs>
    <cluster type="string">
    <sources>
    <request>cluster</request>
    </sources>
    <default-value>solacefm</default-value>
    </cluster>
    </inputs>

    <actions>
    <action-definition>
    <component-name>SQLLookupRule</component-name>
    <action-type>Perform SQL Query</action-type>
    <action-inputs>
    <user type="string"/>
    </action-inputs>
    <action-outputs>
    <query-result type="result-set" mapping="queryClusters"/>
    <CLUSTERS type="string"/>
    </action-outputs>
    <component-definition>
    <jndi>MetaSource</jndi>
    <query><![CDATA[SELECT DISTINCT(availkey) FROM auth_table]]></query>
    </component-definition>
    </action-definition>
    <action-definition>
    <component-name>SecureFilterComponent</component-name>
    <action-type>Prompt for Information</action-type>
    <action-inputs>
    <queryClusters type="result-set"/>
    <cluster type="string"/>
    </action-inputs>
    <component-definition>
    <selections>
    <cluster style="select">
    <title>Select the Cluster</title>
    <filter value-col-name="CLUSTERS" display-col-name="CLUSTERS">queryClusters</filter>
    </cluster>
    </selections>
    <xsl>parameter-template</xsl>
    <target>Report_Window</target>
    </component-definition>
    </action-definition>
    </actions>
    Last edited by bmcglynn; 01-10-2009 at 12:24 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.