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

Tables

Former Member
0 Likes
782

Hi Folks,

How to retrieve data from a table which is in two different clients say 100 and 200 and output that data as a list output.

Cheers,

Sriram.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
764

hi,

<b>Client Handling</b>

As already mentioned, you can switch off the automatic client handling in Open SQL statements using a special addition. In the SELECT statement, the addition comes after the options in the FROM clause:

SELECT ... FROM <tables> CLIENT SPECIFIED ...

If you use this addition, you can then address the client fields in the individual clauses of the SELECT statement.

DATA WA TYPE SCARR.

DATA NAME(10) VALUE 'SCARR'.

SELECT *
INTO   WA
FROM   (NAME) CLIENT SPECIFIED
WHERE  MANDT = '000'.

  WRITE: / WA-CARRID, WA-CARRNAME.

ENDSELECT.

A condition for the MANDT field is allowed, since the example uses the CLIENT SPECIFIED option. If NAME had contained the value ‘scarr’ instead of ‘SCARR’, a runtime error would have occurred.

regards,

Ashok Reddy

6 REPLIES 6
Read only

vikram_maduri2
Explorer
0 Likes
764

U can retrive data If the tables r clinet indepedent & provided they or on the same database,If they r client dependent U need to use RFC.

Read only

Former Member
0 Likes
764

Hi,

data is Client Dependent, we can not access the data from other client,

but you can do it in way, in a Client, get the data into a Internal table, then Download it to Desktop, then come to second internal table, then Upload this to a Internal table, then get the data from this client and List all these data in the output

Regads

Sudheer

Read only

Former Member
0 Likes
764

HI,

u can get the data from other clients using RFC.

see the procedure to get the data using RFC from other clients.

rgds,

bharat.

Read only

Former Member
0 Likes
764

Hi,

Create a remote enabled function module which fetches the required data by using a SELECT statement. Create destinations in both clients.

Call this function module by specifying the destinations in your report.

Regards

Sailaja.

Read only

Former Member
0 Likes
765

hi,

<b>Client Handling</b>

As already mentioned, you can switch off the automatic client handling in Open SQL statements using a special addition. In the SELECT statement, the addition comes after the options in the FROM clause:

SELECT ... FROM <tables> CLIENT SPECIFIED ...

If you use this addition, you can then address the client fields in the individual clauses of the SELECT statement.

DATA WA TYPE SCARR.

DATA NAME(10) VALUE 'SCARR'.

SELECT *
INTO   WA
FROM   (NAME) CLIENT SPECIFIED
WHERE  MANDT = '000'.

  WRITE: / WA-CARRID, WA-CARRNAME.

ENDSELECT.

A condition for the MANDT field is allowed, since the example uses the CLIENT SPECIFIED option. If NAME had contained the value ‘scarr’ instead of ‘SCARR’, a runtime error would have occurred.

regards,

Ashok Reddy

Read only

Former Member
0 Likes
764

Using 'client specified' is quite questionable in buisness applications, why do you want to see data of different clients???