Common Message Format ver 2.1 (9-9-2004) ---------------------------------------- ** everything below in a printable format (no compression - few if any special characters) note: graphics ... etc excepted ** most messages fixed length (1000 bytes for most configurations) ** something similar to below can be achieved with xml, but xml has the following drawbacks -1- building the message is more complicated (and error prone) -2- parsing the built message is more complicated -3- storing and retrieving from a database more difficult (John Layden may be able to help us here) Message_Header (54 bytes) Message_Type // 15 bytes (name clearing house?) Message_Type_Version // 4 bytes (0001 - 9999) ** note: generally speaking newer versions should simply be adding fields to the end thereby allowing convenient expectations of field order by receiving pgms Message_Date // 8 bytes (YYYYMMDD) Message_Date // 8 bytes (YYYYMMDD) Message_Time // 9 bytes (HHMMSSMMM, hours minutes seconds milliseconds) Message_Sending_Program // 8 bytes, mostly for debugging purposes Message_Seq // 3 digits (for when 1 logical message spans many physical) Message_Body_Config // 1 byte // S -- small (12 byte field content) // M -- medium (50 byte field content) // L -- large (100 byte field content) // X -- xlarge (1 field per msg, (e.g. graphics) Message_Body_Length // 6 bytes // -- 000946 for small config msgs // -- 000946 for mediuim config msgs // -- 000946 for large config msgs // -- ###### whatever value needed for xlargeMessage_Body_Small_Config array (35) Data_Type // 15 bytes (data name clearing house?) ** the receiving program needn't blindly look in fixed positions but can look for the expected variable by name -- this is most useful when a program is looking for the same data_type across message_types Data // 12 bytes ** numerics should be in printable format -- embedded decimal point -- leading sign or no sign -- right or left justified doesn't matter (program functions can handle either) trailer (1 byte) // ---------------- Message_Body_Medium_Config array (14) Data_Type // 15 bytes (data name clearing house?) ** the receiving program needn't blindly look in fixed positions but can look for the expected variable by name -- this is most useful when a program is looking for the same data_type across message_types Data // 50 bytes trailer (36 bytes) array (14) Data_Type // 15 bytes (data name clearing house?) ** the receiving program needn't blindly look in fixed positions but can look for the expected variable by name -- this is most useful when a program is looking for the same data_type across message_types Data // 50 bytes trailer (36 bytes) // ---------------- Message_Body_Large_Config array (8) Data_Type // 15 bytes (data name clearing house?) ** the receiving program needn't blindly look in fixed positions but can look for the expected variable by name -- this is most useful when a program is looking for the same data_type across message_types Data // 100 bytes trailer (26 bytes)