- From: Digitome Ltd. <sean@digitome.com>
- Date: Sat, 17 May 1997 13:35:55 +0100
- To: w3c-sgml-wg@w3.org
>[Andrew Layman] >In many of these cases, the >volume of data is large, but is mainly short fields, so the overhead of >lengthy tags is pretty high relative to the basic data. > Why don't the data people do this instead:- <database> <schema> <field name = "name" type = "string" length = "20"/> <field name = "shoesize" type = "int" length = "2"/> </schema> <record name = "Sean Mc Grath " shoesize = "12"/> <record name = "Mark Uplang " shoesize = "14"/> ... </database> If the field sizes are generally small, attributes might be a better option than data content and side-steps the need for long delimiter strings. Each record above costs 55 characters. The element version:- <record><name>Sean Mc Grath </name><shoesize>12</shoesize></record> costs 64 characters With empty end-tags:- <record><name>Sean Mc Grath </><shoesize>12</></> costs 55 again. The attribute version costs the same as the end-tag here but is much more Perl/Python/Grep-able. Sean Sean Mc Grath sean@digitome.com Digitome Electronic Publishing http://www.digitome.com
Received on Saturday, 17 May 1997 09:00:10 UTC