cancel
Showing results for 
Search instead for 
Did you mean: 

Getting list of PP orders that a document is attatched to

Former Member
0 Kudos

Hi all,

I'm looking for Bapi or some other tool, which will receive document characteristics (like Name, Type Etc.) and returns list of PP orders that this document is attached to.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Shimshon ,i have the seam prob, whats solution ???

Thanks

Former Member
0 Kudos

You can try using standard T-codes CF12 and CF22 to search for Documents in PP orders.

Note that Production Resources/Tools (PRT's) represent tools, fixtures, procedures, assembly aids, etc. PRT's are typically allocated (linked) to Operations in Routings (task lists). Routings, along with Bills of Material, are copied into production orders. So, PRT's can be found in both Routings and Production Orders.

PRT's come in 4 types, and one of them is Documents (created via CV01N). The others are materials, equipments, and PRT Misc/Masters.

CA70 can be used to perform where-used searches in Routings. Each of the four types also has standard T-Codes for where-used searches in Production Orders.

Barry Vitovsky

Former Member
0 Kudos

Thanks Vitovsky ,

But i want to know, for a work order, How can I see the number(count) of Document Info Record(Fiche info document) that is attached, by a simple request?

Excuse me for my English

MangeshP
Active Contributor
0 Kudos

Hi Shimshon

Can you please ellaborate your requirement.This will help us to to solve your querry faster.

Till that time as per my understanding You want to search a Document with parameter Object Link.

Means you want to Search document which are linked to PP orders ( Object :- PORDER Production order)

So check this BAPI BAPI_DOCUMENT_GETOBJECTDOCS

Hope this is usefull to you.

With Regards

Mangesh Pande

Former Member
0 Kudos

Thanks Mangesh,

Your interpetation was correct. I want the input to be: Document number, Type and Part.

The output will be: list of PP Orders that this document is attached to.

It looks like, the Bapi you sugest will give me details about the document itself.

I do not succees with this Bapi . It asks for OBJECTTYPE (I tried AFPO or AFKO) and OBJECTKET (I put the order number). Am I doing something wrong?

Besr regards,

Shimshon

MangeshP
Active Contributor
0 Kudos

Hi Shimshon

Please Check this BAPI

  • BAPI_DOCUMENT_GETDETAIL2 *.

You can also get the list in CV04N Transaction.

Just Go to CV04N > Object Link Tab Page

Put Search Parameters and get the List of Document which are linked to search parameters in CV04N.

By the way what functionality are you exploring by BAPI.

With Regards

Mangesh Pande

Former Member
0 Kudos

Thanks Mangesh,

The Bapi worked, and show me the orders to witch the document is attached in the header level, but not as PRTs attached to the operations.

How can I see the operations that the documents is attached to as PRTs?

To your questions u2013 what do I need it for u2013

We want to give the engineers a tool u2013 when they make a change to some document, they would be able to see what PP orders that are already in the shop, would be affected..

Thanks,

Shimshon

MangeshP
Active Contributor
0 Kudos

Hi Shimshon

Welcome!!!

Hey Can you tell me what is PRT? Never heard?

With Regards

Mangesh Pande

Former Member
0 Kudos

PRT is a document or tool witch is needed for the manufacturing process.

You usually attach it to an operation in the routing, and it is copied to the PP Order.

The worker can view the document from CO03

Shimshon

MangeshP
Active Contributor
0 Kudos

Hi Shimshon

I have gone through PP Orders in CO02( Change Order ).There are two assignments of SAP DIR ( Documents created in SAP DMS ).

1. First One is at the Header Level called Document Overview.

2. Second one is attached at Operations level as PRT.

When you link to Production Order in a particular DIR,It also has entries for Sequence , Operation and description.So you will to develope a Z report to display all Production Order for Document.

So your Search Parameters will be Production Orders for Documents ( For Example )

Document -


to -


Hope I have answered your query. Get back if any thing left

With Regards

Mangesh Pande

Former Member
0 Kudos

We are using both u2013 Documents in the header level and documents in the operation's level (PRT). My question is how to retrieve those operations and orders, once I know to identify the document (Like "where used" u2013 Document X, What orders and what operations it is attached to)

Best regards, Shimshon

Former Member
0 Kudos

Hi Mangesh

Bapi_document_getobjectdocs:

If the object I'm looking for is PP Order, The OBJECTTYPE will be PORDER

What will be the OBJECTKEY? What fields have to be concatenated in order to create the string?

Thanks, Shim

Former Member
0 Kudos

"How can I see the operations that the documents is attached to as PRTs?

We want to give the engineers a tool u2013 when they make a change to some document, they would be able to see what PP orders that are already in the shop, would be affected.."

You can try the following standard transactions to search for PRT Documents in orders.

CF12.....Use of Production Resources/Tools in Production Orders

CF22.....Production Resources/Tools Usage in Orders

Barry Vitovsky

Former Member
0 Kudos

Yes it is true,

My problem is that I should not use the standard transactions, I must add a field in a SmartForms which displays the number of Document Info Record(FID) for an order, so I want to know the table that contains the relationship between OT and FID ?

In the case of a Notice(Avis) I use the following query on the table :

"Select COUNT (*) from DRAD into WV_FID

where OBJKY = W_VIQMEL-QMNUM. "

I want to do the same for the OT?

"

Oui c'est vrais

Mon problème c'est que je ne dois pas utiliser les transactions standard, en fait je dois ajouter un champ dans un SMARTFORMS qui affiche le nombre de FID pour un ordre, et donc je veux connaître la table qui contient la relation entre OT et FID ??

Dans le cas d'un Avis j'utilise la requête suivante sur la table:

"Select COUNT(*) from DRAD into WV_FID

where OBJKY = W_VIQMEL-QMNUM."

Je veux faire de même pour l u2018OT ?

"

Thanks Vitovsky

Former Member
0 Kudos

I'm sorry, but I cannot help you with your programming, tables, etc.

My background is from the Functional User perspective. That is why I was able to provide suggested transactions.

Barry Vitovsky

Former Member
0 Kudos

Thanks Barry,

I found how to do it :

DATA WV_AUFPL  TYPE  CO_AUFPL.
 SELECT  SINGLE AUFPL FROM AFKO INTO WV_AUFPL
   WHERE AUFNR = WV_AUFNR.

 SELECT SINGLE COUNT( * ) from AFFH into WV_FID
   WHERE AUFPL = WV_AUFPL.

Rgds,

Adil

Former Member
0 Kudos

Hello,

Please check BAPI_DOCUMENT_GETDETAIL2

Rgds,

Jagruti