PADX Sirius Data Demo

The Sirius example represents telephone service provisioning information. In the telecommunications industry, the term provisioning refers to the steps necessary to convert an order for phone service into the actual service. To track AT&T's provisioning process, the Sirius project compiles weekly summaries of the state of certain types of phone service orders. These ASCII summaries store the summary date and one record per order. Each order record contains a header followed by a sequence of events. The header has 13 pipe separated fields: the order number, AT&T's internal order number, the order version, four different telephone numbers associated with the order, the zip code of the order, a billing identifier, the order type, a measure of the complexity of the order, an unused field, and the source of the order data. Many of these fields are optional, in which case nothing appears between the pipe characters. The billing identifier may not be available at the time of processing, in which case the system generates a unique identifier, and prefixes this value with the string ``no_ii'' to indicate the number was generated. The event sequence represents the various states a service order goes through; it is represented as a new-line terminated, pipe separated list of state, timestamp pairs. There are over 400 distinct states that an order may go through during provisioning. The sequence is sorted in order of increasing timestamps.

A first suggestion is to experiment with the XQuery query, to select different fields from the PADS-processed output. Depending on your depth of knowledge of XQuery, you could choose queries which focus on specific fields, or combinations of fields.

Note that there are three input records in the provided sample. A second suggestion is to change the input data to explore how PADS handles error conditions.

Please experiment as you wish - and notify us if you find problems.

PADS Description

Ptypedef Puint64 pn_t;

Ptypedef Pchar zipSep_t :
zipSep_t x => {x == '-' || x == '/' || x == ' '};

Pstruct extended_zip_t{
Puint32 zip;
zipSep_t sep;
Puint32 suffix;
};

Punion Pzip{
extended_zip_t extendedZip;
Puint32 smallZip;
Puint64 largeZip;
};

Precord Pstruct summary_header_t {
"0|";
Puint32 tstamp;
};

Pstruct no_ramp_t {
"no_ii";
Puint64 id;
};

Punion dib_ramp_t {
Pint64 ramp;
no_ramp_t genRamp;
};

Pstruct order_header_t {
Puint32 order_num;
'|'; Puint32 att_order_num;
'|'; Puint32 ord_version;
'|'; Popt pn_t service_tn;
'|'; Popt pn_t billing_tn;
'|'; Popt pn_t nlp_service_tn;
'|'; Popt pn_t nlp_billing_tn;
'|'; Popt Pzip zip_code;
'|'; dib_ramp_t ramp;
'|'; Pstring(:'|':) order_type;
'|'; Puint32 order_details;
'|'; Pstring(:'|':) unused;
'|'; Pstring(:'|':) stream;
'|';
};

Pstruct event_t {
Pstring(:'|':) state; '|';
Puint32 tstamp;
};

Parray eventSeq {
event_t[] : Psep('|') && Pterm(Peor) ;
} Pwhere {
Pforall (i Pin [0..length-2] :
(elts[i].tstamp <= elts[i+1].tstamp));
};

Precord Pstruct entry_t {
order_header_t header;
eventSeq events;
};

Parray entries_t {
entry_t[];
};

Psource Pstruct out_sum{
summary_header_t h;
entries_t es;
};

PADS Input Data

XQuery Query