|
|
![]() |
|
|
A Poor Man's Data Query by Shannon O'Donnell Want to learn how you can easily display iSeries DB2/400 data in a nice looking little GUI on your PC? Want to learn how to share that same query with other users in your shop? If you have access to the IBM Client Access Express V5R1 tools, and your company owns a license for the Data Transfer tools that come with them, then you have all you need to quickly pull iSeries data down to your PC. In this article, I'll show you how.
What You NeedAll you really need to accomplish this "poor man's" data query are the Data Transfer tools that come with Client Access Express V5R1. To use these tools, you'll have to pay IBM for a license to the tools. Most companies pay for this license as a matter of course when ordering Client Access Express, so chances are your company already owns a license. If the Data Transfer tools are not already installed on your PC, use the Selective Setup feature of Client Access Express to install them now. How It's DoneOpen a new Data Transfer from AS/400 on your PC. You can access that feature from Client Access Express by clicking the Windows Start button, then Programs, then IBM AS/400 Client Access Express, and, finally, Data Transfer from AS/400. You should see a panel like the one shown in Figure 1. Figure 1: The Data Transfer from AS/400 panel provides a quick view of DB2/400 data. Select an iSeries name or IP address for the System Name, and then enter the library/file (member) name of the iSeries database whose data you want to view. In this case, I selected a file named EMPMST in library SHANNON. Leave the PC Output device value set to Display. We want to display our data on the PC. Of course, you can always change this value to either File, HTML, or Printer. It all depends on how you want to view the data. For now, we'll just look at it on the screen. You can also choose to format the data by clicking the Format Options button on the Data Transfer panel. And you can even perform selection criteria by clicking the Data Options button. We'll take all the defaults for our example. When you're done filling in the various options, click the Transfer data from AS/400 button. Your output should look similar to that shown in Figure 2. Figure 2: Displaying AS/400 data is easy! Saving and Running It LaterIf everything looks OK, you'll probably want to save this data transfer session, so that you can run it at a later time without having to re-input all the values. And you may even want to load this transfer request onto other users' PCs in your shop, so that they can use it, too. Click the File menu item on the Data Transfer panel. Before you click the Save menu item, click the Properties menu item. We need to make a few execution property choices before we save the session. When you first see the Properties panel, you'll notice that you have six tabs running across the top: Conversions, Library List, Display, SQL, Connection, and Startup. You can control the behavior of the data transfer session by the choices you make in these property panels. For example, if you click on Display tab, you can determine whether or not to display the data transfer diagnostic messages as the transfer is running. If you create and save this transfer request and then put it onto another user's PC, you may want to suppress these diagnostic messages, so that the user doesn't see them and wonder what's going on. You can probably figure out all of these tabs yourself, so I won't go into a lot of detail here. The only two I should make mention of are the Connection and the Startup tabs. You can control what connection method you want the user to have when he runs this data transfer request. For example, you could allow him to use the default settings, as defined in the Operations Navigator session. Of course, if the user doesn't have OpsNav installed on his PC, this won't work very well. If you're going to load this data transfer request on another user's PC, you probably want to prompt them to log onto their AS/400 every time. You can select that connection option from the Connection panel. The Startup tab allows you to control whether or not the data transfer runs automatically when the transfer request is activated. Check the Run transfer request automatically box if you want the transfer to run when the user double-clicks the data transfer request. Now you're ready to save the data transfer request. Click File and Save, and save the transfer somewhere on your PC. Remember what you named this transfer request (it must have the extension .DTF to be a valid data transfer file. Also remember where you saved the file, so that you can run it later. Running the Request AutomaticallyNow that the request has been saved, you can either run it immediately or copy it to any other PC in your network and allow it to be run from there. In fact, you can even make the request run automatically. If you checked Run transfer request automatically, from the Startup tab, you could add to that user's Windows Startup folder a shortcut to the data transfer file you placed on the user's PC. That way, every time the user booted his PC, this transfer request would run and present him with information like that shown in Figure 2. Or you could add a shortcut to the transfer request file to the user's Programs menu on his PC and allow him to control when the request is initiated. Regardless of how you do it, the data transfer request for DB2/400 data makes for a very nice "poor man's" data query program!
|
Editors
Contact the Editors |
|
Last Updated: 6/20/02 Copyright © 1996-2008 Guild Companies, Inc. All Rights Reserved. |