ME52N: Purchase Requisition Change GL Account Number
Requirement: ABAP auto-change the GL Account field number in a Purchase Requisition after the Material Group is changed.
Background: This custom logic has been successfully applied to all types of Purchase Requisitions using BADI ME_PROC_REQ_CUST, with the exception of a Purchase Requisition type that is called a 'Service Limits'. There are differences that are important to note between a 'Service Limits' Purchase Requisition and the other Purchase Requisitions that had custom code added without any problems.
1)This type of Purchase Requisition uses a item category of 'B', and the logic has a tendency to flow through SAP differently.
2)This type of Purchase Requisition's GL Account number is under-intensified on the 'item' subscreen, and cannot be changed manually on that screen like the others..
3)In order for the GL Account to be changed manually, or for the GL Account to be changed once my code has changed the GL Account Number, the user must select the 'Limits' tab and select the Account Assignment arrow, then a popup appears where the GL Account can be changed manually, or, my coded GL Account number change then occurs.
Problem: I want the custom code to be able to change the GL Account NUmber without having to go into thge 'Limits' tab, where the icon has to be selected. I believe the problem is that the field is protected, because it displays as under-intensified, thus, preventing my new GL Account NUmber from displaying. I also have the subsequent SAP code below that appears to reject set_exkn because protect is set to 'X'.
CODE1: Is my custom code.
CODE2: Is the SAP code that my will flow into where this field appears to be unchangeable.
My question:
I am thinking that this GL Account field is protected and cannot be changed because it is under-intensified on the subscreen on the Purchase Requisition. Can it be changed with custom code, a way to 'unprotect it'? Or, are there settings that should be changed in SPRO for the Purchase Requisition to allow this functionality to change the GL Account number.
Thank-You
(CODE1)
METHOD IF_EX_ME_PROCESS_REQ_CUST~PROCESS_HEADER.
*Purchase Requisition Item Declarations
DATA: LT_ITEMS TYPE MMPUR_REQUISITION_ITEMS.
DATA: LS_ITEM TYPE MEREQ_ITEM.
FIELD-SYMBOLS: <FS_ITEM> TYPE LINE OF MMPUR_REQUISITION_ITEMS.
*Purchase Requisition Accounting Declarations.
DATA: LT_ACCT TYPE MMPUR_ACCOUNTING_LIST.
DATA: LS_ACCT TYPE EXKN.
DATA: LS_SETX TYPE MEPOACCOUNTING_DATAX.
FIELD-SYMBOLS: <FS_ACCT> TYPE LINE OF MMPUR_ACCOUNTING_LIST.
CALL METHOD IM_HEADER->GET_ITEMS
RECEIVING
RE_ITEMS = LT_ITEMS.
LOOP AT LT_ITEMS ASSIGNING <FS_ITEM>.
LS_ITEM = <FS_ITEM>-ITEM->GET_DATA( ).
LT_ACCT = <FS_ITEM>-ITEM->IF_ACCT_CONTAINER_MM~GET_ITEMS( ).
LOOP AT LT_ACCT ASSIGNING <FS_ACCT>.
LS_ACCT = <FS_ACCT>-MODEL->GET_EXKN( ).
LS_ACCT-SAKTO = 'N500300 '.
LS_SETX-SAKTO = 'X'.
<FS_ACCT>-MODEL->SET_EXKN( LS_ACCT ).
<FS_ACCT>-MODEL->SET_EXKNX( LS_SETX ).
ENDLOOP.
ENDLOOP.
ENDMETHOD.
(CODE2)
METHOD if_accounting_model_mm~set_exkn.
DATA: ls_buffer LIKE LINE OF my_data_input_buffer,
ls_bufferx LIKE LINE OF my_data_input_bufferx,
l_buffered TYPE sy-subrc,
l_data_old TYPE exkn,
l_data_oldx TYPE mepoaccounting_datax,
l_data_newx TYPE mepoaccounting_datax,
l_indx TYPE sy-tabix. "1478013
*PROTECT EQ 'X'
CHECK my_state->protect EQ mmpur_no.
Edited by: Tom Matys on Dec 12, 2011 10:55 AM
Your PO release strategy must have been based on Cost Center as one of characteristics.
Pl check & confirm.
Regards
Bhavesh Mistry
Similar Messages
-
Change GL account number in PO
Hello Friends,
I have tried to change GL account number in PO throug executing a program(BAPI). I am getting error message "Releases already effected are liable to be reset". What could be the reason for this?
Please help me in resolving this issue.
Thanks,
RamYour PO release strategy must have been based on Cost Center as one of characteristics.
Pl check & confirm.
Regards
Bhavesh Mistry -
Dear All,
How Can I change bank account number from 11 characters to 12 characters for a company code?
I tried to do it in FBZP but I have an error message that I can't do this change for a bank account number longer than 11 characters.
Is there any solution?
Thanks
FerdawsHi,
@Innamuri : I tried to maintain the correct bank account in alternative account number but I don't know why there is also an inconsistency between bank account number and alternative account number.
For example : In bank account number (X00000XXYYX) --- > 11 characters
and In alternative account number (0X00000XXYYX) -
> 12 characters
I understand from that that the first number 0 in bank account number it's not maintained.
@ Smuthyala : We haven't the right to do this.
Ferdaws -
Tell me the link between Purchase Requisition and Sales Order Number
tell me the link between Purchase Requisition(MEREQ_TOPLINE-BANFN_EXT) and Sales Order Number(COBL-KDAUF)
Hi Puja,
If you have created sales order for matrial which has both procurement type,after MRP run you will get
planned order.This planned order you can convert to purchase requisition for external procurement or
subcontracting.
You will find sales order number in details of purchase requisition ( ME52N) in Account assignment tab.
Hope this help you.
Regards,
Raja -
Hi Experts,
I need a report for a purchase requisition, if a PO already exists against it, I need to change the flag for the purchase requisiton as closed. Is there any sample report to do this?I have checked BAPI BAPI_REQUISITION_CHANGE. Do I need to also use the GETDETAIL bapi before using this.
Please advise.
Thanks,
RajIs the sales order a third party order?
What did you change in sales order?
What want you change in PR ?
Do you get an error or why do you ask?
If you got a message, which one? Double click the message and post the message number here. -
Purchase Requisitions Change after create existing document.
Hi,
We want to restrict System not allow to change the Purchase Requisition Quantity after create the existing document RFQ & PO with reference of PR.
Regards
AamirDear Amir,
We had also faced same problem in our organization 2 years back. Then I have change the screenlayout of ME52N as follows.
SPRO -> Materials Management -> Purchasing - > Purchase Requistion -> Define screeen layout at document level -> Create new entry ME52N by coping ME52. Then goto qty & price field, tick the Qty field as display.
Due to this changes in PR Qty in ME52N will not be possible. If any change in PR QTY before creation of PO has to be done then user has to delete that line item in ME52N & create new line item in same PR.
This development is successful at our end.
Regards,
Shekhar Gaikwad.
SAP MM Consultant -
Link between purchase requisition and dms document number(cv02n)
hai all,
can u pls tell me how to get the dms document number(cv02n) for a given purchase requisition number?
is there any table?
Tnx & Regardstry table DRAD with field DOKOB = EBAN. The number of PR is in field OBJKY.
Teresa -
Purchase order referencing released purchase requisition change
Hello everybody
When we create a purchase order making reference to a released purchase requisition, I can still make changes on the item such as changes on the quantity, value, etc.
We would like to know how to restrict changes of purchase orders when they reference purchase requisitions already released.
Thank you in advance and regards,
Alejandra Álamo B.Hi,
For meeting this requirement, you will have to create a new document type (If the same requirement exists for all the Purchase Orders, do not create additional document types).
Next create a new Field selection where the fields that are copied from PR are made non editable (display). Assign this field selection to the new document type.
Normally, PO fields are editable because the quantity and values may change based on the negotiation with vendor, or to club requirements.
Hope this helps
Priyadarshi -
Hi All,
Do you know the transaction code, if available to change the GL account number? I'm not talking about GL account description change through FS00.
If the existing gl account number is 123445, I want to change it to AB12345. Is it possible?
Regards
PrabinHi,
GL Account number being the primary key in the table, you cannot change the GL Account number.
You might however, create a new GL account and transfer the balance/line items from this GL Account into the new one.
But, if you can be more specific as why you want to change the GL Number, we might give you a better suggestion..
Caio
Raghu -
HI Experts,
At present my employees are having 13 digit bank account number,Now another zero has been added as prefix from feb 2008.
When im trying to prefix zero it is showing error """Change earliest retroactive account date 01.09.2005 acc to payroll area n6"""
Where should i change this....
Regards,\
SaiHi Sikindar,
Thanks for your guidance.
Instead of create option i tried with change mode.Thats why it s throwing error.Anyway thank u very much.
Regards,
Sai. -
Changing the account number through DTW.
Hello All,
wheather Its possible to replace the existing G/L account through DTW.
For example, Inventory account is '1021000'(Raw materials) in Inventory data tab in Item Master data. But I want to replace it to '1021201'(Industrial Stock account). Please suggest wheather its possible through DTW.
Thanks,
PratheevirajTo be honest with you, I never try and never think it is a workable solution to set account by item level. In your case, you need to change account for >700 items today. If you are lucky that you have not posted any inventory transactions, then you can DTW to upload the new changed account. However, once you have transactions, you will be locked up for any future change. In my opinion, Item Level account will only apply to very few special items. It should not be used for common items. If possible change your account to by Item Groups would be a better solution.
-
hi ,
im just a mom, not very computer savy.....however, I need to change the payment method my daughter uses to purchase things on her ipad due to the fact that the current one is expiring. ie: for such things like songs and games, etc.
I would appreciate any help as how to do so.
THanksOn a computer's iTunes you should be able to edit the payment info by going into the Store > View Account menu option (if you are not logged into the account that your daughter is using then Store > Sign menu option to log out of the currently logged in account ; that will then change to a Store > Sign In option so that you can log into her account) and log into the account (enter the account's password and click View Account on the popup)
And on the account's details page there should be a payment link.
If you are doing it on your iPad then tap on your id in Settings > iTunes & App Store (if not logged into her account then log out of your account via the popup that you get and then log in with her account) and tap on 'View Apple ID' on the popup and log into the account - that should also give you a payments link on your account's page.
Changing payment info : http://support.apple.com/kb/HT1918 -
Purchase Order changing Sales Order Number when printing.
Hi all,
I have a client who is trying to print a Purchase Order and when they go to Print or do a Print Preview the Sales Order number changes from 2259 to 2264. The customer is using SAP Business 1 2005A SP01 Pl43. If anyone has heard of this or can help us out that would be greatly appreciated. Thanks!
Jeff Haldeman
Support OneHi Jeff
That sounds strange .May be it is a bug .lets find out some of the issue before you log to sap support or patch upgrade .
1 Are you using formatted search . check the setup - if it is automatically refresh when field altered or changes,
--If that's the case , change it into display saved user -defined values .
give a shot and see what happens
Thank you
Bishal -
Problem in Purchase requisition change BAPI
Hi Techies
When using BAPI "BAPI_REQUISITION_CHANGE" for AFS for changing the purchase requistion, the changes are getting affected only in the purchase request line item level. whereas the schedule line (AFS size Breakup) is not getting changed.
CALL FUNCTION 'BAPI_REQUISITION_CHANGE'
EXPORTING
number = va_prno
TABLES
requisition_items_old = it_itmold
requisition_items_new = it_itmnew
REQUISITION_ACCOUNT_OLD =
REQUISITION_ACCOUNT_NEW =
REQUISITION_TEXT_OLD =
REQUISITION_TEXT_NEW =
return = it_return
requisition_afs_data_old = it_liold
requisition_afs_data_new = it_linew.
IF sy-subrc = 0.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
EXPORTING
wait = 'X'.
CLEAR: flg.
ENDIF.
please suggest.
Regards,
PRASAD.Hi,
Yes, in the AFS BAPI these parameters are exits..
ofcourse,i got the Solution..
Best regards
Prasad.EV -
When I got my ipad, i was still using an old isp, but i changed isp when we moved. When i attempt to use cloud features, i get prompted for the password for the old email account which I turned off 2 years ago, What should I do?
Thanks,
my active email accounts are [email protected] and [email protected]Hi vegasbob,
You need to do the following:
1. Go to Manage Your Apple ID https://appleid.apple.com/cgi-bin/WebObjects/MyAppleId.woa/
2. Sign on with your current Apple ID and password
3. Change your Apple ID to the old email address, but do not verify it - Save Changes
4. Go to Setting>iCloud on your iPad, and scroll to the bottom of the screen and click on Delete Account
5. It will ask you for your password to turn off Find My iPhone, type in your current password
6. Delete iCloud account
7. Go back to Manage Your Apple ID and sign in with the changed ID and current password
8. Change your Apple ID back to your current ID - Save Changes
9. Go back to Settings>iCloud and sign on with your current Apple ID
You should be all set.
Cheers,
GB
Maybe you are looking for
-
How to get the output of a single command from multiple servers using power shell
Hi All, I have a requirement in my project, wherein I have to find the database list on each server which has autoshrink option is enabled. Below is the query which I'm using and I want to automate it in such a way that, I can give the input to power
-
Relinking image files in Indesign CS6 library
I have a customer that has created more than 300 page templates stored as libary files.They are distributing the library across multiple properties in their organization and in each instance, on the "other" servers, all images linked in the template
-
Hi I need to send the mail from the SAP Inbox (i.e. from Tcode SO01) to my personal mail account. In Tcode SO01, I am creating a new message and under recipient I am providing my mail ID (for eg [email protected]), and I am selecting Recp. Type as In
-
No connection to Integration Builder (only generic data Visible) Call Functions LCR_LIST_BUSINESS_SYSTEMS
-
Possible values for WDY_ATTRIBUTE_FORMAT_PROP-DATE_FORMAT?
Hi, where can I lookup possible values for formatting a date typed field using WDY_ATTRIBUTE_FORMAT_PROP-DATE_FORMAT? I did not find any documentation so far.