10-17-2008 6:35 AM
BINARY_RELATION_CREATE_COMMIT
can anybody tell me what is the use of this FM
10-17-2008 7:15 AM
hi,
BINARY_RELATION_CREATE_COMMIT function module is used to link the object id to the invoice document.
please refer the series of the steps below which will explain it better.....
1. Read the file into memory. For that we can use OPEN DATASET if the file is on a server or FM GUI_DOWNLOAD if the file is on a local PC (e.g. on your laptop's C: drive). Don't worry that it's a Word file - if you use the binary mode, it will be OK.
2. Get a "folder ID" by calling SO_FOLDER_ROOT_ID_GET. Now this part is rather confusing (does this FM actually create a folder somewhere?), but just look at it this way - you're getting an address of where your file contents will be stored in SAP, that's all.
3. Put the file into that "folder" by calling SO_OBJECT_INSERT. The content of the file is passed to this function module in a table.
4. The FM SO_OBJECT_INSERT will give you the "object ID" for your file. At this point your file is already stored somewhere in the depths of SAP Office and the last step is to link this "object ID" to the invoice. To do so, we call the FM BINARY_RELATION_CREATE_COMMIT.
regards,
Alpa.
10-17-2008 6:36 AM
10-17-2008 6:38 AM
no documentation available for that
thats why i have posted
if you know that pls tell me
10-17-2008 6:43 AM
check with the following link
http://friendlyabaper.blogspot.com/2008/07/oh-my-gos.html
i hope it will help u.
10-17-2008 6:42 AM
i think the use of this FM is
Attach Documents to Any Custom Program Using Generic Object Services (i am not sure)
check this link
Edited by: srinivasu bv on Oct 17, 2008 7:42 AM
10-17-2008 7:15 AM
hi,
BINARY_RELATION_CREATE_COMMIT function module is used to link the object id to the invoice document.
please refer the series of the steps below which will explain it better.....
1. Read the file into memory. For that we can use OPEN DATASET if the file is on a server or FM GUI_DOWNLOAD if the file is on a local PC (e.g. on your laptop's C: drive). Don't worry that it's a Word file - if you use the binary mode, it will be OK.
2. Get a "folder ID" by calling SO_FOLDER_ROOT_ID_GET. Now this part is rather confusing (does this FM actually create a folder somewhere?), but just look at it this way - you're getting an address of where your file contents will be stored in SAP, that's all.
3. Put the file into that "folder" by calling SO_OBJECT_INSERT. The content of the file is passed to this function module in a table.
4. The FM SO_OBJECT_INSERT will give you the "object ID" for your file. At this point your file is already stored somewhere in the depths of SAP Office and the last step is to link this "object ID" to the invoice. To do so, we call the FM BINARY_RELATION_CREATE_COMMIT.
regards,
Alpa.