cancel
Showing results for 
Search instead for 
Did you mean: 

How can I find a FU that is associated in a FO?

Former Member
0 Kudos

Hello all,

I want to find a connection between FU and FO (I tried /scmtms/d_torrot) . I need to list all of my Freight Ordes which has a specific FU. I tried to find this connection, but i'm can't find. Could someone help me?

I looked those tables /SCMTMS/D_T* and /SCMTMS/D_P*. But i haven't find anything.

Best regards,

Vicente Picardi

Franco_Espino
Discoverer
0 Kudos

Good afternoon I am new to these topics, please I would like you to help me by indicating how I can read the records for example from the table / SCMTMS / D_TORROT. Is there a function to help me read the tables in the TM module? Thank you

Accepted Solutions (1)

Accepted Solutions (1)

Hi Vicente,

Considering that /scmtms/d_torrot is a transparent table I am assuming you want to consume the connection between FU and FO implementating a new program...

You can do it using BOPF instead of reading database tables.

You just need retrieve your FUs using the /SCMTMS/TOR and call the TOP_LEVEL_TORS association or call the association directly assign the a list of FU keys.


This association will return a list FOs assigned to your FUs.

Best regards,

Thiago Bohn

Answers (4)

Answers (4)

former_member849311
Discoverer

It's been quite some years but as no answer was satisfying my needs I would like to share my BOPF based solution here also.

I was confused by the title as it says "find FU for given FO" but in the question itself it sounds like "find FO a given FU". Second was already resolved by Thiago Bohn. I'd like to give a solution for the first task.

You can select all associated items for the TOs by retrieve_by_association and from there you can reach for the FUs above the items by retrieve_by_associaction again.

You can't directly refer from the FOs into the FUs from my understanding.

Content of the coding snippets:

  1. Retrieving the ITEM_TRs from our TOs
  2. Putting the retrieved keys in a seperate table so that I can pass it into the next method
  3. Retrieving the FUs
lo_service_manager->retrieve_by_association(
EXPORTING
iv_node_key = /scmtms/if_tor_c=>sc_node-root
it_key = lo_chaco_request->mt_tor_key
iv_association = /scmtms/if_tor_c=>sc_association-root-item_tr
iv_fill_data = abap_true
IMPORTING
et_data = lt_item_tr
).
LOOP AT lt_ITEM_TR INTO ls_item_tr.
MOVE ls_item_tr-key TO ls_item_key-key.
APPEND ls_item_key TO lt_item_key.
ENDLOOP.
     lo_service_manager->retrieve_by_association(
EXPORTING
iv_node_key = /scmtms/if_tor_c=>sc_node-item_tr
it_key = LT_item_key
iv_association = /scmtms/if_tor_c=>sc_association-item_tr-fu_root
iv_fill_data = abap_true
IMPORTING
et_data = lt_tor_root_fu
).
bharath_k6
Active Participant
0 Kudos

Dear Vicente,

Probably you are interested in the below blogs and you can get the required help after reading the blog.

Using TEST UI in BOPF

Below blog would help you if you want to build any report.

Report Development using BOPF

Let me know if you still need any specific help.

Thanks,

Bharath.

Former Member
0 Kudos

Hello all,

Thank you so much for reply. I will try to build a report to do this.

Best regards,

Vicente Picardi

Former Member
0 Kudos

Use REQ_TOR association by passing FO key

Former Member
0 Kudos

Hi Vicente

If it is for a specific FU... you can check in the FU's document flow.

Regards

Eduardo Chagas

Former Member
0 Kudos

Hi Eduardo,

Thank you for reply.

That's ok, i can find a specific FU in document flow.

But i have a list with about 900 FUs. All those FUs were planned. And I need to know what is your FO in a fast way.

Do you know how can i find that?

Best regards,

Vicente Picardi