Patent ID: 8676863

Claim:
A method in a computing system for representing in a relational database informational content of a stream of XML messages, at least two of the XML messages having different hierarchical formats, comprising: from each XML message of the stream, reading a plurality of open tags each corresponding to an element in the corresponding XML message; for each read open tag, automatically determining a path from a root node corresponding to a first read open tag from the corresponding XML message to the currently read open tag; for each determined path: (a) automatically designating a relational table in the relational database corresponding to the path, and (b) storing a combination of at least one of a first identifier for the currently read open tag corresponding to the path, the first identifier being stored in connection with information identifying a primary key column of the designated relational table corresponding to a primary key for the designated relational table, and a second identifier of a parent of the currently read open tag, the parent comprising the open tag immediately preceding the currently read open tag in the determined path, the second identifier being stored in connection with information identifying a foreign key column of the designated relational table corresponding to a foreign key of the designated relational table; for each read open tag having at least one of a value or an attribute value: (c) designating at least one data column different from the primary and foreign key columns of the relational table corresponding to the determined path for the read open tag, the at least one data column corresponding to the at least one of the value or the attribute value, and (d) storing information identifying the at least one designated data column of the relational table in connection with the stored combination of the first identifier and the second identifier for the read open tag; and after reading open tags associated with XML messages comprising hierarchical formats not previously encountered and not previously associated with at least one of created relational tables or created columns of relational tables: automatically creating at least one of relational tables or columns of relational tables in accordance with steps (a) thru (d) above, and when a currently read open tag corresponds to an existing combination of a first and second identifier, creating a new row in the designated relational table associated with the combination of the first identifier and the second identifier, the row containing the first identifier stored in the primary key column of the associated relational table and the second identifier stored in the foreign key column of the associated relational table, and for each value or attribute value of the currently read open tag associated with the existing combination of the first identifier and the second identifier, writing the value or attribute value to the at least one corresponding data column of the new row of the associated relational table.