Skip to content

Instantly share code, notes, and snippets.

@ilyakaznacheev
Created February 25, 2019 19:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ilyakaznacheev/80932fefee7f0f8c707983eaa8bba6de to your computer and use it in GitHub Desktop.
Save ilyakaznacheev/80932fefee7f0f8c707983eaa8bba6de to your computer and use it in GitHub Desktop.
@EndUserText.label : 'Shop list'
@AbapCatalog.enhancementCategory : #NOT_EXTENSIBLE
@AbapCatalog.tableCategory : #TRANSPARENT
@AbapCatalog.deliveryClass : #A
@AbapCatalog.dataMaintenance : #LIMITED
define table ztest_shop {
@AbapCatalog.foreignKey.screenCheck : true
key mandt : mandt not null
with foreign key t000
where mandt = ztest_shop.mandt;
key shop_id : int4 not null;
address : stringval;
}
@EndUserText.label : 'Sales history'
@AbapCatalog.enhancementCategory : #NOT_EXTENSIBLE
@AbapCatalog.tableCategory : #TRANSPARENT
@AbapCatalog.deliveryClass : #A
@AbapCatalog.dataMaintenance : #LIMITED
define table ztest_shop_hist {
@AbapCatalog.foreignKey.screenCheck : true
key mandt : mandt not null
with foreign key t000
where mandt = ztest_shop_hist.mandt;
@AbapCatalog.foreignKey.screenCheck : true
key shop_id : int4 not null
with foreign key ztest_shop
where mandt = ztest_shop_hist.mandt
and shop_id = ztest_shop_hist.shop_id;
@AbapCatalog.foreignKey.screenCheck : true
key matnr : matnr not null
with foreign key mara
where mandt = ztest_shop_hist.mandt
and matnr = ztest_shop_hist.matnr;
key timestamp : timestamp not null;
amount : int4;
}
@EndUserText.label : 'Products in shop'
@AbapCatalog.enhancementCategory : #NOT_EXTENSIBLE
@AbapCatalog.tableCategory : #TRANSPARENT
@AbapCatalog.deliveryClass : #A
@AbapCatalog.dataMaintenance : #LIMITED
define table ztest_shop_prod {
@AbapCatalog.foreignKey.screenCheck : true
key mandt : mandt not null
with foreign key t000
where mandt = ztest_shop_prod.mandt;
@AbapCatalog.foreignKey.screenCheck : true
key shop_id : int4 not null
with foreign key ztest_shop
where mandt = ztest_shop_prod.mandt
and shop_id = ztest_shop_prod.shop_id;
@AbapCatalog.foreignKey.screenCheck : true
key matnr : matnr not null
with foreign key mara
where mandt = ztest_shop_prod.mandt
and matnr = ztest_shop_prod.matnr;
@Semantics.amount.currencyCode : 'ztest_shop_prod.currency'
price : abap.curr(13,2);
currency : abap.cuky;
amount : int4;
}
@EndUserText.label : 'Text table for shops'
@AbapCatalog.enhancementCategory : #NOT_EXTENSIBLE
@AbapCatalog.tableCategory : #TRANSPARENT
@AbapCatalog.deliveryClass : #A
@AbapCatalog.dataMaintenance : #LIMITED
define table ztest_shop_t {
@AbapCatalog.foreignKey.screenCheck : true
key mandt : mandt not null
with foreign key t000
where mandt = ztest_shop_t.mandt;
@AbapCatalog.foreignKey.screenCheck : true
key spras : spras not null
with foreign key t002
where spras = ztest_shop_t.spras;
@AbapCatalog.foreignKey.keyType : #TEXT_KEY
@AbapCatalog.foreignKey.screenCheck : true
key shop_id : int4 not null
with foreign key [1..*,1] ztest_shop
where mandt = ztest_shop_t.mandt
and shop_id = ztest_shop_t.shop_id;
text : text255;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment