07-23-2010 6:50 AM
I have created a Z table with the following fields:
Mandt
Bukrs (Company Code)
Saknr (General Ledger)
Created_by
Created_on
As per the requirement, whenever a new entry is created in the Z table, by default 'created by' and 'created on' field should be populated in the Z table.
For eg.
When I'll do an entry with Bukrs = 7000 and Saknr = 123456 and my table entry should look like
Company_Code General_Ledger Created_by Created_On
7000 123456 John <date-Time>
So how will I get Createdby and createdon field
Edited by: reshma.rbi on Jul 23, 2010 11:22 AM
07-23-2010 7:17 AM
Hi,
You need to create one FM for inserting or updating your ZTABLE. Input should be BUKRS and SAKNR.
Inside that Fm, Insert or update the table with SY-UNAME for created by, SY_DATUM for Created on....
Ask your developers to use your FM to update or insert the table
Another way is, create Table maintenance and write your code to insert created by and created on.......
07-23-2010 8:34 AM
Hi ,
For this you have to use Table Events in SE11.
create a table maintainance generator for the ztable u have created.
goto utilities click on table maintainance generator.
give auth. grp as &nc&
give ur table name as function group.
goto environments ->modification->events.
create a new entry use 05 event before updating to the database.
write ur form routine there. to populate the field with counter.
Steps to implement
07-23-2010 2:18 PM