Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Plant details with respect to company code

Former Member
0 Kudos
952

hai giuys,

how to get the plant details with respect to the company code.

Regards,

N.selvamuthukumar

1 ACCEPTED SOLUTION

Former Member
222

Hi

Use this FM

K_WERKS_OF_BUKRS_FIND

Import parameters Value

BUKRS 0001

Tables Value

ITAB_001K 0 Entries

Result: 12 Entries

ITAB_001W 0 Entries

Result: 10 Entries

ITAB_001W contains Plant details including address etc.

Regards

Shiva

9 REPLIES 9

Former Member
223

Hi

Use this FM

K_WERKS_OF_BUKRS_FIND

Import parameters Value

BUKRS 0001

Tables Value

ITAB_001K 0 Entries

Result: 12 Entries

ITAB_001W 0 Entries

Result: 10 Entries

ITAB_001W contains Plant details including address etc.

Regards

Shiva

Former Member

0 Kudos
222

I don't suppose anyone has the Hana S4 1909 version of this? Or even the 1809 will suffice?

Thanks

Former Member
0 Kudos
222

Hi,

I don't think that there is a way to directly get the plant details from the company code.....I would suggest you to use the FM 'HRCA_PLANT_GET_COMPANYCODE' to check if a particular plant belongs to a company code and if then then get the plant details using the FM 'GET_PLANT_DETAILS'.

Hope it helps.

Thanks,

Sandeep.

Former Member
0 Kudos
222

Hi,

Check table T001W.

Pass company code BUKRS to BWKEY and get the details of the plants accordingly.

Hope this will help.

Regards,

Nitin.

Former Member
0 Kudos
222

Hi,

Table T001K is the link of Company Code (BUKRS) to PLANT (BWKEY). Plant text information is on the table T001W.

Regards,

Mon Magallanes

Former Member
0 Kudos
222

Hi,

Try this code i hope you can get it.

TABLES:

ekpo.

TYPES:

BEGIN OF type_s_a,

bukrs TYPE ekpo-bukrs,

werks TYPE ekpo-werks,

END OF type_s_a.

DATA:

fs_a TYPE type_s_a,

t_a LIKE STANDARD TABLE OF fs_a.

SELECT-OPTIONS:

s_bukrs FOR ekpo-bukrs.

SELECT bukrs werks FROM ekpo INTO TABLE t_a where bukrs in s_bukrs.

LOOP AT t_a INTO fs_a.

WRITE:/ fs_a-bukrs,

fs_a-werks.

ENDLOOP.

Regards,

Rajani

Former Member
0 Kudos
222

Hi,

Use this function module.

It will the list of all plants for a given company code.

This will give the exact output what you want....

K_WERKS_OF_BUKRS_FIND

Regards

Kiran

Edited by: Kiran Saka on Feb 6, 2009 9:46 AM

0 Kudos
222

Hi,

Is it working...

It will definitely work...Try it once..

Regards

Kiran