Application Development and Automation 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: 
Read only

Cross client data read

Former Member
0 Likes
2,172

Hi Experts

select * from zemp

into corresponding fields of table itab

where sy-mandt = 391.

Can we read data of database table from cross clients.

i used abv query, says error.

regards

Rajaram

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,290

use the client specified addition.

SELECT *

FROM ZEMP CLIENT SPECIFIED

INTO TABLE ITAB

WHERE mandt = '000'.

7 REPLIES 7
Read only

Former Member
0 Likes
1,291

use the client specified addition.

SELECT *

FROM ZEMP CLIENT SPECIFIED

INTO TABLE ITAB

WHERE mandt = '000'.

Read only

0 Likes
1,290

Hi

I trid as follows

SELECT * FROM zemp CLIENT SPECIFIED INTO table itab

WHERE MANDT = '392'.

But am getting the error as follows,

The work area "ITAB" is not long enough. long enough.

What could be the reason,

regards

Rajaram

Read only

0 Likes
1,290

Raja,

Check the itab structure.

K.Kiran.

Read only

0 Likes
1,289

declare itab as follows...

data itab type table of zemp.

SELECT * FROM zemp CLIENT SPECIFIED INTO table itab

WHERE MANDT = '392'.

Read only

Former Member
0 Likes
1,289

Hi,

Add the keyword CLIENT-SPECIFIED in your select query....

Best Regards.

Read only

Former Member
0 Likes
1,289

u have to use like this

select * from zemp

into corresponding fields of table itab client specified

where sy-mandt = 391.

for better clarity

SELECT * FROM SCUSTOM CLIENT SPECIFIED INTO WA_SCUSTOM

WHERE MANDT = '003'.

if any query....revert

Read only

Former Member
0 Likes
1,289

Use a function module for cross client it would be more recommandable and easy if we need any cross client data.

Declare the Cross client function module like this.

Declare like this.

DATA: LOC_REMOTE_CLIENT TYPE GSVAL.

*FOR FETCHING VENDOR NAME*

CALL FUNCTION 'ZGET_VENDOR_NAME' DESTINATION LOC_REMOTE_CLIENT

TABLES

TLFA1 = INT_LIF.

Thanks,

Sakthi