Step by step batch input

Hi friends,
Please tell me about how to create a batch input from beginning to end.
How can I achieve the entry of the data?
sm35 or shdb is used to record the transaction steps?
One says sm35, the other says shdb?
Step by step?
Thanks in advance.

Hi,
BDC option
ABAP Runtime Environment (BC-ABA)
Batch Data Communication option.
BDC options define the processing mode for a batch input session.
Examples of modes used for processing sessions are:
•     Display all records.
•     Display for error dialogs only.
•     Process session in the background.
•     Process session on the screen.
Purpose
During data transfer, data is transferred from an external system into the SAP R/3 System. You can use data transfer when you:
•     Transfer data from an external system into an R/3 System as it is installed.
•     Transfer data regularly from an external system into an R/3 System. Example: If data for some departments in your company is input using a system other than the R/3 System, you can still integrate this data in the R/3 System. To do this, you export the data from the external system and use a data transfer method to import it into the R/3 System.
Implementation considerations
Before creating your own data transfer program, you should use the Data Transfer Workbench to find the data transfer programs that are delivered by SAP.
The Data Transfer Workbench 
Purpose
The Data Transfer Workbench supports the automatic transfer of data into the R/3 System.
The Workbench is particularly useful for large amounts of data. It guarantees that data is transferred efficiently and ensures that data in the R/3 System is consistent.
Features
The Data Transfer Workbench provides the following functions:
•     Integration of standard data transfer programs
•     Registration and integration of your own data transfer programs
•     Various techniques to load data into R/3.
The data is read from a transfer file in SAP format and loaded into the R/3 System using one of the techniques below:
•     Administration and organization of data transfer projects
•     Tools for analyzing the required SAP structures
•     BAPI interface
•     Batch input
•     Direct input
Integration
SAP applications support the data transfer of numerous SAP business objects. The data transfer program specifies the data format definition that is necessary to import the data into the R/3 System. Adapt your conversion program for exporting the data from the external system to this definition.
Once the data has been exported, you can import it into your system using a generated data transfer program.
Features
•     Data transfer from other, external systems
•     Generation of data transfer programs
•     Generation of function modules that can be used as an interface to the R/3 System
Initial Data Transfer 
Prerequisites
Before you start the initial data transfer, you should have answered the following questions:
•     Which business objects are to be transferred?
The objects to be transferred depend on the business applications you are using. If you are using sales and distribution processing, for example, you should transfer the material master records as well as the sales master records .
•     How should the business objects be transferred?
Various techniques are available to load the data into the R/3.
Process Flow
The process of transferring data can be divided into the steps:
1.     Preparing the data transfer
•     Analyzing and Cleaning Legacy Data
•     Analyzing SAP Structures
•     Developing Programs, Function Modules and BAPIs
•     Creating a Program or FM for Data Extraction
•     Creating a Mapping Program
•     Registering Programs, Function Modules and BAPIs
1.     Executing the data transfer
•     Organizing the Transfer in Projects
•     Executing Data Transfer Runs, monitoring (CCMS) and processing (log)
•     Checking transferred objects in R/3 using a function module or report (task type AUD).
The graphic below describes the steps involved in transferring the data:
ThThe The Data Transfer Workbench is an integrated project management for all the required steps involved in transferring data to your R/3 System.
You need to use programs or function modules for the various steps. SAP provides a range of BAPIs for loading data into R/3.
You could also carry out all the steps, except for loading the data via BAPIs, without using the Data Transfer Workbench.
In the first step you extract the existing data from a source system into a file and clean it there, if necessary.
To load data into R/3 you need a transfer file in an appropriate SAP format.
Using a mapping program you have to map the extracted data to the structures of the transfer file.
To load the data into the R/3 System one of the Techniques is used depending on the type of business object . I f more than one of these techniques is provided for a particular object type, you should read the documentation to find out what the different uses are .
Once you have created a project, you can start a run. The tasks of the run definition are processed in order.
After the data has been successfully loaded into the R/3 System, it can be checked here.
Result
You have transferred the data into the relevant R/3 application and checked it here.
Data Transfer 
Purpose
During data transfer, data is transferred from an external system into the SAP R/3 System. You can use data transfer when you:
•     Transfer data from an external system into an R/3 System as it is installed.
•     Transfer data regularly from an external system into an R/3 System. Example: If data for some departments in your company is input using a system other than the R/3 System, you can still integrate this data in the R/3 System. To do this, you export the data from the external system and use a data transfer method to import it into the R/3 System.
Implementation considerations
Before creating your own data transfer program, you should use the Data Transfer Workbench to find the data transfer programs that are delivered by SAP.
Integration
SAP applications support the data transfer of numerous SAP business objects. The data transfer program specifies the data format definition that is necessary to import the data into the R/3 System. Adapt your conversion program for exporting the data from the external system to this definition.
Once the data has been exported, you can import it into your system using a generated data transfer program.
Features
•     Data transfer from other, external systems
•     Generation of data transfer programs
•     Generation of function modules that can be used as an interface to the R/3 System
Data Transfer Methods 
You can use the following methods to transfer data:
•     Direct input: With direct input, the SAP function modules execute the consistency checks. However with batch input, these consistency checks are executed with the help of the screens. This means that direct input has considerable performance advantages.
•     CALL TRANSACTION: Data consistency check with the help of screen logic.
•     Batch input with batch input sessions : Data consistency check with the help of screen logic.
Difference between Batch Input and CALL TRANSACTION
If the direct input cannot be used for your task, this makes creating a data transfer program easier since the underlying transactions ensure that the data consistency checks are executed.
In the case of an error during the data transfer (if data records are inconsistent, for example), you can restart the transfer at the point in the program where the error occurred.
Batch input methods
With the batch input method, an ABAP program reads the external data that is to be entered in the R/3 System and stores the data in a "batch input session". The session records the actions that are required to transfer data into the system using normal SAP transactions.
When the program has generated the session, you can run the session to execute the SAP transactions in it. You can explicitly start and monitor a session with the batch input management function (by choosing System  Services  Batch input), or have the session run in the background processing system.
CALL TRANSACTION methods
In the second method, your program uses the ABAP statement CALL TRANSACTION USING to run an SAP transaction. External data does not have to be deposited in a session for later processing. Instead, the entire batch input process takes place inline in your program.
The information in Choosing Data Transfer Methods will help you decide which is the best data transfer method.
Data Transfer: Overview of Batch Input  
Prerequisites
Before beginning the initial data transfer, you should answer the following questions:
•     Which business objects are to be transferred?
The business objects to be transferred depend on the business applications that you will be using. If you are using sales and distribution processing, for example, you must transfer the material masters as well as the sales documents from your legacy system.
•     How are the business objects to be transferred?
The data can be transferred either manually or automatically, using an SAP data transfer program or using your own transfer program.
Process flow
During the initial data transfer, data from the external system is converted into a sequential data transfer file and then transferred into the R/3 System using an SAP data transfer program. The data transfer file is the prerequisite for successfully transferring data as it contains the data in a converted format that is suitable for the R/3 System.
1.     Check to see if an SAP data transfer program (direct input, batch input or CALL TRANSACTION) exists for this data using the Data Transfer Workbench. Refer to the notes for this transfer program.
If no SAP data transfer program exists, proceed as follows:
2.     Determine the SAP transactions that a user would use to enter data records.
3.     Record these transactions using the batch input recorder. Ensure that you have filled all of the relevant fields with data.
4.     Use this data to generate a data transfer program.
5.     Display the Data Transfer Workbench and create your own data transfer object.
6.     Now follow the steps for transferring data using the Data Transfer Workbench.
The Transaction Recorder 
Use
You can use the transaction recorder to record a series of transactions and their screens.
Features
You can use the recording to create
•     Data transfer programs that use batch input or CALL TRANSACTION
•     Batch input sessions
•     Test data
•     Function modules.
The recording can be executed several times. The screens are run in exactly the same way as they were run during the recording.
You can edit recordings that you have already made using an editor.
Activities
1.     To display the batch input initial screen, choose System  Services  Batch input Edit.
2.     Choose Recording. The system now displays the initial screen of the batch input recorder.
3.     Make a recording of the relevant transactions.
4.     Generate one or several of the objects named above.
Special features
•     F1 -, F4 - and self-programmed F1 - and F4 help ( PROCESS ON HELP-REQUEST , PROCESS ON VALUE-REQUEST ) are not recorded. The same applies to all commands in the System and Help menus.
•     Error and warning dialogs are not recorded. This means that only the OK code field and the field contents that lead to successful further processing in the current screen.
•     " COMMIT WORK " in a transaction flow indicates the successful end of the transaction as regards batch input. The recording also ends successfully.
•     " LEAVE TO TRANSACTION " in the course of a transaction indicates that it is not suitable for batch input. The recording is terminated.
•     In ScreenPainter screens, movements in the scrollbar are not recorded. Use the function keys F21-F24 for positioning.
  Recording Transactions 
