Page 1 of 2

Using Table Values for User Variables

Posted: Tue Feb 11, 2020 11:32 pm
by ben.w
Hi!
We have a report that uses a table for various customer values that normally are not overridden at the report level, like labor values, etc. However, we would like to have the ability to override the default sales tax value because of non-profits (0%). I am able to do the following, but it isn't ideal:
- set a default value in the report (ignores our table) and the user can override the value as needed
- set the variable to pull a value from the table (it only pulls the top value) and the user can override the value
- not have a variable and the report uses what is set in the table

How can I get the 2nd option to work with filtering the table?

Please let me know if this makes sense. Thank you!

Re: Using Table Values for User Variables

Posted: Thu Feb 13, 2020 9:46 pm
by Lech Kulikowski
Hello,

Please send us a sample report with test data that reproduces the issue for analysis.

Thank you.

Re: Using Table Values for User Variables

Posted: Tue Feb 18, 2020 11:24 pm
by ben.w
Hi Lech,
Attached are the files you requested.
- MicrovellumFactory.sdf contains a table called ActivityStations, which is used by the ActivityStations.mrt report.

Thank you!
Ben

Re: Using Table Values for User Variables

Posted: Wed Feb 19, 2020 9:33 pm
by Lech Kulikowski
Hello,

Ok. Could you explain your issue in more detail, which result do you need in your report?

Thank you.

Re: Using Table Values for User Variables

Posted: Wed Feb 19, 2020 10:31 pm
by ben.w
Hi Lech,
I would like to set a variable in the report with the following criteria:
1) default value to be set to a value in a table (which isn't the first row in the table)
2) allow the variable to be overridden by the user

Re: Using Table Values for User Variables

Posted: Sun Feb 23, 2020 10:38 pm
by Lech Kulikowski
Hello,

Ok, where do you want to use that variable - in filtering, query, etc?
Could you explain your issue in more detail?

Thank you.

Re: Using Table Values for User Variables

Posted: Mon Feb 24, 2020 5:33 pm
by ben.w
Hi Lech,
The use of the variable will be in text formulas, such as: Quote = {(MaterialCosts + Labor Costs) * (Markup + SalesTax)}

To explain this more fully:
We are designing 4 reports that will calculate the materials and labor needed for a project. There values are then multiplied by Sales Tax, Markup and Overhead percentages for the total cost that a customer would pay for the project. These 3 variables currently only exist in the report with an initial value set. We would like these values to be set by a value in a table (ActivityStations) so that report modifications can be minimized.

Basically, we are looking for the following:
1. ActivityStations table is populated with various values, including the 3 I just mentioned above
2. Reports display the appropriate value (i.e. Sales Tax), which the user of the report can override
3. The variable is then used in formulas to calculate the total cost

Our difficulty is in filtering the ActivityStations table to display the one value we need for the user to see and override. I can point the variable to the table, but I only get the first row of the table for values, which is incorrect.

Does that help?
Ben

Re: Using Table Values for User Variables

Posted: Thu Feb 27, 2020 8:52 pm
by Lech Kulikowski
Hello,

In your report, the SalesTax variable is static with 7.5 value and uses only on the TitleBand. Perhaps, you sent a report which does not show your issue.
If you need to use the value from data source in that variable, you should set the ReadOnly property. But in that case, the user won't be able to provide your own value.

Thank you.

Re: Using Table Values for User Variables

Posted: Thu Feb 27, 2020 9:05 pm
by ben.w
Hi Lech,
I set the variable as we have it set today, with is to a static value. I am asking how I can tie it to a value in a table which can be overridden.

Re: Using Table Values for User Variables

Posted: Thu Feb 27, 2020 9:28 pm
by Lech Kulikowski
Hello,

To set the value from data source as initializing value, you can set the expression as - datasourcename.columnname
and set the ReadOnly property.

Thank you.