How to pass cross component values from developer.

Hi,

We don’t have TN. we are getting some products numbers. we need to check that number is valid for the target system. I have Target system list of only required product numbers. How can I check from the source system number is valid for the target system.

source system product numbers like this (1, 100, 1000,70000, 100000…)
target system needs all as 18 characters(this we can do with leading zeros, is this only one way to check a to z lengths or is there any simple way to check and pass the 18 characters).

Thanks
Ravi

Hi Ravi,
If the sourceId you get is like (1, 100, 1000,70000, 100000…) and the targetId is all 18 chars like (000000000000000001, 000000000000001000,000000000000070001), then yes padding the sourceId with leading 0s is one of the easiest way to compare between these 2.

Regards,
Bhawesh.

Hi Bhawesh,
But source side product codes and target side product codes not are maching. We need to check between source and target.Than only we need to allow to target system.

do we need to check all characaters lengths like lengths are 1,2 …10 for these lengths we need to check are is there any other service check and only the rest zeros.

thanks
Ravi

Hi Ravi,
It is still not clear what is your requirement?
Is it that you get:
pCode1=1
pCode2=100
pCode3=1000
pCode4=70000 etc…

and you have a list for possible target like pList[0]=1, pList[1]=15, pList[2]=700 etc… and you want to check if any pCodex matched with pList[y] or not?

  • Bhawesh.

Hi Bhawesh,

Target system has list of product codes, In that list each product code length is not fixed it may the length is 1 to 10. Where we can maintain that list of product codes of target system? As per my knowledge there is a service we can measure the lenghth of input and concat with leading zeros. you to check the length if it one or two or three…to ten and then lead zeros. Do we need to check all this possibilities or is there any other service to check the length and automatically lead the rest are as zeros.

From the developer point of view is there any service where we can store this required product code details like (pub.string.lookupTables).

collect input data and check that table–and pass the corresponding value to the target system. Is it mandatory to store in DB and check every time there.

Could you please tell still if you need any more details.

Thanks
Ravi

Hi Ravi,
You can use the padLeft and padRight services for padding variable length data to make it a fixed length data.

If the possible no. of target values are <20 or so, you can use the pub.string.lookupTables, if you have large no. of lookup, use DB to store them.

HTH,
Bhawesh.