The recording forms the basis of generating data transfer programs, sessions, test data and function modules.
Procedure
1.     Display the initial screen of the batch input recorder.
2.     Assign a name to your recording.
3.     Choose Create.
4.     On the subsequent dialog box, enter the transaction code that you want to record and choose Continue.
The system displays this transaction.
5.     Execute the transaction in the usual way.
6.     When you have finished processing the transaction, the system displays an overview of the transaction and your input.
Choose Get transaction if no errors occurred while the transaction was being recorded.
If you do not want to keep the last recording that you made, go to the next step.
7.     Choose Next transac. If you want to record an additional transaction. Then continue from point 4.
8.     Save your recording when you have finished.
Recording 
Once you have recorded the transaction, you can process it again later.
Procedure
1.     Display the initial screen of the batch input recorder (Transaction SHDB).
2.     Choose Overview.
The system displays an overview of all recordings.
3.     Position the cursor on the relevant recording and choose Execute.
4.     Choose one of the following processing modes:
A : Display all screens.
E : Display errors only. In the case of an error, the system displays the screen on which the error occurred. Once this error has been corrected, the system continues to process the recording until the next error occurs.
N : No display. The recording is not processed visibly.
5.     Choose the update mode:
A : Asynchronous update
S : Synchronous update
L : Local update
6.     You begin to process the recording when you choose Enter to exit the dialog box. When the recording is complete, the system displays a log that lists the name of the transaction, the system field SY-SUBRC and the system messages that were output.
Using the Recording Editor 
The recording editor contains functions that you can use to edit your recordings.
Procedure
1.     Display the initial screen of the batch input recorder (Transaction SHDB).
2.     Choose Overview.
The system displays an overview of all recordings.
3.     Position the cursor on the relevant recording and choose Change.
4.     The following functions are available on the overview that the system displays:
• Delete transaction from the recording: This deletes the selected transaction.
• Add a new transaction to the recording: The transaction is added at the end of the recording.
• Editing: You can edit the current recording.
If you choose Editing, proceed as follows:
5.     The system displays an editor where you can add and delete individual lines. You can also change the contents of these lines.
6.     If these editor functions are insufficient for your requirements, you can choose Export to download the recording onto your presentation host and use a PC editor to edit it there.
7.     Choose Import to import this file back into the R/3 System. Ensure that the file is still in the correct format.
8.     Choose Check to ensure that the edited version of the recording is still syntactically correct.
9.     Save your changes to the recording when you have finished editing it.
Generating Batch Input Sessions From the Recording 
The data from the recording is transferred into batch input sessions that you can process for test purposes using the usual mechanisms.
Prerequisites
Before you can generate a batch input session, you must record the transactions through which the data is to enter the R/3 System. You use the batch input recorder to do this.
Procedure
1.     Display the initial screen of the batch input recorder (Transaction SHDB).
2.     Choose Overview.
The system displays an overview of all recordings.
3.     Position the cursor on the relevant recording and then choose Generate session.
4.     Enter a session name, a user with whose authorizations the session is to be processed, the identification whether the session is to be deleted once it has been processed and the processing date.
5.     Choose Continue to exit the dialog box.
You have generated a batch input session that uses the same data for the input fields that you entered when you created the recording. You can now process this as usual.
Generating Data Transfer Programs 
Prerequisites
Before you can generate a data transfer program, you must record the transactions using which the data is imported into the R/3 System. You use the batch input recorder to do this.
Procedure
1.     Display the initial screen of the batch input recorder (Transaction SHDB).
2.     Choose Overview.
The system displays an overview of all recordings.
3.     Position the cursor on the relevant recording and choose Create program.
4.     On the following screen, specify a program name.
5.     You can also choose how the maintained field contents of the recorded screens are to be filled:
• Transfer the values that were used during the recording. If you require a flexible data transfer, you must modify this program.
• Set the parameters of the input values to be maintained and import these values from a data file. To set the parameters, the system creates a data structure and imports the data records from an external file into this data structure. The program assumes that the external file has been adapted to this data structure.
6.     If you have decided to set parameters for the input values to be maintained, it is useful if you create a test file when you generate the program. To do this, flag the checkbox and enter a name for the test file. For more information, see creating a test file.
7.     Choose Continue.
8.     The system displays the attribute screen of the program editor. Choose the relevant attributes here and save the program.
Result
You have now generated a data transfer program that you can use to import data into the R/3 System. The program can execute the data transfer using batch input or CALL TRANSACTION .
Generating Function Modules 
Prerequisites
Before you can generate a data transfer program, you must record the transactions using which the data is imported into the R/3 System. You use the batch input recorder to do this.
Procedure
1.     Display the initial screen of the batch input recorder (Transaction SHDB).
2.     Choose Overview.
The system displays an overview of all recordings.
3.     Position the cursor on the relevant recording and choose Create function module.
4.     On the subsequent dialog box, enter a function module name, a function group and a short text for the function module. Exit the dialog box by choosing Continue.
The system automatically creates the function module.
Result
You have now generated a function module that you can use as an interface for your R/3 System. As well as information relevant for the data transfer, the function module's import interface has a parameter for each input field of the transaction recorded.
Using Function Modules 
Prerequisites
The function module was generated from a recording made using the batch input recorder.
Procedure
1.     Cal the function module.
2.     Supply the generic interface of the function module:
CTU : Flag whether the data is to be transferred using batch input method CALL TRANSACTION USING . The system generates a batch input session if this flag is not set.
MODE : Processing mode:
A     Display all
E     Display only errors
N     No display
UPDATE : Update mode:
S     Synchronous
A     Asynchronous
L     Local update
GROUP : (If CTU is already specified): Name of the batch input session to be generated
USER : (If CTU is already specified): User with whose authorizations the session is to be processed
KEEP : Specifies whether this session is to be deleted once it has been processed
HOLDDATE : Specifies the earliest processing date for the error session
NODATA : Defines the NODATA character
3.     Supply the function module's special interface.
For each input field that was filled when you recorded the transactions, the system creates an import parameter. The recorded value is used as the default value for this import parameter.
Creating Test Files 
To test the data transfer program that you have created, you can create a data record in a sequential file. This data record contains all the field contents from the recording that are relevant to the data transfer in the format required by the data transfer program. It is therefore useful if you align the format of your conversion program data file with the format of the test file.
Prerequisites
Before you can generate a data transfer program, you must record the transactions using which the data is imported into the R/3 System. You use the batch input recorder to do this.
Procedure
1.     Display the initial screen of the batch input recorder (Transaction SHDB).
2.     Choose Overview.
The system displays an overview of all recordings.
3.     Position the cursor on the relevant recording and choose Create test data.
4.     Enter a test file and exit the dialog box by choosing Continue.
You have now created a test file.
If the test file you have specified already exists, the system appends the new data record.
If you do not specify the path, the system archives the test file in the working directory of the current application server.
Executing the Data Transfer 
Purpose
You generally use the Data Transfer Workbench to execute the data transfer. The following section describes how you transfer data directly using the batch input method.
Prerequisites
You require a data transfer program. This may be an SAP data transfer program, or you can create your own program.
Process flow
1.     Provide the data to be imported in a data file. Ensure that the data is in the correct format.
2.     If you are using a generated data transfer program, you can choose a data transfer method.
If you are only dealing with one data record, you can import this directly using a generated function module.
3.     Execute the data transfer program.
4.     Analyze the program and correct any errors that occur.
Writing Data Conversion Programs 
The data conversion program is responsible for the following tasks:
•     Converting the data that is to be transferred into the R/3 System as required by the SAP data structure or transactions that you are using.
If you are using an SAP batch input standard program, you must generate the data structure from the SAP standard data structure (see generating an SAP data structure).
If you develop your own batch input program, the data structure is determined by the R/3 System when the program is generated. Generate a test file from the recording and align the format of your conversion program with the format of the test file.
A conversion may be necessary for data type and length data type and length. The data type required by all standard SAP batch input programs is C, character data. You can find the required field lengths either in your analysis of the data declaration structure of the generated batch input program or in the data structures that you generate.
•     The data is exported in SAP format to a sequential file. The batch input program in the R/3 System reads the data in from this file.
Process flow
The tasks involved in writing a data transfer program are shown in the diagram and list below.
Writing Data Conversion Programs 
The data conversion program is responsible for the following tasks:
•     Converting the data that is to be transferred into the R/3 System as required by the SAP data structure or transactions that you are using.
If you are using an SAP batch input standard program, you must generate the data structure from the SAP standard data structure (see generating an SAP data structure).
If you develop your own batch input program, the data structure is determined by the R/3 System when the program is generated. Generate a test file from the recording and align the format of your conversion program with the format of the test file.
A conversion may be necessary for data type and length data type and length. The data type required by all standard SAP batch input programs is C, character data. You can find the required field lengths either in your analysis of the data declaration structure of the generated batch input program or in the data structures that you generate.
•     The data is exported in SAP format to a sequential file. The batch input program in the R/3 System reads the data in from this file.
Process flow
The tasks involved in writing a data transfer program are shown in the diagram and list below.
Selecting a Data Transfer Method  
When you transfer data in ABAP, you have three options to submit the data for the data transfer. Only the first two methods can be recommended without reservation. The third method, by way of CALL DIALOG, is outmoded. CALL DIALOG is less comfortable than the other methods. You should use it only if you must.
•     Use the CALL TRANSACTION USING statement
Summary: With CALL TRANSACTION USING, the system processes the data more quickly than with batch input sessions. Unlike batch input sessions, CALL TRANSACTION USING does not automatically support interactive correction or logging functions.
Your program prepares the data and then calls the corresponding transaction that is then processed immediately.
The most important features of CALL TRANSACTION USING are:
o     Synchronous processing
o     Transfer of data from an individual transaction each time the statement CALL TRANSACTION USING is called
o     You can update the database both synchronously and asynchronously
The program specifies the update type
o     Separate LUW (logical units of work) for the transaction
The system executes a database commit immediately before and after the CALL TRANSACTION USING statement
o     No batch input processing log
•     Create a session on the batch input queue.
Summary: Offers management of sessions, support for playing back and correcting sessions that contain errors, and detailed logging.
Your program prepares the data and stores it in a batch input session. A session is a collection of transaction data for one or more transactions. Batch input sessions are maintained by the system in the batch input queue. You can process batch input sessions in the background processing system.
Your program must open a session in the queue before transferring data to it, and must close it again afterwards. All of these operations are performed by making function module calls from the ABAP program.
The most important aspects of the session interface are:
o     Asynchronous processing
o     Transfers data for multiple transactions
o     Synchronous database update
During processing, no transaction is started until the previous transaction has been written to the database.
o     A batch input processing log is generated for each session
o     Sessions cannot be generated in parallel
The batch input program must not open a session until it has closed the preceding session.
•     Use the CALL DIALOG statement
Summary: Not recommended if you can enter data by way of sessions or CALL TRANSACTION USING.
Your program prepares data for a sequence of dialog screens, and calls a dialog module for immediate processing.
The most important aspects of the CALL DIALOG interface are:
o     Synchronous processing
o     Transfers data for a sequence of dialog screens
o     No separate database update for the dialog
A database update occurs only when the calling program executes a commit operation.
o     Shares LUW with calling program
o     No batch input processing log is generated
Executing Data Transfer Programs 
Procedure
If you are using an SAP data transfer program, follow the procedure specified in the program documentation.
If you are using a generated data transfer program, proceed as follows:
1.     Start the data transfer program.
2.     Decide which batch input method you want to use for the data transfer.
a) CALL TRANSACTION USING:
You must specify the:
– Processing mode: You use this parameter to specify whether processing should take place in the background or in dialog mode.
Possible values are:
A     Display all
E     Display only errors
N     No display
– Update mode: This parameter determines how the data is to be updated:
Possible values are:
S     Synchronous
A     Asynchronous
L     Local update
– Error session: Here you have the option to specify a session name for a batch input session in which data is to be written in the case of an error. You can use this to identify incorrect data records after the batch input program has run and to import the records into the R/3 System once you have corrected them.
If you are creating an error session, you must also specify:
– User: Specify the user with whose authorizations the sessions are processed.
– Keep session: This specifies whether or not the session should be deleted once it has been processed.
– Lock date: Specify the processing date for the error session.
b) Generate session:
– Session name: Specify a name for the batch input session to be generated.
– User: Specify the user with whose authorizations the sessions are processed.
– Keep session: This specifies whether or not the session should be deleted once it has been processed.
– Lock date: Specify the processing date for the error session.
3.     Specify a character that is to be used as the NODATA character.
4.     Specify the path of the data file from which the data is to be imported into the R/3 System.
5.     Execute the program.
6.     If you have generated a session, or if errors occurred in CALL sTRANSACTION USING mode, you must now edit the generated sessions. You can find information on this in BC - System services in batch input sessions.
Batch Input Authorizations 
You do not need special authorization - other than the ABAP run time authorization (authorization object S_PROGRAM - to run a program that creates batch input. Any user can create batch input sessions.
Starting processing for a session once it is in the queue is another matter, however. You can find more information on this in batch input sessions.
Creating a Session with BDC_OPEN_GROUP  
Use the BDC_OPEN_GROUP function module to create a new session. Once you have created a session, then you can insert batch input data into it with BDC_INSERT.
You cannot re-open a session that already exists and has been closed. If you call BDC_OPEN_GROUP with the name of an existing session, then an additional session with the same name is created.
A batch input program may have only one session open at a time. Before opening a session, make sure that any sessions that the program closes any sessions that it previously had opened.
BDC_OPEN_GROUP takes the following EXPORTING parameters:
•     CLIENT
Client in which the session is to be processed.
Default: If you don't provide a value for this parameter, the default is the client under which the batch input program runs when the session is created.
•     GROUP
Name of the session that is to be created. May be up to 12 characters long.
Default: None. You must specify a session name.
•     HOLDDATE
Lock date. The session is locked and may not be processed until after the date that you specify. Only a system administrator with the LOCK authorization for the authorization object Batch Input Authorizations can unlock and run a session before this date.
Format: YYYYMMDD (8 digits).
Default: No lock date, session can be processed immediately. A lock date is optional.
•     KEEP
Retain session after successful processing. Set this option to the value X to have a session kept after it has been successfully processed. A session that is kept remains in the input/output queue until an administrator deletes it.
Sessions that contain errors in transactions are kept even if KEEP is not set.
Default: If not set, then sessions that are successfully processed are deleted. Only the batch input log is kept.
•     USER
Authorizations user for background processing. This is the user name that is used for checking authorizations if a session is started in background processing. The user must be authorized for all of the transactions and functions that are to be executed in a session. Otherwise, transactions will be terminated with "no authorization" errors.
The user can be of type dialog or background. Dialog users are normal interactive users in the R/3 System. Background users are user master records that are specially defined for providing authorizations for background processing jobs.
Adding Data to a Session: BDC_INSERT  
Use the BDC_INSERT function module to add a transaction to a batch input session. You specify the transaction that is to be started in the call to BDC_INSERT. You must provide a BDCDATA structure that contains all of the data required to process the transaction completely.
BDC_INSERT takes the following parameters:
•     TCODE
The code of the transaction that is to be run.
•     POST_LOCAL
Parameter to update data locally. If POST_LOCAL = ‘X’, data will be updated locally.
(refer to the keyword documentation of SET UPDATE TASK LOCAL for more information)
•     DYNPROTAB
The BDCDATA structure that contains the data that is to be processed by the transaction.
DYNPROTAB is a table parameter in the function module.
Closing a Session: BDC_CLOSE_GROUP  
Use the BDC_CLOSE_GROUP function module to close a session after you have inserted all of your batch input data into it. Once a session is closed, it can be processed.
Function Module BDC_CLOSE_GROUP
Exception parameters
Parameter     Function
NOT_OPEN     Client
QUEUE_ERROR     Internal use
BDC_CLOSE_GROUP needs no parameters. It automatically closes the session that is currently open in your program.
You must close a session before you can open another session from the same program.
You cannot re-open a session once it has been closed. A new call to BDC_OPEN_GROUP with the same session name creates a new session with the same name.
Processing Batch Input Sessions 
When you create a batch input session, it remains in the batch input queue until it is explicitly started. Session processing can be started in two ways:
•     An on-line user can start the session using the batch input menu options. (To access the batch input options, choose System  Services  Batch Input.)
•     You can submit the background job RSBDCSUB to start a session in background processing. If several sessions have the same name, RSBDCSUB starts them all.
It’s possible to coordinate the generation and execution of a session in the background processing system.
You can, for example, schedule both the batch input program and RSBDCSUB in the background. If you designate the batch input job as the predecessor for RSBDCSUB, then RSBDCSUB will be started automatically when the batch input job successfully completes.
Alternatively, you can schedule both the batch input program and RSBDCSUB as job steps in a single background job. In this case, however, RSBDCSUB is started even if the batch input program should terminate abnormally.
For detailed information about processing batch input sessions, see Managing Batch Input Sessions in the System Services guide.
Frequent Data Transfer Errors 
The most frequent errors include:
•     The BDCDATA structure contains screens in incorrect sequence.
•     The BDCDATA structure assigns a value to a field that does not exist on the current screen.
•     The BDCDATA structure contains a field that exceeds the specified length.
General guidelines
You should be aware of the following guidelines when you create sessions and call transactions or dialogs:
•     You must provide data for all required fields on a screen.
•     You can only specify the initial data for a screen. The system does not accept input as a response to a warning or an error message.
•     If there is more than one possible screen sequence for a transaction or dialog, your program specifies the screen sequence for the transaction. You must transfer all screens that the dialog user sees to the selected screen sequence. This applies even if the screen itself is not used to input data.
Direct Input  
To enhance the batch input procedure, the system offers the direct input technique, especially for transferring large amounts of data. In contrast to batch input, this technique does not create sessions, but stores the data directly. It does not process screens. To enter the data into the corresponding database tables directly, the system calls a number of function modules that execute any necessary checks. In case of errors, the direct input technique provides a restart mechanism. However, to be able to activate the restart mechanism, direct input programs must be executed in the background only. To maintain and start these programs, use program RBMVSHOW or Transaction BMV0.
Examples for direct input programs are:
Program     Application
RFBIBL00     FI
RMDATIND     MM
RVAFSS00     SD
RAALTD11     AM
RKEVEXT0     CO-PA
Pls reward points.
Regards,
Ameet

Similar Messages

  • Lsmw  step by step procedure using   batch input method

    hi,
    lsmw  step by step procedure using   batch input method

    Step-by-Step Guide for using BAPI in LSMW
    Note! The screen prints in this article are from ECC 5.0. They may differ slightly in other versions.
    Introduction:
    This document details the usage of BAPI in LSMW. We have used the example of migration of the purchase order data into SAP.
    Pre-requisites:
    It is assumed that the reader of this article has the minimum knowledge required on the Business Object, BAPI, Message Types and IDoc Types.
    Step-by-Step Procedure:
    Details of the BAPI used in this scenario:
    Business Object: BUS2012
    Method: CreateFromData
    Details of Message Type and Basic IDoc Type:
    Message Type: PORDCR
    Basic IDoc Type: PORDCR02
    Let’s have a look at the BAPI first, before proceeding to the LSMW:
    1. Go to Transaction BAPI
    2. Click on Search Button
    3. Enter the value “BUS2012” and select “Obj.type(Technical Object Name”
    4. Press ENTER
    5. Following screen appears:
    6. On the left side of the screen, Expand the “PurchaseOrder”.
    7. Select “PurchaseOrder” and double-click on the same for details.
    Building LSMW using BAPI:
    1. Go to Transaction LSMW.
    2. Enter the Project, Subproject and Object information and click on CREATE.
    3. Enter the descriptions for Project, Subproject and Object.
    4. Now select Settings à IDoc Inbound Processing
    5. “IDoc Inbound Processing” screen appears. Enter the required details as shown below:
    6. Click on “Activate IDoc Inbound Processing”.
    7. Click on “Yes” when prompted for “Activate IDoc Inbound?”
    8. Hit on “Back” to return to the main screen.
    9. Click on Continue (F8). Following Screen appears:
    10. Select the Step 1 “Maintain Object Attributes” and select “Execute”.
    11. Select the radio button “Business Object Method” and enter the following details:
    Business Object: BUS2012
    Method: CreateFromData
    Hit ENTER
    12. Save and click on BACK button. Following information message is displayed.
    13. Now select step 2 “Maintain Source Structures” and click “Execute”.
    14. In this step, we need to maintain the source structure. In our example, lets consider the example of a file with 2 structures Head and Item data as shown below:
    Click on Create and name the source structure as HEADERDATA. Now select HEADERDATA and click on “Create” again to create the child structure. Following popup appears:
    Select “Lower Level” and click on Continue. Enter the Item data structure name.
    Click Save and hit BACK button to go to the main screen.
    15. Select step 3 “Maintain Source Fields” and hit execute.
    16. Enter the fields as shown below:
    17. Click SAVE and return to main screen.
    18. Select step 4 “Maintain Structure Relations” and click Execute.
    Select E1PORDCR and click on CREATE RelationShip. Following screen appears:
    Select HEADERDATA and hit ENTER
    Similarly do the same for the structure E1BPEKKOA, E1BPEKPOC and E1BPPEKET.
    Click Save and return to main screen.
    19. Select the step “Maintain Field Mapping and Conversion Rules” and click on execute. Maintain the Field Mapping as seen below:
    20. Select step 7 “Maintain Source Files” and provide the link for the test file created. (Create a test file with the same structure as defined earlier).
    Save and return to main screen.
    21. Select the step “Assign Files” and click on Execute.
    Assign the file provided to the source structure. Here the same file is provided for both the structures.
    Save and return to the main screen.
    22. Select the step “Read Data” and click on Execute.
    Click on Execute.
    Return to the main screen.
    23. Select the step “Display read data” and click on execute.
    Click on the structure name to get the field level values.
    24. Return to main screen and now select “Convert Data”.
    25. Return to the main screen and select “Display Converted data”.
    26. Return to main screen and select “Start IDoc generation”.
    27. Now select the step “Start IDoc Processing” on the main screen.
    28. Return to main screen and click on “Create IDoc overview”. Here the data record and status records of the IDoc could be viewed
    It is given in screen shot.
    http://www.****************
    http://www.sapbrainsonline.com/TUTORIALS/TECHNICAL/LSMW_tutorial.html
    http://www.sapbrain.com/TOOLS/LSMW/SAP_LSMW_steps_introduction.html
    http://esnips.com/doc/8e732760-5548-44cc-a0bb-5982c9424f17/lsmw_sp.ppt
    http://esnips.com/doc/f55fef40-fb82-4e89-9000-88316699c323/Data-Transfer-Using-LSMW.zip
    http://esnips.com/doc/1cd73c19-4263-42a4-9d6f-ac5487b0ebcb/LSMW-with-Idocs.ppt
    http://esnips.com/doc/ef04c89f-f3a2-473c-beee-6db5bb3dbb0e/LSMW-with-BAPI.ppt
    http://esnips.com/doc/7582d072-6663-4388-803b-4b2b94d7f85e/LSMW.pdf
    Reward points if useful.

  • Creation of Batch Input for transaction C201

    Hello,
    Currently I am having a requirement to create a batch input session for tcode C201.
    Following steps we need to perform using batch input session:
    1. Go to tcode C201 and enter material and Plant.
    2. Then click on choose template and give Mater Recipe option.
    3. On next screen enter Recipe Group and Recipe.
    4. After that it will go to Copy Master Recipe screen and then giving status it will open other tabs like Operations, Materials etc.
    Now when I create recording, till step 3 it is continuing correctly. but when press enter after step 3 it goes to Create Mater Recipe instead of Copy..
    I got one SAP note 142022 but dont know how to implement this in my case.
    Can you please help me?
    Thanks and Regards
    Nishad

    As [Note 142022 - Batch input and CATT in recipe|https://service.sap.com/sap/support/notes/142022] explain, you have to add one step in your batch input with BDC_OKCODE "=TOFF" on the first dynpro so C201 will always use old screens which are batch-input compatible. (First check [Note 365051 - OK code TON does not work when creating recipes|https://service.sap.com/sap/support/notes/365051] is implemented on your system)
    SAPLCPDI 4000
                  BDC_CURSOR RC271-PLNNR
                  BDC_OKCODE =TOFF
    Regards,
    Raymond

  • LSMW Create Batch Input Session question

    Hi all
    when I use LSMW to upload data. every step is OK, but at the NO. 13 step ' 13 Create Batch Input Session', it always set the 'Display Trnacts per BI Folder' field a default value '1' .I must clear the defautl value and let the field to black so I can create ONE session.
    why it always set a default value '1' in the 'Display Trnacts per BI Folder' field ??
    anybody can help me?
    thanks a lot!!

    Hi,
    => Looks like you havent mentioned the TCODE that you are using whilst recording. There is a field specific to TCODE in the step 'Maintain Field Mapping and Conversion Rules'. Double Click on the field, a dialog opens, give your TCODE in capitals.
    => Check if you have mapped all the fields that you want to upload using LSMW. You could have missed mapping few target fields with their source fields.
    => Remove any unnecessary structure relations in step 4 - 'Maintain Structure Relations'.

  • LSMW  Create Batch Input Session

    Hi all
    when I use LSMW to upload data. every step is OK, but at the NO. 13 step ' 13 Create Batch Input Session', it always set the 'Display Trnacts per BI Folder' field a  default value '1' .I must clear the defautl value and let the field to black so I can create ONE session.
    why it always set a default value '1' in the 'Display Trnacts per BI Folder' field ??
    anybody can help me?

    It shows the no. of transactions covered in a particular session. Like if you have 1000 records in your load file and if u put 500 transactions as value then it will create 2 sessions of 500 each. And if you leave it blank then by default also it will create 1 session......
    Best Luck,
    Ravin

  • PIR - LSWM Error in create batch input session

    Hi
    i made a conversion program Purchasing info record through Standard object / Direct Input in that Step 13 : Create Batch input session when i execute the Batch Input session i am getting the following error message
    Transaction 00000001 : no transaction code transfered.
    Please help me to solve this issue
    Thanks & Regards,
    mani.

    Hi
    Everything is working perfectly till STEP 10 : " Display Read Data"
    once if i convert it it was not populating the correct one. i cant find the T.Code ,Material Number & Indictor for Purchasing Info record.
    Please help me to solve thi s issue
    Thanks & Regards,
    Mani.

  • Problem in running batch input session

    Hello Guys i developed a lsmw object .in step 13 after executing  create batch inputsession a session is created and i can see the session created but when i go to step 14 run batch input session .i couldnt find session there and eventually can not run session can any body help me please .

    Hi priya,
    in 13step session is created for test data.
    if session is created the message will be display like this " 1 batech input n number of record are created".
    if like message will display 14th step automatically run the session ifnot there is problem with in u flat file or miss match with some fileds.
    check it corrected than run the u lsmw project.
    i think now it will work.
    Reward is usefull.
    Thank's.
    Patil

  • Step by step instruction for Using LSMW Recoding method for Material Master

    Guys,
    Can some one explain step by step procedure for uploading the materials master data to R/3 by using LSMW Recoding method. By the time you reply I will go through the rule of uploading the data..
    Thanks guys,
    Dhanu.

    Hi,
    The Legacy System Migration Workbench (LSMW) is a tool recommended by SAP that you can use to transfer data once only or periodically from legacy systems into an R/3 System.
    The LSM Workbench covers the following steps:
    (1)Read the legacy data from one or several files (e.g. spreadsheet tables, sequential files)
    (2)Convert the data from source format to target format
    (3)Import the data using standard interfaces (Batch Input, Direct Input, BAPI, IDoc).
    The Steps for LSME are:
    Example: Customer Master upload:
    LSMW to Update Customer Master Records with Transaction Recording
    Call Legacy System Migration Workbench by entering transaction code LSMW. Every conversion task is grouped together as Project / Subproject / Object structure. Create a Project called LSMW_DEMO and a Subproject as CUSTOMERS and Object as CUST_REC
    Step 1: Maintain Object attributes
    In this example, you will be updating the customer master records with the help of recording a transaction (XD02). Choose radio button Batch Input Recording and click on the recording overview icon to record the R/3 transaction. Enter the Recording name as XD02_REC, the description as Customer Master Updates Recording, and the transaction code as XD02.
    Step 2. Maintain Source Structures
    Give a name and a description to the source structure
    Step 3. Maintain Source Fields
    In this step, you need to list what fields are present in the source structure. The easiest way is to click on u2018Table Maintenanceu2019 icon to enter Fieldname, Type and Length for each field
    Step 4: Maintain Structure Relations
    Execute a step to u2018Maintain Structure Relationsu2019. Since, there is only one Source and Target Structure, the relationship is defaulted automatically.
    Step 5: Maintain field mapping and conversion rules
    Field RF02D-D0310 represents that you chose u2018Sales viewu2019 for the customer Master screen accordingly its value should be set to X. Keep your cursor on field RF02D-D0310 and click on Constant rule icon to choose the constant value of u2018Xu2019.
    If your source file already has the field value, you choose rule u2018Source Fieldu2019.
    Keep cursor on field u2018KUNNRu2019 and click on u2018Assign Source fieldu2019 icon to choose source field CUSTOMER from structure XD02S
    Step 6: Maintain fixed values, translations, user-defined routines
    You can also maintain re-usable translations and user-defined routines, which can be used across conversion tasks. In this case, that step is not required.
    Step 7: Specify files
    In this step, we define how the layout of the input file is. The input file is a [Tab] delimited with the first row as field names. It is present on my PC (local drive) as C:\XD02.txt.
    Step 8: Assign files
    Execute step u2018Assign Filesu2019 and the system automatically defaults the filename to the source structure.
    Step 9: Read data
    In this step, LSMW reads the data from the source file (from your PCu2019s local drive). You have the option to read only selected rows and convert data values to Internal format.
    Step 10: Display read data
    This step is optional. If required, you can review the field contents for the rows of data read.
    Step 11: Convert data
    This is the step that actually converts the source data (in source format) to a target format. Based on the conversion rules defined, source fields are mapped to target fields.
    Step 12: Display Converted data
    Again this is an optional step to view how the source data is converted to internal SAP format
    Step 13: Create batch input session
    Once the source data is converted in an internal format, you can create a batch session to process updates.
    Step 14: Run Batch Input Session
    You can execute the BDC session by Run Batch input session. Executing a batch input session is a standard SM35 transaction for managing BDC sessions. Once you have successfully executed the batch input session, the customer master records are updated in the system. You can confirm this by viewing the customer master records (XD03).
    Follow the link for material master
    http://www.sap123.com/showthread.php?t=98
    Regards,
    Biju K

  • Lsmw Step by step procedure

    Hi Abap Gurus,
    I very new to abap and this site.
    Can any body provide the  step by step procedure in lsmw.
    I can give points to good answers.

    Hi rangamma,
    can U go through this info.
    Step-by-Step Guide for using LSMW to Update Customer Master Records
    Note! The screenprints in this article are from IDES Release 4.6. They may differ slightly in other versions.
    Call Legacy System Migration Workbench by entering transaction code LSMW. Every conversion task is grouped together as Project / Subproject / Object structure. Create a Project called LSMW_DEMO and a Subproject as CUSTOMERS and Object as CUST_REC as shown in Figure 1.
    Figure 1                Conversion Task with Project, Subproject and Object
    The main screen of LSMW provides wizard-like step-by-step tasks, as shown in Figure 2. To complete your data conversion, you need to execute these steps in sequence. Once a step is executed, the cursor is automatically positioned to the next step.
    Note that these steps may look different depending upon your Personal menu settings. You could make step numbers visible by ‘Numbers on’ icon or hidden by ‘Numbers off’ icon. You can execute a step by double-clicking on the row. Toggle icon ‘Doubleclick=Display’ or ‘Doubleclick=Edit’, makes the step in ‘display’ mode or ‘change’ mode.
    Figure 2 LSMW Wizard – initial screen
    Step 1: Maintain Object attributes
    In this example, you will be updating the customer master records with the help of recording a transaction (XD02). Choose radio button Batch Input Recording and click on the recording overview icon to record the R/3 transaction. Enter the Recording name as XD02_REC, the description as Customer Master Updates Recording, and the transaction code as XD02.
    Figure 3                Object type ‘Transaction Recording’
    The system calls the transaction code XD02 and prompts you to complete the Change
    Customer transaction, as shown in Figure 4. Enter the key customer information (I entered customer number 1000, sales organization 1000, distribution channel 01, and division 00) and choose ‘Sales’ view within ‘Sales area data’. Make changes to these three fields (I entered, sales office 1010, sales group 110, and customer group 01) and save the transaction.
    Figure 4                Transaction recording for Transaction Code ‘XD02’
    Once the transaction is completed, R/3 records the flow of screens and fields and saves the information, as shown in Figure 5.
    Default Values
    Field Names
    Figure 5                Transaction recording overview
    Note that the fields are populated with default values. The values you entered when you recorded the transaction are set by default.
    Note that if you have more fields in the recording than needed, you can remove them by clicking ‘Remove Screen field’ icon.
    Observe that the transaction-recording process stores field names in a technical format. By pressing the F1 key on individual screen fields and then pressing the F9 key, the system displays technical names. You then can replace the technical names with descriptive names. Double-click on the field RF02D-KUNNR and enter the name as KUNNR and the description as Customer Account Number and remove the default value. (See Figure 6.)
    Figure 6                Field attributes
    Similarly, double-click on all other fields with default values and make appropriate changes. Once you have made changes, the recording overview screen looks like what you see in Figure 7.
    Figure 7                Transaction Recording Overview – with screen field attributes
    Save your changes. When you go back to the initial screen, you will see that the initial screen steps have changed. Since you want to import data via the BDC method, the Direct Input and IDoc-related steps are hidden, as they are not relevant.
    Step 2. Maintain Source Structures
    Give a name and a description to the source structure (Figure 8). 
    Figure 8                Source Structure
    Step 3. Maintain Source Fields
    In this step, you need to list what fields are present in the source structure. The easiest way is to click on ‘Table Maintenance’ icon to enter Fieldname, Type and Length for each field  as shown in Figure 9. 
    Figure 9                Source fields of source Structure
    Note that your input file will have four fields as key fields and you need to update three fields in the system.
    Step 4: Maintain Structure Relations
    Execute a step to ‘Maintain Structure Relations’. (See Figure 10.) Since, there is only one Source and Target Structure, the relationship is defaulted automatically. 
    Figure 10  Structure Relation
    Step 5: Maintain field mapping and conversion rules
    Field RF02D-D0310 represents that you chose ‘Sales view’ for the customer Master screen accordingly its value should be set to X. Keep your cursor on field RF02D-D0310 and click on Constant rule icon to choose the constant value of ‘X’. 
    If your source file already has the field value, you choose rule ‘Source Field’. 
    Keep cursor on field ‘KUNNR’ and click on ‘Assign Source field’ icon to choose source field CUSTOMER from structure XD02S as shown in Figure 11.
    Figure 11 Assign source fields
    Similarly, assign ‘Source Field’ rules to the remaining fields. 
    Once all the fields are mapped, you should have an overview screen as shown in Figure 12.
    Figure 12 Field mapping and Conversion rules overview
    Step 6: Maintain fixed values, translations, user-defined routines
    You can also maintain re-usable translations and user-defined routines, which can be used across conversion tasks. In this case, that step is not required.
    Step 7: Specify files
    In this step, we define how the layout of the input file is. The input file is a [Tab] delimited with the first row as field names. It is present on my PC (local drive) as C:\XD02.txt. (See Figure 13.)
    figure 13 File attributes
    Create an Excel file (Figure 14) with your data and save it as a Tab-delimited text file on your local drive (C:\) and name it XD02.txt.
    Figure 14  Source data in Excel file (saved as Tab delimited file)
    Step 8: Assign files
    Execute step ‘Assign Files’ (Figure 15) and the system automatically defaults the filename to the source structure.
    Figure 15 Assign file to Source Structure
    Step 9: Read data
    In this step, LSMW reads the data (Figure 16) from the source file (from your PC’s local drive). You have the option to read only selected rows and convert data values to Internal format. 
    Figure 16 Read Data
    Step 10: Display read data
    This step (Figure 17) is optional. If required, you can review the field contents for the rows of data read.
    Figure 17 Display Read Data
    Step 11: Convert data
    This is the step that actually converts the source data (in source format) to a target format. Based on the conversion rules defined, source fields are mapped to target fields.
    Step 12: Display Converted data
    Again this is an optional step to view how the source data is converted to internal SAP format (Figure 18). 
    Figure 18 Display Converted Data
    Step 13: Create batch input session
    Once the source data is converted in an internal format, you can create a batch session to process updates (Figure 19). 
    Figure 19 Create Batch Input Session
    Step 14: Run Batch Input Session
    You can execute the BDC session by Run Batch input session. Executing a batch input session is a standard SM35 transaction for managing BDC sessions. Once you have successfully executed the batch input session, the customer master records are updated in the system. You can confirm this by viewing the customer master records (XD03).
    Note! Browsing thru these 14 steps, you may get a feeling that this is a very lengthy and time-consuming activity. However, for the purposes of demonstration, I have made it detailed. Although it looks lengthy, actually it takes hardly few hours from start-to-finish! After playing around with few simple LSMW scripts, you will find it so easy to change and create more complex ones.
    www.****************
    Rewards some points if it is helpful.
    Rgds,
    P.Nag

  • LSMW Issue at step -Run Batch Input Session

    Dear gurus,
                     While uploading service master through lSMW while processing the system prompts a message specifying "Buffertable not upto date" at Run Batch Input Session step .So please investigate what is missing/wrong.
    Wirth regards,
    Raj

    I dont think that this has directly something to do with LSMW.
    It is more related to the transaction your try to post in the batch input.
    Search OSS with the error message number. I had seen some notes for number SE001, but your message is actually twice in the message table, and you did not tell the message number.
    If it is message SE001, then you may find programm corrections in OSS.
    Otherwise just log out and in again and try, or open a message at OSS yourself if the problem still persists

  • LSMW last step.  Batch input????

    Hi all,
    I have successfully read the flat file and all the record is being read.  The last step is batch input and its showing the record read and everything...
    Now how do I go forward with the batch input and run it so that the respective data gets loaded to the transaction and to the database tables...
    If possible, can you experts give me the steps so that I can run the batch input, the last step of the LSMW.  Guys, I am really new to the SAP field, so please help me...
    Waiting for your replies.
    Thanks,
       -Ken C

    Have you gone through all these steps, particularly the bold ones?
       <b>Maintain object attributes
       Maintain source structures                     
       Maintain source fields                         
       Maintain structure relations                   
       Maintain field mapping and conversion rules</b>    
       Maintain fixed values, translations, user-define
       <b>Specify files                                  
       Assign files                                   
       Generate read program</b>                          
       Display read program                           
       <b>Read data</b>
       Display read data                              
       <b>Generate conversion program</b>
       Display conversion program                     
       <b>Convert data</b>
       Display converted data                         
       Check converted data against customizing       
       <b><i>Create batch input session
       Run Batch Input session
       Analyze erroneous transactions</i></b>
       Frame program for periodic data transfer       
    The last steps in bold and italics are the ones that will post the data.
    Srinivas

  • How to call SQL job step by step from windows batch file

    Hi ,
    I have a SQL agent job [POC_IOD_RunPkgJob]  which is being called from bat file with below command.
    Could you please tell me how to call only one step of this job, what command I need to mention in the batch file.
    SQLCMD -Sabcwi\SQLI01,51565 -E -Q"exec msdb.dbo.sp_start_job [POC_IOD_RunPkgJob]"

    Hi RameshDravid,
    Regarding your description,though not aware of what is the purposed to call only one step of that job, the below sample can somewhat help to achieve your requirement.
    --find the job steps
    SELECT
    steps.step_id,steps.step_name,steps.subsystem,steps.command
    FROM msdb.dbo.sysjobsteps steps
    JOIN msdb.dbo.sysjobs jobs
    ON steps.job_id = jobs.job_id
    WHERE jobs.name = 'youJobName'
    --find the command runs in that step, usually that is some command exec stored procedure
    SQLCMD -Sabcwi\SQLI01,51565 -E -Q"exec stored procedure found in the above query"
    If you have any question, feel free to let me know
    Eric Zhang
    TechNet Community Support

  • Oracle 10gR2 WebService Call-In & Call-Out via PL/SQL (Step-by-Step Guide)

    Hi Everyone,
    This guide is for those of you who tried to Call-In and Call-Out WebService via Oracle 10gR2 using PL/SQL but failed a couple of times, re-installed a couple of times and retry, got it to work but don't know what made it work scenarios.
    Hope this helps ;-)
    Thanks,
    Henry Wu
    Instructions on how to use Oracle10gR2 Webservice Call-Out feature (Oracle JAX-RPC DII - Dynamic Invocation (DII) APIs)
    PREREQUISITE
    =================================================================
    1. Download Oracle Database 10g Release 2 (10.2.0.1.0) (ZIP, ~655MB)
    http://www.oracle.com/technology/software/products/database/oracle10g/htdocs/10201winsoft.html
    http://download.oracle.com/otn/nt/oracle10g/10201/10201_database_win32.zip
    1.1 Choose Enterprise Edition
    2. Download 10.1.3.1 Callout Utility for 10g (R1 +R2) RDBMS (ZIP, ~13MB)
    http://download.oracle.com/technology/sample_code/tech/java/jsp/dbws-callout-utility-10131.zip
    2.1 Extract to C:\oracle\product\10.2.0\db_1\dbws_callout_utility_10131
    3. Download OC4J Standalone - Oracle Containers for J2EE (OC4J) 10g Release 3 (10.1.3.3) (ZIP, ~93MB; Pure Java—runs on all certified platforms)
    http://www.oracle.com/technology/software/products/ias/index.html (Download Site)
    http://download.oracle.com/otn/java/oc4j/101330/oc4j_extended_101330.zip
    3.1 Extract to C:\oracle\product\10.2.0\db_1\oc4j_extended_101330
    STEP-BY-STEP PROCEDURES
    =================================================================
    1. Prepare the database
    1.1 Connect to SYS account (or any account that can connect as SYSDBA)
    1.2 alter system set shared_pool_size=96M scope=both
    1.3 alter system set java_pool_size=80M scope=both
    1.4 ALTER USER SCOTT ACCOUNT UNLOCK;
    1.5 ALTER USER SCOTT IDENTIFIED BY "tiger";
    1.6 ALTER USER SCOTT QUOTA UNLIMITED ON USERS;
    1.7 GRANT PUBLIC TO SCOTT;
    1.8 GRANT Create Public Synonym TO SCOTT;
    2. Load Oracle SOAP client to SCOTT (for Oracle 10g Release 2 Database)
    2.1 Commands
    2.1.1 Open command prompt (cmd.exe)
    2.1.2 loadjava -u scott/tiger -r -v -f -genmissing -s -grant public C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\webservices\lib\soap.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\lib\dms.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\jlib\javax-ssl-1_1.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\lib\servlet.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\lib\mail.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\lib\activation.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\lib\http_client.jar C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\lib\ejb.jar
    2.1.3 It will take around 3 minutes and you will see "something" like the following when it completes (count may not be exact) :
    Classes Loaded: 909
    Resources Loaded: 75
    Sources Loaded: 0
    Published Interfaces: 0
    Classes generated: 0
    Classes skipped: 0
    Synonyms Created: 984
    Errors: 0
    2.1.3 Close this command prompt
    3. Load Oracle JAX-RPC client to SYS (for Oracle 10g Release 2 Database)
    3.1 Commands
    3.1.1 Open command prompt (cmd.exe)
    3.1.2 loadjava -u sys/oracle -r -v -f -genmissing -s -grant public C:\oracle\product\10.2.0\db_1\dbws_callout_utility_10131\sqlj\lib\dbwsclientws.jar C:\oracle\product\10.2.0\db_1\dbws_callout_utility_10131\sqlj\lib\dbwsclientdb102.jar
    3.1.2.1 It will take around 15 minutes and you will see "something" like following when it completes (count may not be exact) :
    Classes Loaded: 4027
    Resources Loaded: 81
    Sources Loaded: 0
    Published Interfaces: 0
    Classes generated: 61
    Classes skipped: 0
    Synonyms Created: 4108
    Errors: 0
    3.1.3 Close this command prompt
    4. Execute UTL_DBWS packages to SYS (for Oracle 10g Release 2 Database)
    4.1 Commands
    4.1.1 Connect to SYS account only
    4.1.2 Execute the following (in TOAD you should execute them as Script, press the "thunder" button)
    4.2.1 @"C:\oracle\product\10.2.0\db_1\dbws_callout_utility_10131\sqlj\lib\utl_dbws_decl.sql"
    4.2.2 @"C:\oracle\product\10.2.0\db_1\dbws_callout_utility_10131\sqlj\lib\utl_dbws_body.sql"
    4.2.3 CREATE PUBLIC SYNONYM utl_dbws FOR sys.utl_dbws;
    5. Call-out a free Web Service using SCOTT
    5.1 Commands
    5.1.1 Connect to user SCOTT with password of TIGER
    5.1.2 Copy and Paste the following "Anonymous Block" (sample #1) and execute it :
    5.1.2.1 It sould return "PL/SQL DII client return ===> Redwood City"
    declare
    service_ utl_dbws.SERVICE;
    call_ utl_dbws.CALL;
    service_qname utl_dbws.QNAME;
    port_qname utl_dbws.QNAME;
    operation_qname utl_dbws.QNAME;
    string_type_qname utl_dbws.QNAME;
    retx ANYDATA;
    retx_string VARCHAR2(1000);
    retx_double number;
    retx_len number;
    params utl_dbws.ANYDATA_LIST;
    l_input_params utl_dbws.anydata_list;
    l_result ANYDATA;
    l_namespace VARCHAR2(1000);
    begin
    -- open internet explorer and navigate to http://webservices.imacination.com/distance/Distance.jws?wsdl
    -- search for 'targetNamespace' in the wsdl
    l_namespace := 'http://webservices.imacination.com/distance/Distance.jws';
    -- search for 'service name' in the wsdl
    service_qname := utl_dbws.to_qname(l_namespace, 'DistanceService');
    -- this is just the actual wsdl url
    service_ := utl_dbws.create_service(HTTPURITYPE('http://webservices.imacination.com/distance/Distance.jws?wsdl'), service_qname);
    -- search for 'portType name' in the wsdl
    port_qname := utl_dbws.to_qname(l_namespace, 'Distance');
    -- search for 'operation name' in the wsdl
    -- there will be a lot, we will choose 'getCity'
    operation_qname := utl_dbws.to_qname(l_namespace, 'getCity');
    -- bind things together
    call_ := utl_dbws.create_call(service_, port_qname, operation_qname);
    -- default is 'FALSE', so we make it 'TRUE'
    utl_dbws.set_property(call_, 'SOAPACTION_USE', 'TRUE');
    -- search for 'operation soapAction' under <wsdl:operation name="getCity">
    -- it is blank, so we make it ''
    utl_dbws.set_property(call_, 'SOAPACTION_URI', '');
    -- search for 'encodingstyle' under <wsdl:operation name="getCity">
    utl_dbws.set_property(call_, 'ENCODINGSTYLE_URI', 'http://schemas.xmlsoap.org/soap/encoding/');
    -- search for 'binding style'
    utl_dbws.set_property(call_, 'OPERATION_STYLE', 'rpc');
    -- search for 'xmlns:xs' to know the value of the first parameter
    -- under <wsdl:message name="getCityResponse"> you will see the line <wsdl:part name="getCityReturn" type="xsd:string" />
    -- thus the return type is 'string", removing 'xsd:'
    string_type_qname := utl_dbws.to_qname('http://www.w3.org/2001/XMLSchema', 'string');
    -- in the line <wsdl:operation name="getCity" parameterOrder="zip">
    -- the parameterOrder is 'zip', thus we put in 'zip'
    -- the 'ParameterMode.IN' is used to specify that we will be passing an "In Parameter" to the web service
    -- the 'ParameterMode.IN' is a constant variable in the sys.utl_dbws package
    utl_dbws.add_parameter(call_, 'zip', string_type_qname, 'ParameterMode.IN');
    utl_dbws.set_return_type(call_, string_type_qname);
    -- supply the In Parameter for the web service
    params(0) := ANYDATA.convertvarchar('94065');
    -- invoke the web service
    retx := utl_dbws.invoke(call_, params);
    -- access the returned value and output it to the screen
    retx_string := retx.accessvarchar2;
    dbms_output.put_line('PL/SQL DII client return ===> ' || retx_string);
    -- release the web service call
    utl_dbws.release_service(service_);
    end;
    5.1.3 Copy and Paste the following "Anonymous Block" (sample #2) and execute it :
    5.1.3.1 It should return "PL/SQL DII client return ===> twelve thousand three hundred and forty five"
    declare
    service_ utl_dbws.SERVICE;
    call_ utl_dbws.CALL;
    service_qname utl_dbws.QNAME;
    port_qname utl_dbws.QNAME;
    operation_qname utl_dbws.QNAME;
    string_type_qname utl_dbws.QNAME;
    retx ANYDATA;
    retx_string VARCHAR2(1000);
    retx_double number;
    retx_len number;
    params utl_dbws.ANYDATA_LIST;
    l_input_params utl_dbws.anydata_list;
    l_result ANYDATA;
    l_namespace VARCHAR2(1000);
    begin
    -- open internet explorer and navigate to http://www.dataaccess.com/webservicesserver/numberconversion.wso?WSDL
    -- search for 'targetNamespace' in the wsdl
    l_namespace := 'http://www.dataaccess.com/webservicesserver/';
    -- search for 'service name' in the wsdl
    service_qname := utl_dbws.to_qname(l_namespace, 'NumberConversion');
    -- this is just the actual wsdl url
    service_ := utl_dbws.create_service(HTTPURITYPE('http://www.dataaccess.com/webservicesserver/numberconversion.wso?WSDL'), service_qname);
    -- search for 'portType name' in the wsdl
    port_qname := utl_dbws.to_qname(l_namespace, 'NumberConversionSoap');
    -- search for 'operation name' in the wsdl
    -- there will be a lot, we will choose 'NumberToWords'
    operation_qname := utl_dbws.to_qname(l_namespace, 'NumberToWords');
    -- bind things together
    call_ := utl_dbws.create_call(service_, port_qname, operation_qname);
    -- default is 'FALSE', so we make it 'TRUE'
    utl_dbws.set_property(call_, 'SOAPACTION_USE', 'TRUE');
    -- search for 'operation soapAction' under <operation name="NumberToWords">
    -- it is blank, so we make it ''
    utl_dbws.set_property(call_, 'SOAPACTION_URI', '');
    -- search for 'encodingstyle'
    -- cannot find xml tag 'encodingstyle', so we just use the following as the generic encoding style
    utl_dbws.set_property(call_, 'ENCODINGSTYLE_URI', 'http://schemas.xmlsoap.org/soap/encoding/');
    -- search for 'binding style'
    -- although 'document' was used, it produced an error, thus we will use 'rpc'
    -- this value is generally only 'document' or 'rpc'
    utl_dbws.set_property(call_, 'OPERATION_STYLE', 'rpc');
    -- search for 'xmlns:xs' to know the value of the first parameter
    -- under <xs:element name="NumberToWords"> you will see the line <xs:element name="ubiNum" type="xs:unsignedLong" />
    -- thus the return type is 'unsignedlong', removing 'xs:'
    -- however, upon testing, using 'unsignedlong' produced an error, while 'string' did not, so we will use 'string'
    string_type_qname := utl_dbws.to_qname('http://www.w3.org/2001/XMLSchema', 'string');
    -- under <xs:element name="NumberToWords"> you will see the line <xs:element name="ubiNum" type="xs:unsignedLong" />
    -- the element name is 'ubiNum', thus we put in 'ubiNum'
    -- the 'ParameterMode.IN' is used to specify that we will be passing an "In Parameter" to the web service
    -- the 'ParameterMode.IN' is a constant variable in the utl_dbws package
    utl_dbws.add_parameter(call_, 'ubiNum', string_type_qname, 'ParameterMode.IN');
    utl_dbws.set_return_type(call_, string_type_qname);
    -- supply the In Parameter for the web service
    params(0) := ANYDATA.convertvarchar('12345');
    -- invoke the web service
    retx := utl_dbws.invoke(call_, params);
    -- access the returned value and output it to the screen
    retx_string := retx.accessvarchar2;
    dbms_output.put_line('PL/SQL DII client return ===> ' || retx_string);
    -- release the web service call
    utl_dbws.release_service(service_);
    end;
    NOTES AND REFERENCES
    =================================================================
    This detailed step-by-step guide was produced with the following guide http://www.oracle.com/technology/sample_code/tech/java/jsp/callout_users_guide.htm
    I could still not load Oracle JAX-RPC client to SCOTT (step 4) as it produces an error. See the following for more details :
    http://forums.oracle.com/forums/thread.jspa?threadID=633219&tstart=0
    Also, I could not consume some of the other free Web Services out there for reasons I don't know, hope someone can help clarify. See the following for more details :
    http://forums.oracle.com/forums/thread.jspa?threadID=630733&tstart=0
    >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    Instructions on how to use Oracle10gR2 Webservice Call-In feature
    PREREQUISITE
    =================================================================
    1. Download Oracle Database 10g Release 2 (10.2.0.1.0) (ZIP, ~655MB)
    http://www.oracle.com/technology/software/products/database/oracle10g/htdocs/10201winsoft.html
    http://download.oracle.com/otn/nt/oracle10g/10201/10201_database_win32.zip
    1.1 Choose Enterprise Edition
    2. Download OC4J Standalone - Oracle Containers for J2EE (OC4J) 10g Release 3 (10.1.3.3) (ZIP, ~93MB; Pure Java—runs on all certified platforms)
    http://www.oracle.com/technology/software/products/ias/index.html (Download Site)
    http://download.oracle.com/otn/java/oc4j/101330/oc4j_extended_101330.zip
    2.1 Extract to C:\oracle\product\10.2.0\db_1\oc4j_extended_101330
    STEP-BY-STEP PROCEDURES
    =================================================================
    1. Connect to SYS account and create user STORE
    CREATE USER store IDENTIFIED BY store;
    GRANT connect, resource TO store;
    2. Connect to Oracle using the user STORE and password STORE
    CONNECT store/store;
    3. Execute the following objects for this excercise
    CREATE SEQUENCE order_sq;
    CREATE TABLE product_types (
    product_type_id INTEGER
    CONSTRAINT product_types_pk PRIMARY KEY,
    name VARCHAR2(10) NOT NULL
    CREATE TABLE products (
    product_id INTEGER
    CONSTRAINT products_pk PRIMARY KEY,
    product_type_id INTEGER
    CONSTRAINT products_fk_product_types
    REFERENCES product_types(product_type_id),
    name VARCHAR2(30) NOT NULL,
    description VARCHAR2(50),
    price NUMBER(5, 2)
    CREATE TABLE customers (
    customer_id INTEGER
    CONSTRAINT customers_pk PRIMARY KEY,
    first_name VARCHAR2(10) NOT NULL,
    last_name VARCHAR2(10) NOT NULL,
    dob DATE,
    phone VARCHAR2(12)
    CREATE TABLE orders (
    order_id INTEGER
    CONSTRAINT orders_pk PRIMARY KEY,
    product_id INTEGER
    CONSTRAINT purchases_fk_products
    REFERENCES products(product_id),
    customer_id INTEGER
    CONSTRAINT purchases_fk_customers
    REFERENCES customers(customer_id),
    quantity INTEGER NOT NULL
    INSERT INTO customers (
    customer_id, first_name, last_name, dob, phone
    ) VALUES (
    1, 'John', 'Brown', '01-JAN-1965', '800-555-1211'
    INSERT INTO product_types (
    product_type_id, name
    ) VALUES (
    1, 'Book'
    INSERT INTO products (
    product_id, product_type_id, name, description, price
    ) VALUES (
    1, 1, 'Modern Science', 'A description of modern science', 19.95
    COMMIT;
    CREATE OR REPLACE PACKAGE dbfunc AS
    FUNCTION place_order (
    p_product_id INTEGER,
    p_customer_id INTEGER,
    p_quantity INTEGER
    RETURN VARCHAR2;
    END dbfunc;
    CREATE OR REPLACE PACKAGE BODY dbfunc AS
    FUNCTION place_order (
    p_product_id INTEGER,
    p_customer_id INTEGER,
    p_quantity INTEGER
    RETURN VARCHAR2 IS
    v_customer_count INTEGER;
    v_product_count INTEGER;
    v_order_id INTEGER;
    BEGIN
    -- count the number of products with the
    -- supplied p_product_id (should be 1 if the product exists)
    SELECT COUNT(*)
    INTO v_product_count
    FROM products
    WHERE product_id = p_product_id;
    IF v_product_count = 0 THEN
    RETURN 'No such product';
    END IF;
    -- count the number of customers with the
    -- supplied p_customer_id (should be 1)
    SELECT COUNT(*)
    INTO v_customer_count
    FROM customers
    WHERE customer_id = p_customer_id;
    IF v_customer_count = 0 THEN
    RETURN 'No such customer';
    END IF;
    -- get the next value from orders_sq
    SELECT order_sq.nextval
    INTO v_order_id
    FROM dual;
    -- place the order
    INSERT INTO orders (
    order_id, product_id, customer_id, quantity
    ) VALUES (
    v_order_id, p_product_id, p_customer_id, p_quantity
    COMMIT;
    RETURN 'Order placed with id of ' || v_order_id;
    EXCEPTION
    WHEN OTHERS THEN
    ROLLBACK;
    RETURN 'Order not placed';
    END place_order;
    END dbfunc;
    4. Install and Configure OC4J
    4.1 Change Directory
    4.1.1 Open command prompt (cmd.exe)
    4.1.2 CD C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\bin
    4.2 Configure Environment variables (type in command prompt)
    4.2.1 set JAVA_HOME=C:\oracle\product\10.2.0\db_1\jdk
    4.2.2 set ORACLE_HOME=C:\oracle\product\10.2.0\db_1\oc4j_extended_101330
    4.3 Starting OC4J for the first time
    4.3.1 oc4j -start
    4.3.2 If this is not your first time to "start" oc4j, go to step 4.3.4
    4.3.3 Set oc4jadmin password (use the password "oracle" w/o the quotation marks)
    08/03/21 17:13:54 Set OC4J administrator's password (password text will not be displayed as it is entered)
    Enter password:
    Confirm password:
    Confirm password: The password for OC4J administrator "oc4jadmin" has been set.
    08/03/21 17:14:01 The OC4J administrator "oc4jadmin" account is activated.
    4.3.4 OC4J has started if you see the message :
    08/03/21 17:14:16 Oracle Containers for J2EE 10g (10.1.3.3.0) initialized
    4.3.5 Leave this command prompt open
    4.4 Configure Data Source
    4.4.1 Open a new command prompt via the cmd.exe command
    4.4.2 type "hostname" and then press enter
    4.4.3 Keep this command prompt open for later use
    4.4.4 Open Windows Explorer and navigate to the folder C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\config
    4.4.5 Open the file data-sources.xml
    4.4.6 Modify and Save the file so that it will look something like the following :
    4.4.6.1 Note that "hpv2710us" is my hostname found in step 4.4.2
    4.4.6.2 Note that "ORCLDEV" is the name of my Oracle Instance. (Default installation uses ORCL only)
    <connection-pool name="Example Connection Pool">
    <connection-factory factory-class="oracle.jdbc.pool.OracleDataSource"
    user="store"
    password="store"
    url="jdbc:oracle:thin:@//hpv2710us:1521/ORCLDEV">
    </connection-factory>
    </connection-pool>
    4.4.7 Close the text editor
    4.4.8 Close the Windows Explorer
    4.4.9 Close this command prompt (type exit)
    5. Publishing a PL/SQL Package as a Database Web Service
    5.1 Create the config.xml file
    5.1.1 Open Notepad.exe
    5.1.2 Copy and Paste the following :
    5.1.2.1 Note that "hpv2710us" is my hostname found in step 4.4.2
    5.1.2.2 Note that "ORCLDEV" is the name of my Oracle Instance. (Default installation uses ORCL only)
    <web-service>
    <display-name>PLSQL Web Service</display-name>
    <description>PLSQL Sample</description>
    <destination-path>./dbfunc.ear</destination-path>
    <temporary-directory>/tmp</temporary-directory>
    <context>/plsqlsample</context>
    <stateless-stored-procedure-java-service>
    <jar-generation>
    <schema>store/store</schema>
    <db-url>jdbc:oracle:thin:@hpv2710us:1521:ORCLDEV</db-url>
    <prefix>db.func.place.order</prefix>
    <db-pkg-name>dbfunc</db-pkg-name>
    </jar-generation>
    <uri>/dbfunc</uri>
    <database-JNDI-name>jdbc/OracleDS</database-JNDI-name>
    </stateless-stored-procedure-java-service>
    <wsdl-gen>
    <wsdl-dir>wsdl</wsdl-dir>
    <option name="force">true</option>
    <option name="httpServerURL">http://localhost:8888</option>
    </wsdl-gen>
    <proxy-gen>
    <proxy-dir>proxy</proxy-dir>
    <option name="include-source">true</option>
    </proxy-gen>
    </web-service>
    5.1.3 Save file as config.xml in the directory C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\config
    5.1.3.1 Note it should be config.xml and not config.txt
    5.1.4 Close the text editor
    5.2 Publish dbfunc Oracle Package as a Web Service
    5.2.1 Open a new command prompt via the cmd.exe command
    5.2.2 CD C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home
    5.2.3 mkdir ear
    5.2.4 CD ear
    5.2.5 set ORACLE_HOME=C:\oracle\product\10.2.0\db_1\oc4j_extended_101330
    5.2.6 set CLASSPATH=.;%ORACLE_HOME%\webservices\lib\wsdl.jar;%ORACLE_HOME%\lib\xmlparserv2.jar;%ORACLE_HOME%\soap\lib\soap.jar
    5.2.7 java -jar %ORACLE_HOME%\webservices\lib\WebServicesAssembler.jar -config C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\config\config.xml
    Please wait ...
    STORE.DBFUNC
    5.2.8 java -jar %ORACLE_HOME%\j2ee\home\admin_client.jar deployer:oc4j:localhost:23791 oc4jadmin oracle -deploy -file C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home\ear\dbfunc.ear -deploymentName dbfunc
    08/03/21 17:46:23 Notification ==>Application Deployer for dbfunc COMPLETES. Operation time: 296 msecs
    5.2.9 java -jar %ORACLE_HOME%\j2ee\home\admin_client.jar deployer:oc4j:localhost:23791 oc4jadmin oracle -bindWebApp -appname dbfunc -webModuleName dbfunc_web
    5.2.10 java -jar %ORACLE_HOME%\j2ee\home\admin_client.jar deployer:oc4j:localhost:23791 oc4jadmin oracle -bindAllWebApps -appname dbfunc
    5.2.11 Close this command prompt (type exit)
    6. Test dbfunc Web Service
    6.1 Restart OC4J
    6.1.1 Open the command prompt you used to start OC4J in step 4.1.1/4.3.1
    6.1.2 In the keyboard, hit Ctrl+C
    6.1.2.1 Type "Y" and then hit Enter
    08/03/21 18:02:51 Shutting down OC4J...
    Terminate batch job (Y/N)? Y
    6.1.2.2 Note that the command prompt should still be open
    6.1.2.2.1 If you accidentally closed the command prompt just do the following
    6.1.2.2.1.1 Do 4.1.1 to 4.2.2 and then proceed to 6.1.3
    6.1.3 oc4j -start
    Starting OC4J from C:\oracle\product\10.2.0\db_1\oc4j_extended_101330\j2ee\home...
    08/03/21 18:07:57 Oracle Containers for J2EE 10g (10.1.3.3.0) initialized
    6.1.4 Leave this command prompt open
    6.2 Use the Web Service to "Order an Item"
    6.2.1 Connect to Oracle using the user STORE and password STORE
    6.2.2 select * from orders
    6.2.2.1 Zero row should return
    6.2.3 Open Internet Explorer
    6.2.4 Navigate to http://localhost:8888/plsqlsample/dbfunc
    6.2.5 Input the following :
    6.2.5.1 param0 value: 1
    6.2.5.2 param1 value: 1
    6.2.5.3 param2 value: 10
    6.2.6 Click the Invoke button
    6.2.7 A pop-up window will appear having the following contents :
    <?xml version="1.0" encoding="UTF-8" ?>
    - <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    - <SOAP-ENV:Body>
    - <ns1:placeOrderResponse xmlns:ns1="http://db.func.place.order/dbfunc.wsdl" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
    <return xsi:type="xsd:string">Order placed with id of 1</return>
    </ns1:placeOrderResponse>
    </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    6.2.8 Go back to SQLPLUS or Toad and execute "select * from orders" again
    6.2.8.1 There should be one row
    ORDER_ID, PRODUCT_ID, CUSTOMER_ID, QUANTITY
    1, 1, 1, 10
    NOTES AND REFERENCES
    =================================================================
    This detailed step-by-step guide was produced with the following article by Jason Price http://www.oracle.com/technology/pub/articles/price_10gws.html

    Success!!!
    I had to grant this permissions:
    call dbms_java.grant_permission( 'WS_TEST', 'SYS:java.lang.RuntimePermission', 'getClassLoader', '' );
    call dbms_java.grant_permission( 'WS_TEST', 'SYS:java.lang.RuntimePermission', 'accessClassInPackage.sun.util.calendar', '' );
    call dbms_java.grant_permission( 'WS_TEST', 'SYS:java.lang.RuntimePermission', 'setFactory', '' )
    call dbms_java.grant_permission( 'WS_TEST', 'SYS:java.util.PropertyPermission', 'HTTPClient.socket.idleTimeout', 'write' );
    call dbms_java.grant_permission( 'WS_TEST', 'SYS:java.net.SocketPermission', 'localhost', 'resolve' );
    call dbms_java.grant_permission( 'WS_TEST', 'SYS:java.net.SocketPermission', '127.0.0.1:8084', 'connect,resolve' );
    As I wrote earlier, WS_TEST is my user into which I load JAX-RPC client. Note that, if you load JAX-RPC client into user another than SYS, you have NOT to use -s -grant public option (wassam wrote about this too). Another thing is that I (finally) didn't load OC4J. To consume WebService I use utl_dbws.invoke(call_Handle CALL, request SYS.XMLTYPE) function.
    voytec001

  • PO creation using LSMW through batch input method

    Hi, I am new to working with LSMW and i have completed a project for creating purchase orders using the direct data input method. I need to do the same using batch input method, however in the maintain structure relationship step, it is only allowing me to assign one structure to the recording that i have done, however in po creation we need separate (nested) structure for header and line item, could anybody help me past this please?

    Hi Rudra!
    OK, now you just know, why you have only one line, not multiple PO item lines. To get a dynamic number of items, you need a complex program - just like standard direct input.
    If you need a field, which is not part of this program, don't try to write your own program for batch input - it's just to much work before you have a good result.
    You can use Bapi method instead with BAPI_PO_CREATE1. This can handle a lot of fields and there is some documentation available how to fill the Bapi.
    If this looks to complicated in the first moment, think about creation of POs via direct input and a small batch recording to change your additional field(s) afterwards. (You can select EKPO table to generate list of 'wrong' migrated orders for input in LSMW.) Use field 'Item' in the bottom of ME22 to position your desired line in first screen line, just change one PO-line after one other (every time a 'save' -> no problem with different number of lines / PO).
    Regards,
    Christian

  • Batch Input : Adding component with C002

    Hi all
    I try to add component on a production ordrer with C0O2 but i have problem with the item category 'R' (Variable-size item). In fact, SAP ask me to fill variable-size item data but i can't run this step with batch input.
    For example with the batch input recorder, i obtain :
    SAPLCOKO1 0110 X
         BDC_OKCODE                         /00
         CAUFVD-AUFNR          10001280
    SAPLCOKO1 0115 X
         BDC_OKCODE          =KPU2
    SAPLCOMK 0120 X
         BDC_CURSOR          RESBD-LGORT(23)
         BDC_OKCODE          /00
         FILTER_BOX          NO_FIL
         SORT_BOX          ST_STA
         RESBD-MATNR(23)      SAM6506P00055
         RESBD-MENGE(23)          2
         RESBD-EINHEIT(23)     M
         RESBD-POSTP(23)          R
         RESBD-VORNR(23)          0040
         RCOLS-APLFL(23)          23
         RESBD-WERKS(23)          0200
         RESBD-LGORT(23)          0010
         BDC_SUBSCR          SAPLCOKO1                               0800ORD_HEADER
         BDC_SUBSCR          SAPLCOMK                                0050BUTTONS
         BDC_SUBSCR          SAPLCOMD                                0160SUBSCR_0100
         BDC_CURSOR          RESBD-ROMEI
         RESBD-MATNR          SAM6506P00055
         RESBD-ROMS1          1000
         RESBD-ROMEI          MM
         RESBD-ROKME          M
    Is there other way to fill variable-size item ? Have you got ideas to simulate this step ?
    I don't use FM because i have to fill the field RESBD-VORNR.
    Thanks in advance for your response.
    Patrick.

    In fact the choice that i have made was wrong.
    Adding component with CO02 is possible with ls_params-nobinpt = ''.

Maybe you are looking for

  • Problems loading RAW files from Canon EOS 70D

    I've recently changed my camera from an EOS 500D to a 70D and now find that I can't open the RAW files even though my Photoshop says it's up-to-date when queried through Creative Cloud.  However, when I check the Camera RAW version used in PhotoShopC

  • Iphoto 9.3 update installation loop on step5 99%.

    Do you have a solution please?

  • Convert From AAC to WMA for nano 16gb

    I pay to get music from Kazaa which uses a WMA format, when I try to add it to my Itunes it says that the songs is from a WMA format and Itunes uses AAC format, how can I get this music to my Itunes to put on my I-pod 16gb

  • OS X 10.9.3 Update Problems

    So i just updated my macbook pro ,15" late 2013 with 8gb of ram, to 10.9.3 and my first problem was as soon as the download is over my mac is frozen, so i had to shut it down manually then after 15 min of using it, a new tab shows up and says no more

  • CentOs 6.5 Shutdown

    Hi all, I've just finished the install of CentOs 6.5 on SCVMM 2012 R2. The CentOs VM is hosted on HyperV 2012 R2. The mouse, timesync, keyboard work fine. I've only the issue with the SCVMM Shutdown functionality. When I do a shutdown from SCVMM, the