Max Titov IV @ TechSplice

The most beautiful music of all is the music of what happens.
  • Home
  • About

Posts Tagged ‘user’

25 Nov 2009

SAP: deleted users [when/who]?

Actions that are done to a user profile, be that creation, modification or deletion are tracked in a table USH04.

The field PROFS will reflect each of the actions referencing the following characters:

A: add

M: modify

D: delete

Simply enter the user you are interested in and see what has occured over the year.

25 November, 2009 at 13:08 by Max

Tags: administration, configuration, sap, security, user
Posted in SAP/ABAP | No Comments »

18 Nov 2008

The sales order … is currently being processed by user …

An inbound IDOC was failing due to the error [described in the title].  Some research resulted in the following results:

TR: SM12 displayed a list of locked elements in the system.

TR: SM04 displayed a list of logged in users in the local system.

TR: SM08 displayed a list of logged in users in all the app-servers [not just the current system].

Unfortunately in my case non of the mentioned transactions above helped me narrow down where the user was locking the system – in the end I’ve requested for the user to log back in and kill his session with a TR: /nex.

18 November, 2008 at 8:59 by Max

Tags: fix, order, problem, process, sales, sap, SAP/ABAP, solution, user
Posted in SAP/ABAP | No Comments »

23 Aug 2007

Retrieving user data [ABAP]

In this example we will explore attempts to gather information from SAP database tables. We aim to collect user information and display it on the screen using SELECT statements and internal TABLE variables.

For the purposes of this example we will be collecting information from the table USR02.
In order to access that information the program must explicitly reference the desired tables at the header of the file.

REPORT Z_USERS.
* Import the USR02 table in to the program.
TABLES: USR02.

Next we want to create a internal table for gathering information from the database. We will create a local variable table ‘USERS’ with two attributes. All variables used within the ABAP/4 program must be declared with DATA statements.

DATA
<name> Name of the variable
TYPE or LIKE Indicates the variable type.
VALUE Initial value of the variable.
DECIMAL Can only be used with appropriate types. Specifies the number of decimal places in the number.

* Define USERS internal table.
DATA: BEGIN OF USERS OCCURS 100,
NAME LIKE USR02-BNAME,
DATE LIKE USR02-TRDAT,
END OF USERS.

BEGIN OF USERS OCCURS 100: Specifies the name of the variable table ‘USERS’ and states that the table will contain a 100 records.
The two attributes that the table will contain are NAME and DATE with the same characteristics as BNAME and TRDAT attributes found in the USR02 table. The BNAME attribute stores the name of the user while the TRDAT attribute stores when the user previously logged in.
END OF USERS is a closing statement for the BEGIN statement.

The next step will be to use a SELECT statement to gather information from the USR02 table and populate our local USERS table.

* Select information from the USR02 table.
SELECT * FROM USR02.

CLEAR USERS.
* Copy over the information.
USERS-NAME = USR02-BNAME.
USERS-DATE = USR02-TRDAT.
APPEND USERS.

ENDSELECT.

The SELECT statement acts like a ‘loop’ if you will. Record by record the information will be gathered up from the USR02 table and transfered in to the USERS table. After going through each record the data is added to the USERS table using the APPEND statement.

Now that we gathered some information about the users that reside in the system lets display that info.
First lets find out how many users there are in total. To do that we will use the DESCRIBE statement that will return an attribute LENGTH of all the fields in the USER table.

* How many users were retrieved.
DESCRIBE TABLE USERS LINES LENGTH.
* Output the information on the screen.
WRITE: / 'There are: ', LENGTH, 'USERS'.

The final step in our program will include the displayed of collected user information.
Using a LOOP statement we will go through each element in the USERS table and output the information on the screen.

LOOP AT USERS.
WRITE: / USERS-NAME, USERS-DATE.
ENDLOOP.

Notice that the LOOP statement terminates with a corresponding ENDLOOP statement.

And this completes our glimpse of data gathering in SAP.

23 August, 2007 at 20:43 by Max

Tags: data, interface, sap, SAP/ABAP, user
Posted in SAP/ABAP | No Comments »

  • Subscribe using FeedBurner
  • Cloud

    abap adobe animation basic beautiful builder camera code configuration contribution design development digital engineering fix flash Flex friends function images interesting lesson new paypal Photography php problem problems program programmer review sap SAP/ABAP sdk setup soap software solution story system tables transaction transports user video

    WP Cumulus Flash tag cloud by Roy Tanck and Luke Morton requires Flash Player 9 or better.

  • My Links

    • Cooking
    • Gallery
    • Resume
  • Online Tools

    • Airline Ticket Search
    • Estimate Shipping Cost [from US]
    • Link your Blog
  • Software Engineering Blogs

    • Adam Goucher
    • Joel on Software
    • The Third Bit
    • Wide Awake Developers
  • Categories

    • Everyday stuff
    • Flex
    • Photography
    • SAP/ABAP
    • Short Stories
    • Software Engineering
    • Web Development
  • Gallery

    Roy Tanck's Flickr Widget requires Flash Player 9 or better.

Max Titov IV @ TechSplice is proudly powered by WordPress
Design & code by Jonk
Entries (RSS) and Comments (RSS).
Podcast Powered by podPress (v8.8)