Table of Contents

Search

  1. Preface
  2. Introduction to Data Transformation
  3. Data Processor Transformation
  4. Wizard Input and Output Formats
  5. Relational Input and Output
  6. XMap
  7. Libraries
  8. Schema Object
  9. Command Line Interface
  10. Scripts
  11. Parsers
  12. Script Ports
  13. Document Processors
  14. Formats
  15. Data Holders
  16. Anchors
  17. Transformers
  18. Actions
  19. Serializers
  20. Mappers
  21. Locators, Keys, and Indexing
  22. Streamers
  23. Validators, Notifications, and Failure Handling
  24. Validation Rules
  25. Custom Script Components

Data Transformation User Guide

Data Transformation User Guide

Optional Group

Optional Group

You can use the
optional
property of a
Group
to prevent the Script from attempting to retrieve text from a missing section of a document.
For example, to parse the source
First name: Ron
you might define
First name:
as a
Marker
and
Ron
as
Content
. If some source documents do not contain the first-name data, you can put the
Marker
and
Content
in a
Group
and make it optional. If
First name:
is not found, the
Group
immediately fails, and the Parser does not search for the
Content
anchor.
There is a difference between making the
Group
optional and making its nested anchors optional. If you make both the
Marker
and
Content
optional, instead of the
Group
, the Script ignores the
Marker
failure and searches for the
Content
. This might result in retrieving irrelevant text.