List Pattern Matching for Queries using Hierarchical Meta Data

The syntax and grammar of the query condition expression in covered in Appendix Appendix A:, Hierarchical Query Condition Expression Syntax.

This section introduces a slightly more difficult problem. Suppose you want to get a list of all employees with any programming skill, regardless of the particular programming language. Since there are no fields in the XML structure that specify this information, it will have to be deduced from the skill description.

Assuming all programming skills end with 'Programming', you can find employees with programming skills by matching the skills against a regular expression pattern, '.programming'. The following is a list pattern matching expression:

any skill match '.*programming'

Walkthrough

Follow the following steps to create an 'All Programmers' query.

1. Create an XML query as before, with the name “All Programmers”.

2. Select the 'Employee' node and click on 'Select Record' to make it the selection tree path.

3. Enter the condition expression in the condition text area:

ANY skill match '.*programming'

4. Select 'Save' (on the main toolbar) to save the expression.

5. Select the 'Map to Table' option, then follow the same procedures to map the result sub-tree to a table.

6. Click 'Preview'.

 

<< List Comparison for Queries using Hierarchical Meta Data © 1996-2013 InetSoft Technology Corporation (v11.5) Appendix A: Hierarchical Query Condition Expression Syntax >>