Once in a while, individuals may need to retrieve DB2 data from within an automated script. This is usually required for the parametrization of the automated tests as to make the data independent. For instance, one may need to verify the existence of information that was already recorded in the DB and one may want to automatically verify that in their scripts. For such an operation to be possible, one will need a third party to connect the RFT to the DB system. This third party can very well be the iSeries ODBC driver. This article will show the readers how to configure the iSeries OBDC driver in easy steps.
The first thing individuals need to do is to install the iSeries Navigator together with its DB components. If one cannot do it by themselves, they should ask their administrator to do it for them. After that, for those who operate in Windows, one needs to go to Control Panel, Administrative Tools and Data Source which is actually ODBC. Here a box will appear and users will have to click the Add button which will open another box from which they have to select iSeries Access ODBC Driver. The user should now simply click Finish.
Going back to the General Tab, in Data Source Name field, one will type an arbitrary DB name of their choice. Also, in the Server tab, one will have to change the SQL Default Library to DB library name. The next tab, the Packages Tab contains a field called Package Library which must also be changed to the DB library name. One shall now press ok. At this point, the user will be able to connect the RFT scripts by establishing a link between the RFT and the DB system.
Users should parameterize the database name, their username and their password by prompting the user in the begging of the script. This will remove the odds of having to refactoring the script when the credentials change. Nevertheless, individuals who are doing this should give the authenticated user the opportunity to having enough privilege as to insert statements in the script. If this does not happen, the script will eventually crash and this is not what users will want.