PIXES - Processing Instructions XML, EDI & SQL.


This document is a work-in-progress.
As of October 10, 2007

©American Coders, Ltd. 2005-13
Publish or Perish

Requires OBOE Version 3.5

Programming EDI and SQL using XML tags.

This is not an XSLT processor or a replacement for it, though PIXES may be considered an alternative to XSLT. The files used by PIXES parser will not work with a XSLT processor and vice versa. PIXES does not support the concept of XML namespace.

PIXES is designed to work with the hierarchy of X12 EDI message files and used in conjunction with SQL databases.

As with XSLT, PIXES executes the code within the scope of a XML tag.

If the tag is not reachable then tags within the unreachable scope are not executed.

For example during incoming processing - if the PIXES process has a segment tag such indicating logic for a N1 segment
<segment id="N1">...</segment>
and the process is within a segment container without a N1 segment then all of the PIXES processing tags between <segment and </segment are ignored.

Another example - if the PIXES process has a SQL select tag pulling data from a table
<select fields="*" table="product" where="prodid="12345678">...</select>
and the SQL processor returns some rows for the result set for the select statement then all of the data within the select tags are processed.

Some tags don't required inner tags, for instance <exit/> and <dumpVariables/>

Modes

A PIXES process runs in one of two modes:

  1. inbound.Click here to review a discussion of inbound processing
  2. outbound.Click here to review a discussion of outbound processing

Tag Types

The package provides for several types of tags

  1. SQL tags.
  2. EDI tags.
  3. Control processing tags.
  4. Simple math.
  5. Field level setting and getting.

External Requirements

  1. Java
  2. log4j from Apache
  3. OBOE - Open Business Objects for EDI - Version 3.5
  4. SQL and JDBC libraries
      Tested against
    1. MySQL Version 4.0
    2. DB2 Personal Version 8.1
  5. Open AS2 - optional

Files Used

  1. PIXES Processing File
  2. Inbound Message File
  3. Outbound Mesage File
  4. System.out File

Variables

Variables may be assigned by several methods.
  1. By assigning a value using the set tag
  2. By retrieving a SQL field using the select tag
  3. By retrieving a EDI field value using the element tag
  4. Computing a value using the compute tag
  5. Passing a value using a runtime parameter call
  6. Storing a name/value pair collection in a properties file

The package provides for an indexing mechanism using the [] (square brackets) to indicate an indexed name. Unlike formal programming languages predefining the size or number of index items is not possible. This is similar to the concept of Indexed Strings used in the NetRexx and Rexx languages.

Tags or Processing Instructions

  1. atEnd
  2. break
  3. commit
  4. composite
  5. compute
  6. connect
  7. continue
  8. delete
  9. dumpVariables
  10. element
  11. envelope
  12. exit
  13. for
  14. functionalgroup
  15. if
  16. insert
  17. leave
  18. log
  19. loop
  20. process
  21. rollback
  22. segment
  23. select
  24. set
  25. subroutine
  26. table
  27. transactionset
  28. update