on 07-31-2008 7:02 AM
Hi All,
I am trying to write a validation expression for the following requirement but not able to succeed -
I have two fields which are qualifiers in my one of the qualified lookup table and one field called Material Number(calcualted) which is a main able field. For example name of the fields are -
Field1 - Qualifier
Field2 - Qualifier
Now I have to wirte a validation expression in which - If the Field1 = "Yes" then Field2 has to be null (This I have achieved) and if Field1 = "No" then Field2 can not be null (Done) and it should have a valid Material Number (Not able to do).
By valid material number what I mean is the number should be one amongst what all are present in the Material Number field on the main table.
Any help would be greatly appreciated.
Thanks.
Hi,
Try this...
IF(Qualified.Field1. = "Yes", IS_NULL(Qualified.Field2),IF(Qualified.Field1. = "No" , IS_NOT_NULL(Qualified.Field2),False))
Thanks,
Mandeep Saini
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Try this.....
IF(Qualified.Field1. = "Yes" AND IS_NULL(Qualified.Field2),TRUE, FALSE) OR (IF(Qualified.Field1. = "NO" AND IS_NOT_NULL(Qualified.Field2), TRUE, FALSE) AND IF(FIND(Qualified.Field2,Material Number), TRUE, FALSE))
Rewards if Useful.....
Thanks,
Mandeep Saini
Edited by: Mandeep Saini on Jul 31, 2008 10:25 AM
Hi,
I feel for check all the values in column dynamically only option left with you to change your Repository structure and it should work. for this first you create a subtable say Materials having field name say Name by default of type text which should look up into your Maintable i mean in Main table you create a field say Material Number which is look up to this Subtable Materials.
Now the syntex for find should work.
IF(Qualified.Field1. = "Yes" AND IS_NULL(Qualified.Field2),TRUE, FALSE) OR (IF(Qualified.Field1. = "NO" AND IS_NOT_NULL(Qualified.Field2), TRUE, FALSE) AND IF(FIND(Qualified.Field2,Material Number.Name), TRUE, FALSE))
you can try this in your any Demo repository first if it works you can change to your actuall repository.
But here you have to again change your Maps and whole mapping during import Manager. i hope it should work.
Rewards If Useful....
Thanks,
Mandeep Saini
Edited by: Mandeep Saini on Jul 31, 2008 12:53 PM
Hi Tony,
Validation can be written for the first condition i.e. If field1 is Yes then field2 should be null and other way round, but we cannot have a loop feature to find out the valid material numbers present in the main table.
IF(Qualified.Field1. = YesNoIndicator AND IS_NULL(Qualified.Field2), TRUE, FALSE)
Regards,
Jitesh Talreja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.