300 likes | 491 Views
Using CATT Scripts. Creating Multiple R/3 Userids. Bill Willis SAP America – Irvine, CA. The need for using CATT Scripts. Many times the R/3 Security Administrator is asked to add a large number of userids at one time, especially just before a Go-Live on a new R/3 Implementation
E N D
Using CATT Scripts Creating Multiple R/3 Userids Bill Willis SAP America – Irvine, CA
The need for using CATT Scripts • Many times the R/3 Security Administrator is asked to add a large number of userids at one time, especially just before a Go-Live on a new R/3 Implementation • In most cases all the necessary userids have been given to the Security Administrator in a large spreadsheet • It would take many man hours (sometimes days) to manually key-in or cut-and-paste the userids to accomplish this task • Using the following procedure, this task could be accomplished in less than 30 minutes! The following example is very simplistic as we are demonstrating how to create the userid with a first and last name in the address screen, along with a password. It is possible to expand the recorded CATT Script variants to include assigned profiles and activity groups, full address information, cost center and accounting information, as well as, user parameters to suit customer requirements.
Create your CATT Script • Run transaction SCAT • Enter the name of your Test case (must begin with Z) • Click on the TCD button 2 1
Setup for Recording your CATT Script • Enter transaction SU01 – Do not press <Enter> • Right-Click in dialog box next to transaction code • Select ‘End for Commit Work’ – Do not press <Enter> • Click on ‘Record’ icon (yellow arrow) 1 2 4
Recording Keystrokes and Mouse clicks • In the next steps it is importing not to press the <Enter> key as this keystroke as well as any mistakes you make in the recording phase will be recorded into your test case CATT Script. • If you make a mistake, simple click on the Save icon in the SU01 screen and the Stop Recording icon as shown on page 8 to terminate the recording of the keystrokes. This is why we selected the ‘End for Commit’ option on the previous slide. This tells the CATT Script recorder to end recording when a commit work (clicking the Save icon) has been processed. • To restart the recording simple do not save your test case and click on the green back-arrow until you get to the SCAT initial screen as depicted on page 3. You must then follow the instructions on page 3 to restart the recording.
Recording your CATT Script • Enter the userid as shown – Do not press <Enter> • Click on the ‘Create’ icon 2 1
Recording your CATT Script • Enter Last name – Do not press <Enter> • Enter First name – Do not press <Enter> • Click on ‘Logon data’ tab 3 1 2
Recording your CATT Script • Enter the password ‘initpass’ – Do not press <Enter> • Re-enter the password ‘initpass’ – Do not press <Enter> • Click on ‘Save’ icon • Click ‘Stop Recording’ 3 1 4 2
Saving your CATT Script • Enter Development class as shown • Click on ‘Local object’ 1 2
What is next? • Now that we have recorded the transaction steps, we must modify the recorded CATT Script variants so that input can be taken from an external variant file. • We will be modifying the variable part of our input and replace what we typed in with the ampersand character ‘&’ • This will signal the CATT Script to accept input from an external variant file – in our case a desktop file modified with Excel. • The external variant file created for us is a delimited text file • After making our modifications, we must save it as a delimited text file so that CATT Script can process the input
Maintaining your CATT Script variants • Click the button next to your test case to fill the name into the Test case dialog box • Click on the ‘Change’ icon 2 1
Maintaining your CATT Script variants • Double click on the TCD Function field
Maintaining your CATT Script variants • Click on ‘Field list’ button
Maintaining your CATT Script variants • Change the User name field from ‘sample’ to ‘&’ • Click on Next screen icon 2 1
Maintaining your CATT Script variants • Change Last name ‘sample’ to ‘&’ • Change First name ‘user’ to ‘&’ • Click Next screen icon 3 1 2
Maintaining your CATT Script variants • No need to change the ‘initpass’ password. • Click green back-arrow until the Save icon (floppy disk) is available 2 All users created with this script will received the same initial password of ‘initpass’ 1
Exporting your external variant file • After clicking on the green back-arrow, click on the Save icon • Next, select menu path: Goto Variants Export Defaults 2 1
Exporting your external variant file • Enter local filename to be saved – must be of type ‘TXT’ • Click on Transfer 1 2
Modifying the external variant file • Start Microsoft Excel, select menu File Open • Select file type ‘.txt’ • Click on the file you saved from the previous slide • Click in Open icon 2 3 1
Modifying the external variant file • Being that you are reading into Excel a delimited text file simply click on the Finish icon to format the text file for Excel
Modifying the external variant file • Enter the userids into column C, Last names in column D, and the First names in column E of the userids you wish to create as shown • There is no limit to the number of userids you can create • Click on the Save icon 3 1
Modifying the external variant file • Click on the Save icon • Click on Yes • Click on Yes 2 3 1
Running your CATT Script • Go to the transaction SCAT initial screen • Click on the button next to your test case if the name does not appear in the ‘Test case’ dialog box • Click on the Execute icon 2 1
Running your CATT Script • In the Processing mode box, select the ‘Errors’ radio button • In the Variants box, select the ‘External from file’ radio button • Click on the Choose button 3 2 1
Running your CATT Script • Select the text file you just modified with Excel • Click on the Execute icon 1 2
Running your CATT Script • When the CATT Script execution has completed, the resultant log file will be displayed • Click on the imbedded HTML link inserted below to display the log file of the CATT Script we just created and executed To view this link you must exit the PowerPoint Slide Show mode and double-click on this link 1 2
What’s next? • Now that we successfully run our CATT Script, we should check to see if the userids have been created as expected. • There are many ways to view userids, but the easiest method is to use transaction SUIM, the Security Information System transaction. • In our test case, we created all of our new users with userids beginning with ZUSER. • What might be easy for reviewing newly created userids is to create a user group NEWUSER and assign the userids to this group when recording you script. This is accomplished in the ‘Logon data’ tab of transaction SU01. When you have entered the user’s password, you can then enter the user group NEWUSER. • Transaction SUIM can select user accounts by a specific login group. • To remove the user group NEWUSER from a number of userids in a mass fashion, you can now use transaction SU10 to accomplish this.
Verify userids have been created • Run transaction SUIM • Make selections as shown 2 1 4 3
Verify userids have been created • Our new userids have been created!
Further reference information • See your SAP On-Line Help under the section Basis / Development / Testing • Search SAPnet messages for CATT or SCAT • Search the SIG under Development or Security for CATT