2014 May 10 4:14 PM
Dear Experts,
I have created Database view with two tables like MARA and MAKT. Key field-MATNR. Based on MATNR i collected MARA and MAKTX values. I got double(one duplicate) values in this view. How to approach single values.
I attached screen shots. Kindly give me suggestions for removing duplicate value.
Regards,
Abbas.
2014 May 11 7:20 AM
Hi Syed,
Can you add MANDT(Client) as well in Table join condition on 1st row and then MATNR(2nd row) and recheck it?
Regards,
Sudeesh Soni
Hi Syed,
Can you add MANDT(Client) as well in Table join condition on 1st row and then MATNR(2nd row) and recheck it?
Regards,
Sudeesh Soni
2014 May 10 4:50 PM
Hi,
MAKT have extra key for language
Actually I am quite sure that there is such a view already.
Use "where use" on MAKT.
Use the "selection" compare sy-langu
Regards.
2014 May 10 5:38 PM
Dear Eitan,
I am added above query in selection conditions tab, error display:
'Join for field MAKT-SPRAS uses an SY field'
Added screenshot.
Regards,
Abbas.
2014 May 10 6:47 PM
Hi Abbas,
You cannot Use System field in Database View .
But if you try same in Maintenance View it will work.SO try creating MAINTENANCE VIEW.
or else assign this system field value to a variable before the condition and use that variable in the condition.
Hope it will resolve your queries.
Regards,
Kannan.
2014 May 10 6:38 PM
Hi Syed,
Can you give comparison value equal to 'E' inplace of SY-LANGU and recheck it?
Regards,
Sudeesh Soni
2014 May 10 7:49 PM
Dear Sudeesh,
If i replace 'E' in place of SY-LANGU, activated but values are getting duplicate. If 'EN' no values(0).
Regards,
Abbas.
2014 May 11 5:53 AM
Hi,
What is the purpose of this view ?
If it is a for search help please look at Elementary srch hlp MAT0M
We can see that SPRAS is suplied as parameter:
Regards.
2014 May 11 7:20 AM
Hi Syed,
Can you add MANDT(Client) as well in Table join condition on 1st row and then MATNR(2nd row) and recheck it?
Regards,
Sudeesh Soni
2014 May 11 11:28 AM
Der Sudeesh.
Thank you very much. I added MANDT field in both join condition and view fields. Now values are no duplicates.
Thanks,
Abbas.
2014 May 11 1:08 PM
2014 May 11 8:32 AM
Salam Aleem,
use this bapi it will resolve your problem you need the material description.
PARAMETERS:MATERIAL LIKE BAPIMATDET-MATERIAL.
DATA: MATERIAL_GENERAL_DATA LIKE BAPIMATDOA,
RETURN LIKE BAPIRETURN .
CALL FUNCTION 'BAPI_MATERIAL_GET_DETAIL'
EXPORTING
MATERIAL = MATERIAL
* PLANT =
* VALUATIONAREA =
* VALUATIONTYPE =
* MATERIAL_EVG =
IMPORTING
MATERIAL_GENERAL_DATA = MATERIAL_GENERAL_DATA
RETURN = RETURN
* MATERIALPLANTDATA =
* MATERIALVALUATIONDATA =
.
IF RETURN-TYPE NE 'E' OR RETURN-TYPE NE 'A'.
WRITE: MATERIAL_GENERAL_DATA-MATL_DESC.
ENDIF.
2014 May 11 11:51 AM
w/salam,
I have not required BAPI. Thanks your assistance.
Regards,
Abbas.
2014 May 11 8:38 AM
I thing the duplication is due to the language.
You probably have the same text in both languages.
Try adding field spras to the view...
2014 May 11 8:45 AM
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |