P_TH_StRpRepInfo

DDL: P_TH_STRPREPINFO SQL: PTHSTRPREPINFO Type: view COMPOSITE Package: GLO_FIN_IS_VAT_TH

Get Statutory Report Information for Thailand VAT

P_TH_StRpRepInfo is a Composite CDS View that provides data about "Get Statutory Report Information for Thailand VAT" in SAP S/4HANA. It reads from 1 data source (I_StRpTaskDetails) and exposes 5 fields with key fields StatryRptCategory, StatryRptgEntity. Part of development package GLO_FIN_IS_VAT_TH.

Data Sources (1)

SourceAliasJoin Type
I_StRpTaskDetails I_StRpTaskDetails inner

Parameters (3)

NameTypeDefault
P_ReportingEntity srf_reporting_entity
P_ReportCategory srf_rep_cat_id
P_ReportRun srf_report_run_id

Annotations (9)

NameValueLevelField
AbapCatalog.sqlViewName PTHSTRPREPINFO view
VDM.viewType #COMPOSITE view
VDM.private true view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #NOT_REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.dataClass #MIXED view

Fields (5)

KeyFieldSource TableSource FieldDescription
KEY StatryRptCategory I_StRpRepRun StatryRptCategory
KEY StatryRptgEntity I_StRpRepRun StatryRptgEntity
StatryRptTaskDueDate I_StRpTaskDetails StatryRptTaskDueDate
system_datethenXelseendendasLateFiling
ReportingYear
@AbapCatalog.sqlViewName: 'PTHSTRPREPINFO'
@VDM.viewType: #COMPOSITE
@VDM.private: true
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType.sizeCategory: #XL
@ObjectModel.usageType.serviceQuality: #D
@ObjectModel.usageType.dataClass: #MIXED

define view P_TH_StRpRepInfo
  with parameters
    P_ReportingEntity : srf_reporting_entity,
    P_ReportCategory  : srf_rep_cat_id,
    P_ReportRun       : srf_report_run_id
  as select distinct  from I_StRpRepRun
    inner join   I_StRpTaskDetails on(
      I_StRpRepRun.StatryRptTaskUUID = I_StRpTaskDetails.StatryRptTaskUUID
    )
{
 // key  I_StRpRepRun.StatryRptTaskUUID,

  key  I_StRpRepRun.StatryRptCategory,
  key  I_StRpRepRun.StatryRptgEntity,
       I_StRpTaskDetails.StatryRptTaskDueDate,
       case

       when ( I_StRpRepRun.StatryRptRunType='STAND' )  then ' '
       else case
            when ( I_StRpTaskDetails.StatryRptTaskDueDate <  $session.system_date  ) then 'X'
            else ' '
            end
       end        as LateFiling,
       I_StRpTaskDetails .ReportingYear
}

where
      I_StRpRepRun.StatryRptgEntity  = $parameters.P_ReportingEntity
  and I_StRpRepRun.StatryRptRunID    = $parameters.P_ReportRun
  and I_StRpRepRun.StatryRptCategory = $parameters.P_ReportCategory