on 2023 Jan 30 1:33 PM
Hallo,
I'm using the function module RFC_READ_TABLE to read some data from a table.
In my case I would like to extract data where two field as equal (in my case date).
I know that I have the this options to check the field with fixed values (example MATNR EQ '0001234656').
--> https://help.sap.com/doc/abapdocu_740_index_htm/7.40/de-DE/abenlogexp_any_operand.htm
But can I compare to fields with eachother (example date and date)?
I just tried it with SE37 and didn't get the required result.
Regards
Hassin
Request clarification before answering.
Hello,
you can use the OPTION parameter for this. For the qualification of the 2nd field you have to use the table name and a "~". Here an example for selecting all records from SFLIGHT where SEATSMAX = SEATSOCC.
QUERY_TABLE: SFLIGHT
OPTION: SEATSMAX = SFLIGHT~SEATSOCC
Kind regards
Jan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello hassin,
this is another problem. The tables parameter of RFC_READ_TABLE for supplying the data has a length of 512 bytes - the attempt to read records with a bigger size causes the shown error.
If you do not need all fields of the LIPS table, you can specify the necessary fields in table FIELDS (specifying the field name is enough - offset, length etc. will be provided by RFC_READ_TABLE) to reduce the overall length of the data records to be returned.
If you need all fields, you have to leave RFC_READ_TABLE behind you and try another one. If available, CNVCF_CCE_RFC_READ_TABLE offers the capability to read tables with a record length up to 4096, and /SAPDS/RFC_READ_TABLE2 offers the capability for a record length up to 30KB.
Kind regards
Jan
User | Count |
---|---|
61 | |
8 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.