StockWeeklySnapshots
Source SQL File - Google Cloud Cortex Data Foundation
Google Cloud Cortex Foudantion - Cortex Reporting - (ecc) - StockWeeklySnapshots
Overview
This reporting view provides a snapshot of weekly stock movements for SAP systems. It includes key information such as material number, plant, batch number, storage location, company code, fiscal year, fiscal period, and stock characteristics.
Data Sources
Source Table/View | Description |
---|---|
stock_weekly_snapshots | Contains weekly stock movement data, including quantities, amounts, and stock characteristics. |
CompaniesMD | Provides company-related information, such as company text and fiscal year variant. |
currency_decimal | Contains currency decimal information for currency conversion. |
Key Use Cases
- Analyzing weekly stock movements and trends.
- Identifying stock discrepancies and potential issues.
- Monitoring inventory levels and optimizing stock management.
- Providing data for financial reporting and analysis.
Query Logic
The query retrieves data from the stock_weekly_snapshots
table and joins it with the CompaniesMD
and currency_decimal
tables to enrich the data with company information and currency conversion. It also applies CASE statements to determine the fiscal year and period based on the fiscal year variant and week end date.
Possible relation with SAP Transactions
Transaction Code | Transaction Description |
---|---|
MMBE | Display Material Master |
MB51 | Stock Overview: List |
MB52 | Stock Overview: Hierarchy |
FBL3N | Display Line Items: G/L Account |
Data Lineage
Under Development
Table/View Fields
Field | Field Description | Description in SAP Dictionary (Comming soon) |
---|---|---|
Client_MANDT | Client ID | |
MaterialNumber_MATNR | Material Number | |
Plant_WERKS | Plant | |
BatchNumber_CHARG | Batch Number | |
StorageLocation_LGORT | Storage Location | |
CompanyCode_BUKRS | Company Code | |
CompanyText_BUTXT | Company Text | |
FiscalYear | Fiscal Year | |
FiscalPeriod | Fiscal Period | |
CalYear | Calendar Year | |
CalWeek | Calendar Week | |
WeekEndDate | Week End Date | |
BaseUnitOfMeasure_MEINS | Base Unit of Measure | |
CurrencyKey_WAERS | Currency Key | |
TotalWeeklyMovementQuantity | Total Weekly Movement Quantity | |
QuantityWeeklyCumulative | Quantity Weekly Cumulative | |
TotalWeeklyMovementAmount | Total Weekly Movement Amount | |
AmountWeeklyCumulative | Amount Weekly Cumulative | |
StockCharacteristic | Stock Characteristic |