Skip to Content
1

Want to bypass postal code check for country via BADI ADDRESS_CHECK

Nov 28, 2016 at 04:28 AM

234

avatar image
Former Member

Hi,

After upgrade postal code mask have been NNNNN instead of NNN-NNN for postal code check in Customer/vendor and employee master.

We are getting error 'Postal code 514-XXX must have the length 5'.

We want to bypass/deactivate country check by implementing BADI ADDRESS_CHECK.

Can it be done?

If somebody has any idea about this, please highlight on this.

Warm regards

Srimanta

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

4 Answers

Jürgen L
Nov 29, 2016 at 01:18 PM
1

first of all I would try to find out what the real current postal code rules for a country are, unfortunately you hided about which country are you talking.

SAP is not error free, and a typo can be made easily, I recently reported the error that the FM checks with country code RA for Argentina, just as evidence that there can be errors. And if you have an error then you should better try to get a fix from SAP than changing the coding yourself with an implicit enhancement.

If you want to keep your length as is, then just change in OY07 the field T005-PRPLZ from 9 to 5, which allows to accept any entry up to your maximum of 7 characters (from field T005-LNPLZ = 7). So you users can enter the "new" 5 character postal code and still you can have and maintain the old 7 character postal code with the dash in the middle.

Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Dear Jurgen,

Thanks for your solution. It is for country South Korea(KR)

We tried this as you said to change in OY07. It is bypassing 5 char check correctly.

However it fails to check subsequent validation which we have in our system i.e 7 Numeric field only with dash in middle, no alphabet in suffix and prefix.

We are going ahead with the implicit enhancement at the very start of PERFORM formatcheck.

Thanks and Regards

Srimanta

0
Raymond Giuseppi
Nov 28, 2016 at 06:29 AM
0

Why don't you correct the country parameters?

Regards,
Raymond

Show 7 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Raymond,

Thanks for quick reply.

How can it be corrected the country parameter or bypass this check?

With the SP the following code has been added in FM 'ADDR_POSTAL_CODE_CHECK'

* postal_codemask = 'NNN-NNN '. "*2007d

postal_codemask = 'NNNNN'.

Warm Regards

Srimanta

0

Are you asking for Brazil?

I fear that the call of ADDR_POSTAL_CODE_CHECK can only be delayed (after regional check) in the BAdI returning parameter ex_suppress_check_before set, but not removed. But you can change the FM behavior with parameters like T005-PRPLZ 'check rule' and T005-LNPLZ 'length' (-> 9)

Regards,
Raymond

0
Former Member
Raymond Giuseppi

Hi Raymond,

In config, T005-PRPLZ = 9 and T005-LNPLZ = 7. This is ok. We need 7 chars of Postal code only for our client.

But after upgrade in FM, earlier checkmask field 'NNN-NNN ' has been commented and new value 'NNNNN' has been added as below.

* postal_codemask = 'NNN-NNN '. "*2007d

postal_codemask = 'NNNNN'.

That is why we are getting error 'Postal code 514-XXX must have the length 5'.

How to overcome this error?

Warm Regards

Srimanta

0

Seems the standard check is triggered from value of T005-LANDK 'Vehicle Country Key' (*). So if you change Brazil value to a generic one you can bypass ADDR_POSTAL_CODE_CHECK. Then implement you own check in ADDRESS_CHECK->IF_EX_ADDRESS_CHECK~ADDRESS_POSTAL_CHECK.

(*) Ref. 1123588 - Postal code check for different countries

Regards,
Raymond

0
Former Member
Raymond Giuseppi

Hi Raymonds,

Thanks for your reply and suggestion.

In IF_EX_ADDRESS_CHECK~ADDRESS_POSTAL_CHECK, changing parameters are only CH_ADRC_STRUC and CH_T_ERROR_TABLE.

How can we change T005-LANDK? This can be done through OY07.

Because of this, Customer Master/Vendor master/BP/Employee Master address data have been affected.

Thanks and Regards

Srimanta

0

If you don't want to change this value (OY07) then you could use an implicit enhancement point at start of ADDR_POSTAL_CODE_CHECK in forms like PLZ_PBO_CHECK.

Regards,
Raymond

0
Show more comments
avatar image
Former Member Nov 30, 2016 at 04:21 AM
0

Hi,

Thank you all.

It is solved by implicit enhancement.

Thanks and Regards

Srimanta

Share
10 |10000 characters needed characters left characters exceeded
Jürgen L
Nov 30, 2016 at 08:43 AM
0

The change of postal codes in Korea was August 1st, 2015.

the SAP changes are described in OSS note 2204501 - LC2015: Postal Code Length Change for South Korea

and a few other referenced OSS notes: 2161581 and 2179708

"After the reform, the length of postal code changes to 5 digits (NNNNN) from 6 digits (NNN-NNN). The new postal code system is effective on August 1, 2015. Since the effective date, the old 6-digit postal codes are no longer used."

The Korean Post has a website with a postal code finder: http://www.epost.go.kr/roadAreaCdEng.retrieveRdEngAreaCdList.comm

you should probably initiate a project to replace the old postal codes within a few months, as wrong postal codes will usually cause problems, the post people have to determine the new postal code and comes to delays with the delivery. A purchase order may arrive to late at the vendor and in turn you get your materials late and may have interruptions in production. Your company may have to wait longer for a payment from their customers if the bill is delivered later because of wrong postal codes.

Share
10 |10000 characters needed characters left characters exceeded