Академический Документы
Профессиональный Документы
Культура Документы
1 Workshop Goals
In this workshop, we will look at some query item properties.
This workshop is a script that reads from top to bottom. Each step depends on you having
followed the instructions for the previous steps correctly.
\QUANTITY
\UNIT_COST
\UNIT_PRICE
\UNIT_SALE_PRICE
\GROSS_PROFIT
\ACTUAL_REVENUE
\PLANNED_REVENUE
\PRODUCT_COST
\MARGIN
\Returns
\RETURN_DATE
\RETURN_DESCRIPTION_EN
\RETURN_QUANTITY
\Product Information
\Products
\PRODUCT_NUMBER
\PRODUCTION_COST
\MARGIN
\Forecasts
\YEAR
\MONTH
\EXPECTED_VOLUME
\Additional
Identifier
Fact, Sum
Fact, SumAverage
Fact, AverageSum
Fact, AverageSum
Fact, Sum
Fact, Sum
Fact, Sum
Fact, Sum
Fact, Sum
Fact, Sum
Identifier
Fact, Sum
Fact, Sum
Fact, Sum
\Sales Rep Information
3 Data Formatting
Format columns in your project (Dates, Percentages, and Currency)
Check formatting options for non-FACT query items.
4 Test Drive
Publish your model to ReportNet.
Click Advanced.
Change the Summary For Cell Values to Total.
Click OK.
We now see the totals instead of maximums.
5 Filters
5.1 Data Source Query Subject SQL Filters
You can code a filter directly into the SQL in your data source query subject.
These filters are always applied when the query subject is used in a query regardless of
the user. These filters are integral to the semantics (meaning) of SQL query and are
therefore always applied.
Select *
from [GO Sales].[PRODUCT_LINE][Model].[PRODUCT_LINE].
[PRODUCT_LINE_CODE] = 1
where PRODUCT_LINE_CODE= 1[Model].[PRODUCT_LINE].
[PRODUCT_LINE_CODE] = 1
4
5
If you wish to use an existing model filter, you simply drag and drop the filter from the
metadata tree into the filter area of the query subject properties dialog and set the usage
as required.
For example, we want to stop our users from accessing orders from before 01 Jan 2006.
We will do this by adding a filter to the ORDERS model query subject.
Edit the definition of the \Order information\ORDERS query subject. Click the Insert
Embedded Filter button: