Building a Data Query API

When you create a Data Query through API Builder, you are creating a call to the Lawson Data servlet. The query you create can be pasted into a VB or other application.

Building a Data call

From any screen of the Lawson Design Studio, select Tools from the main menu (menu that runs along the top left of the screen) and click API Builder.

From the API Builder data select page, click Data Queries, and then select the data area, system code, and data table you plan to use.

When you select a data table, the dialog box for selecting table fields, indexes (indices), key fields (index elements), related tables (if any), and related elements (if any) appears.

Form clip: API Builder form for selecting data

You can make specify options for selecting criteria and formatting output. These specialized options are described in "Specifying a criteria statement for Data cell" and "Specifying return Options for Data output".

When you have made all selections for the data, select Build Query or Test Query.

  • The Build Query option creates the data query and prints it in the bottom of the browser window.

  • The Test Query option tests the query and displays the XML results in a browser window. If the XML code is what you expected, you can copy and paste it into another application, such as a VB application or Crystal report.

  • The Build Lawson Portal Query option adds formatting to the query that makes it display properly in Lawson Portal. You could use this option to create a nuglet to display on a custom page.