2.3 KiB
2.3 KiB
C1 Compare
Analysis generated on: 4/2/2025 9:57:11 AM
SQL Statement
SELECT [Util Selection C1].GrossWt, [Util Selection C1].USAGE, [Util Selection C1].BestSheetSet, 1.0533 AS prc1, 1.1333 AS prc2, IIf([BestSheetset]="42.0 X 90.0",[prc1],[prc2]) AS cost, [Cost]*[GrossWt] AS ttl
FROM [Util Selection C1];
Dependencies
- None
Parameters
- None
What it does
SQL Query Description
Overview
This SQL query retrieves data from a table named [Util Selection C1]
. The query calculates various metrics based on the gross weight of each record and applies conditional pricing adjustments.
Columns Retrieved
The query selects the following columns:
[Util Selection C1].GrossWt
: The gross weight of each record.[Util Selection C1].USAGE
: The usage of each record (not explicitly defined in this query, but likely a field in the table).[Util Selection C1].BestSheetSet
: The best sheet set for each record (not explicitly defined in this query, but likely a field in the table).1.0533 AS prc1
: A fixed price value, aliased asprc1
.1.1333 AS prc2
: Another fixed price value, aliased asprc2
.IIf([BestSheetset]="42.0 X 90.0",[prc1],[prc2]) AS cost
: A calculated field that applies different prices based on the[BestSheetset]
value.[Cost]*[GrossWt] AS ttl
: The total cost, calculated by multiplying thecost
with the[GrossWt]
.
Conditional Pricing Adjustment
The query uses an IIf
function to apply conditional pricing adjustments based on the [BestSheetset]
value. If the [BestSheetset]
equals "42.0 X 90.0"
, the prc1
is used; otherwise, the prc2
is used.
Calculation
The total cost (ttl
) is calculated by multiplying the cost
with the [GrossWt]
.
Assumptions
- The table
[Util Selection C1]
has fields forGrossWt
,USAGE
, andBestSheetSet
. - The fixed price values
1.0533
and1.1333
are defined elsewhere in the query or database schema. - The
[Cost]
field is assumed to be a calculated field that depends on the[BestSheetset]
.
Note
This query seems to be part of a larger system, possibly related to inventory management or order processing. Without more context, it's difficult to provide further insights into its purpose or usage.