View (1) :
define view Zcds_View1
with parameters p_plant:WERKS_D
as select from mara as material_master
--joins
inner join marc as plant_data
on material_master.matnr = plant_data.matnr
inner join mard as stloc
on plant_data.matnr= stloc.matnr
---associations
association[1..*] to makt as material_description
on stloc.matnr = material_description.matnr
{
key material_master.matnr as Material_no,
material_master.mtart as Material_type,
plant_data.werks as Plant,
stloc.pstat as Maintenance_status,
material_description[1: ( spras = 'E' or spras = 'J' ) ].maktx as material_description,
material_master.ersda as Date_mat
}
where plant_data.werks = $parameters.p_plant
View (2) :
define view Zcds_View2
with parameters p_plant2: WERKS_D,
p_main_status2: PSTAT_D
as select * from Zcds_View1( p_plant:$parameters.p_plant2) as View1
where View1.Maintenance_status = $parameters.p_main_status2
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
6 | |
5 | |
3 | |
2 | |
2 | |
2 | |
2 | |
2 | |
2 | |
2 |