Create a new query

  1. Open the Query Editor.

    • For Sage 200 versions 2026 R1 and later, open the Query Editor from the SDK.

    • For Sage 200 versions up to 2025 R2, open the Query Editor from the Workspace Designer.

      To do this, first open the Workspace Designer from the Sage 200 desktop client by selecting Tools > Run Workspace Designer. In the Workspace Designer open Content Part Designer, and then in the Content Part Designer open Query Editor.

      To access Workspace Designer you must also enable the setting Can Edit Workspaces in your user properties in System Administration.

  2. Select the Model Models are data schemas that describe how the information held in a particular database can be accessed and displayed within Sage 200. Each model is contained in its own dynamic link library (DLL). from the Data Store drop-down list.

  3. From the Query Editor toolbar, select New.

    A New Workspace Query is added to the Queries pane (on the right).

  4. To change the name of the new query, select New Workspace Query in the query pane.

  5. In the General Settings section, enter the Name of the query.

  6. Add the LINQ Language Integrated Query. Used to extract information from a database, which can then be used in workspaces. query text in the blank centre pane. To see a preview of the query, click Preview on the toolbar. The preview appears on the Results tab in the bottom pane.

  7. To save the new query click Save All. This saves changes to all queries, not just the one displayed.

    The query is now saved but is not used in any workspaces at this point. This allows you to review your queries first.

    Note: Those queries that are saved but not yet used in workspaces are stored in the folder ...Sage\IM Content\Modifications\Queries\Pending.

  8. To add the new query to your workspaces, in the General Settings, select True from the InProduction drop-down list.