This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
Kindly help me out here. I have been trying to solve for this app problem.
My requirement is to show users a list box of customer names they want the data output for. The dates and level of granularity work fine but when it comes to List box passing the parameters to Filter tool it uses an underscore '_' instead of the wide or empty space in the column name and this is causing my filter tool to miss out on most of the values.
For instance, BDI LOGISTICS LLC is BDI_LOGISTICS_LLC and the data stream does not recognize this new input from the list box tool interface.
@farazuddin - one way to handle the issue with spaces and punctuation being replaced by underscores is to make a copy of the customer name and use that to rename the columns. However, make sure to see my second point about when the interface tools are populated.
How to fix column headers if the field has spaces/punctuation:
In your summarize tool, group by CUSTOMER_NAME twice (make two copies of the name)
In your Crosstab tool, put one CUSTOMER_NAME as the column header, and one as the column values. The result will be the original name in the first row, and the modified name (with underscores) in the header.
Use a Dynamic Rename tool to rename the columns using the first row. Now, your column headings have the appropriate spaces/punctuation.
IMPORTANT: app interface tools (like the drop-down) populate BEFORE the workflow runs. So, when the drop-down is presented to the user, the database input and crosstab haven't run yet. The drop-down won't show the user fresh results from the SQL Server; it will show them the results from the last time the workflow ran.
If you want to pull a fresh list from the database each time the user runs the app, then you can use a chained app (I've attached a simple example):
App #1 pulls the list of customers from the database, then outputs them to a .yxdb. Once that's complete, it will move on to App #2.
App #2 uses the .yxdb to populate the drop-down (this would be your existing app)
In App #1, go to View --> Interface Designer
Click the gear icon.
Check On Success - Run Another Analytic App, then navigate to app #2. Make sure the path is relative (it doesn't have the full C:\... path)
Un-check On Success - Show Results to User
Click the layout icon
Add a label telling the user to click Continue. When they press continue, it will pull the names from the database, and then move on to app #2 where it will display the drop-down to the user.