[Gfoss] Tabelle

Andrea Peri peri.rtoscana a gmail.com
Lun 3 Mar 2008 14:35:40 CET


>b) shx record:
>  Byte 0   Offset Offset   Integer BigEndian
>  Byte 4   Content Length  Integer BigEndian

>- The main file is a direct access, variable-record-length
> file in which each record describes a shape with a list
> of its vertices.
>- In the index file, each record contains the offset of the
> corresponding main file record from the beginning of the
> main file.
>- The dBASE table contains feature attributes with one record per
> feature. The one-to-one relationship between geometry and
> attributes is based on record number.
>

>Quindi le strutture dati che consentono di associare
>dinamicamente geometria ed attributi informativi con
>accessi random che usano l'SHX come struttura guida
>ci sono tutte. Poi però ti dicono anche:
>
>- Attribute records in the dBASE file must be in the
> same order as records in the main file.
>
>Insomma, quanto meno ci sono un paio di ridondanze
>[ambiguità ? contraddizioni ?] di troppo che si prestano
>anche troppo bene ad interpretazioni ed implementazioni
>"varie", in primis da parte di ESRI stessa.
>

Io non riesco a cogliere le contraddizioni/ambiguita' che indichi.

>  Byte 0   Offset Offset   Integer BigEndian
>  Byte 4   Content Length  Integer BigEndian

Nell'shx, l'offset si riferisce al punto di partenza nel file shp, e
il content lenght indica quanti bytes occupa lo shape a partire
dall'offset nel file .shp.
Nel file .shx non vi e' nessuna indicazione utile per rintracciare la
corrispondente parte degli attributi nel file .dbf.


>Quindi le strutture dati che consentono di associare
>dinamicamente geometria ed attributi informativi con
>accessi random che usano l'SHX come struttura guida
>ci sono tutte. Poi però ti dicono anche:
>
>- Attribute records in the dBASE file must be in the
> same order as records in the main file.
>
>Insomma, quanto meno ci sono un paio di ridondanze
>[ambiguità ? contraddizioni ?] di troppo che si prestano
>anche troppo bene ad interpretazioni ed implementazioni
>"varie", in primis da parte di ESRI stessa.
>

Ribadisco che non riesco a vedere come sia possibile raggiungere gli
attributi giusti
partendo dall' shx senza tener conto che la parte dbf e' regolata
secondo un ordine posizionale con il file shp.
Nel file shx non vi e' traccia della posizione sul file dbf ove
trovare gli attributi relativi a uno specifico shape.

Ciao,

-- 
~~~~~~~~~~~~~~~~~
§       Andrea              §
§         Peri                 §
~~~~~~~~~~~~~~~~~


Maggiori informazioni sulla lista Gfoss