cancel
Showing results for 
Search instead for 
Did you mean: 

new validation - don't inform material number when creating

Former Member
0 Kudos

Hello!!!

I'd need to create a validation in order to avoid informing the field 'SAP Material number' when creating a new entry in MDM Data Manager for specific material types (material type is a lookup field which has two values, let's say 1 and 2).

For material type 1, we need to inform, when creating the entry, the material type 1, supplier name and supplier reference, but not the SAP material number, as it comes informed through an interface from SAP R/3.

For material type 2, we only need to inform the SAP material number.

Could you guide me on how to do this validation?

Thank you,

Carlos Santamaría.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Carlos,

Can you please explain the data flow in detail.

Thanks,

Ravi

Former Member
0 Kudos

Hello,

The data flow is as follows:

There are two scenarios, one for Goods:

1. Add new record into the Data Manager.

2. Inform field 'Material type' (lookup field) Goods.

3. Inform field 'Supplier name' (lookup field).

4. Inform field 'Supplier reference' (text field).

5. Field 'SAP material number' must be left EMPTY when creating the new record. Once it's created, there is an interface from SAP R/3 which updates through ABAP API the records, informing the SAP material number and other fields informed in SAP R/3.

The validation should avoid that the user informs the material number when creating the new record.

Second scenario is for Finished Goods:

1. Add new record into the Data Manager.

2. Inform field 'material type' (lookup field) Finished goods.

3. Inform field 'SAP material number' (text field).

4. Optionally it is possible to inform Supplier name and Supplier reference, but it's not always inform.

There is already a validation rule that force the user to inform 'Supplier name and supplier reference for Goods, and for Finished goods it's mandatory to inform the SAP material number.

There is another field which is 'Unique key' which is a calculated field and it's composed by SAP material number + Supplier number + Supplier reference.

Our problem is to avoid that the user informs the SAP material number only for Goods. If the user does it, the interface will not work as it is designed.

Thanks for your feedback.

former_member207367
Active Participant
0 Kudos

Hi Carlos,

Check the below validation

IF(Material type =  Goods ,IS_NULL(MATERIAL_NUMBER,Supplier name,Supplier reference))

Note: Select the Goods value from the Lookup values in the expression editor

The above validaiton expression will not allow above fields having an entry when they were creating data in Data Manager.

Regards

Sowseel

Former Member
0 Kudos

Thanks for your reply, but I cannot use this validation as there is an Interface from SAP R/3 to MDM that update the field 'SAP Material nr' in MDM.

I have to validate that this field (Material nr.) is empty, but only when the user is creating manually the new record. Later on, it must be possible to be updated automatically through an interface.

I'd need to use a field which changes once the record is created (for example, 'unique key' which is empty when creating and after saving the record contains a calculated value). But I understand that is not possible to use this kind of fields (calculated fields) for validations in Data Manager.

Edited by: Carlos Santamaría on Aug 2, 2011 3:00 PM

former_member207367
Active Participant
0 Kudos

Hi Carlos

If that was the case add the creation date and updation date in to the logic... consider an user is creatnig a material of material type Goods and save it then created date and updated date will be the same...we can take that in to consideration

So the logic will be

If ( LEFT(Created Date,10) = LEFT(Updated Date,10)  And Materil Type =GOODS , 
IS_NULL(Material Number,Supplier Name,Supplier Reference)

Try this it should solve your problem

Regards

Sowseel

Former Member
0 Kudos

Hi Carlos,

How is the ABAP API getting triggered?

Are you using MDM WF?

When MDM WF are triggered?

Please provide these details,possibly we can find ways to do it.

Thanks,

Ravi

former_member207367
Active Participant
0 Kudos

Hi Carlos,

correction in the logic.....

If( LEFT(Created Date,19)=LEFT(Updated Date,19) AND Material Type = Goods, 

IS_NULL(Material Number,Supplier Name, Supplier Reference))

Regards

sowseel

Former Member
0 Kudos

Finally, I've created these two fields for Creation date and Modification date.

The validation is working as described by you:

IF(Material type.[RECORD]=Material type [Goods]

AND LEFT(Creation date,19)=LEFT(Modification date,19),

IS_NULL(SAP Material nr)

Many thanks to all of you!

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Carloas,

If I have understood your requirement, then You want to send Material Type1, supplier name and supplier reference to ECC if Material Type is Material Type1

And if Material Type is Material Type2, you wnat to send Material Number, Material Type2, supplier name and supplier reference.

If this is your requirement, then you need to create two seperate syndication maps.

Also you need to create Validation to check Material Type & then use this validation in your workflow, in Branch step

So if Material type is 1 then call 1st syndication map in syndication step, if Material Type is 2 then call 2nd Syndication map.

Thanks & Reagrds,

Maheshwari

former_member207367
Active Participant
0 Kudos

Hi

Is your quesion is on notifications in MDM?

If Yes , then your requirement is not possible as MDM Notifications will not work at field level. it works on Display fields of your repository using %Records% in the E-mail body Text

Let me know if i am understanding it correct.

regards

Sowseel