Link to USGS Home Page

[Top] [Prev] [Next] [Bottom]



Annex C

(Informative)

Attribute Encoding

This annex presents a further explanation of the attribute encoding methods specified in the normative portion of the standard. Encoding examples, at the logical level, of the Attribute Primary and Attribute Secondary modules are given, together with examples of the Data Dictionary modules that describe the attribute data.

This annex also presents examples of valid attribute labels, and further describes the use of code sets. It presents a suggested list of code sets for use in a transfer.

C.1 Attribute Primary and Attribute Secondary Modules

The structure of an Attribute Primary module record is defined in 4.1.3.6.1, using BNF, as:

	<Attribute Primary module record>::= <module record identifier>
								[<spatial object ID>]
								[<attribute 1>]
								[<attribute 2>]
									.
									.
									.
								[<attribute n>]

		<module record identifier>::= <module name> <record id>

		<spatial object ID>::= <module name> <object id>

The spatial object ID field is optional. If used, it constitutes a backward link from the attributes to the spatial object. Forward links from the spatial object are made through the use of a foreign identifier in the spatial object module record named Attribute ID. This field is also optional, but the minimum requirement is that there be at least either a forward or a backward link.

The structure of the secondary attribute module record is nearly identical to the structure of the primary module record: the difference is the absence of the spatial object link field.

The following schematic example shows some spatial objects with primary and secondary attributes and their potential links. In the first example ("Bridges"), the Attribute Secondary module is used to handle values of the standard attribute 'Composition' with a one-to-many link between 'Composition' and the attribute 'Material' (i.e., each bridge is composed of more than one material). In the second example, primary attributes such as 'State', 'County', and 'Land Type' are given FIPS and DLG code equivalents.

Table 52 - Point-node module "Bridges"


Point-Node

Attribute ID

Spatial Address

MODN

RCID

OBRP

MODN

RCID

X

Y

Bridges


1


NP


BridgeAtts


81


etc.



Bridges


2


NP


BridgeAtts


82




Bridges


3


NP


BridgeAtts


83



Table 53 - Attribute primary module "BridgeAtts"


Attribute primary

Spatial object ID

Attributes

MODN

RCID

MODN

RCID

COMPOSITION

SPAN LENGTH

BridgeAtts


81


Bridges


1


A


300


BridgeAtts


82


Bridges


2


B


1200


BridgeAtts


83


Bridges


3


A


500

Table 54 - Attribute secondary module "BridgeComp"


Attribute Secondary

Attributes

MODN

RCID

COMPOSITION

MATERIAL

BridgeComp


27


A


Wood


BridgeComp


28


A


Concrete


BridgeComp


29


A


Steel


BridgeComp


30


B


Concrete


BridgeComp


31


B


Wood

In the above example, the link between the Point-Node and Attribute Primary module records is one-to-one, while the link between Attribute Primary and Attribute Secondary records is one-to-many.

The DLG example shows attributes for a set of polygons, with one Attribute Primary Module and three Attribute Secondary modules:

Table 55 - Polygon module "GlenEllen"


Polygon

Attribute ID

Ring ID

MODN

RCID

OBRP

MODN

RCID

MODN

RCID

GlenEllen


1


PR


GlenEllenAtts


11


etc.



GlenEllen


2


PR


GlenEllenAtts


12




GlenEllen


3


PR


GlenEllenAtts


13




GlenEllen


4


PR


GlenEllenAtts


14



Table 56 - Attribute primary module "GlenEllenAtts"


Attribute Primary

Spatial Object ID

Attributes

MODN

RCID

MODN

RCID

STATE

COUNTY

LANDTYPE

GlenEllenAtts


11


GlenEllen


1


California


Sonoma


Park


GlenEllenAtts


12


GlenEllen


2


California


Sonoma


null


GlenEllenAtts


13


GlenEllen


3


California


Sonoma


Land Grant

Table 57 - Attribute Secondary Module "States"


Attribute Secondary

Attributes

MODN

RCID

STATE

DLGCODE

STATEFIPSCODE

States


37


California


091.0006


06


States


38


Nevada


etc.


Table 58 - Attribute secondary module "Counties"


Attribute Secondary

Attributes

MODN

RCID

COUNTY

DLGCODE

COUNTYFIPSCODE

Counties


92


Sonoma


092.0097


097


Counties


93


Napa


etc.



Counties


94


Mendocino



Table 59 - Attribute secondary module "LandTypes"


Attribute Secondary

Attributes

MODN

RCID

LANDTYPE

DLGCODE

LandTypes


6


Land Grant


090.0113


LandTypes


7


Park


090.0130

C.2 Data Dictionary/Schema Module

Each Attribute Primary or Attribute Secondary module shall have an associated Data Dictionary/Schema module. The following is an example of the Data Dictionary/Schema module for the BridgeAtts and BridgeComp modules of the Bridge example (the sequence of the subfield mnemonics in the table corresponds to the sequence of the subfields in the module description table). The entity for this example is "Bridge," a standard SDTS entity.

Table 60 - Data dictionary/schema field


Module record number

Subfield mnemonic

Subfield contents

1


MODN


BridgesSchema


RCID


1


NAME


BridgeAtts


TYPE


ATPR


ETLB


BRIDGE


EUTH


SDTS


ATLB


SPAN_LENGTH


AUTH


NCHA


FMT


I


UNIT


METERS


MXLN


5


KEY


NOKEY


2


MODN


BridgesSchema


RCID


2


NAME


BridgeAtts


TYPE


ATPR


ETLB


BRIDGE


EUTH


SDTS


ATLB


COMPOSITION


AUTH


NCHA


FMT


A


UNIT


null


MXLN


1


KEY


FKEY1


3


MODN


BridgesSchema


RCID


3


NAME


BridgeComp


TYPE


ATSC


ETLB


BRIDGE


EUTH


SDTS


ATLB


COMPOSITION


AUTH


NCHA


FMT


A


UNIT


null


MXLN


1


KEY


PKEY


4


MODN


BridgesSchema


RCID


4


NAME


BridgeComp


TYPE


ATSC


ETLB


BRIDGE


EUTH


SDTS


ATLB


MATERIAL


AUTH


ASTM


FMT


A


UNIT


null


MXLN


1


KEY


PKEY


(Continued)

1

COMPOSITION in BridgeAtts is only part of a foreign key.

Note that in the above example there is one Data Dictionary/Schema module for two attribute modules, confirming that there need not be a one-to-one correspondence between Data Dictionary/Schema modules and attribute modules. Also note that there are two records for the attribute Composition, because it occurs in both the Attribute Primary and Attribute Secondary modules.

C.3 Data Dictionary/Definition Module

The Data Dictionary/Definition module defines the entities and attributes used in the Attribute Primary, Attribute Secondary and Data Dictionary/Schema modules.

The use of the Data Dictionary/Definition module is demonstrated with the following example:

Table 61 - Data dictionary/definition field


Module record number

Subfield mnemonic

Subfield vontents

1


MODN


DDDEF


RCID


1


EORA


ENT


EALB


Lagoon


SRCE


A dictionary of geography, Monkhouse


DFIN


A sheet of salt water separated from ....


AUTH


FDMA


ADSC


Federal Mapping Authority




2


MODN


DDDEF


RCID


2


EORA


ENT


EALB


Bridge


SRCE


Canadian Council on Surveying and Mapping


DFIN


A structure erected over a depression...


AUTH


NCHA


ADSC


National Charting Board, Report Q17-F...




3


MODN


DDDEF


RCID


3


EORA


ATT


EALB


SPAN_LENGTH


SRCE


Bridge Engineering Associates Inc.


DFIN


Distance between bridge abutments...


AUTH


SDTB


ADSC


Spatial Data Transfer Board, publication...


(continued)

In this example the first two records contain entity definitions; the last record defines an attribute of the entity "Bridge." The four-character Attribute Authority codes such SDTB, FDMA, NCHA, would also be used in the Attribute and Entity authority subfields of the Data Dictionary/Schema module for the example transfer.

Table 62 - An example of wildcard character use in this module


Module record number

Subfield mnemonic

Subfieldcontents

1


MODN


DDDEF


RCID


1


EALB


*


AUTH


FDMA


ADSC


Federal Mapping Authority

meaning that the code FDMA as used in each Attribute Definition or Schema field refers to "Federal Mapping Authority" for all attributes ("*" meaning all).

C.4 Data Dictionary/Domain Module

The Data Dictionary/Domain module describes the valid domains for the attributes stored with the Attribute Primary and Attribute Secondary modules.

Table 63 - Data dictionary/domain module example


MODN

RCID

ATLB

AUTH

ATYP

ADVF

ADMU

RAVA

DVAL

DVDF

DDDOMAIN


1


COMPOSITION


SDTS


ALPHABET


A


null


VALUE


Steel


iron &

carbon


DDDOMAIN


2


COMPOSITION


SDTS


ALPHABET


A


null


VALUE


Wood


xylem


DDDOMAIN


3


SPAN_LENGTH


FDMA


INTEGER


I


Meters


MIN


5



DDDOMAIN


4


SPAN_LENGTH


FDMA


INTEGER


I


Meters


MAX


300


The first two records contain the domain type of ALPHABET for the attribute "composition" of the entity "bridge"; the last two contain the upper and lower limits of the range for the attribute "Span_length" of the entity bridge. Note that "Steel" and "Wood" are not part of an enumerated domain, other alphabetic values are legal. With an ENUMERATED domain type, no other values would have been allowed.

C.5 Attribute Labels and SQL Keywords

The standard specifies that an attribute label shall not be identical to an SQL keyword.

Table 64 - The SQL keywords


ALL


FETCH


PASCAL


AND


FLOAT


PLI


ANY


FOR


PRECISION


AS


FORTRAN


PRIVILEGES


ASC


FOUND


PROCEDURE


AUTHORIZATION


FROM


PUBLIC


AVG


GO


REAL


BEGIN


GOTO


ROLLBACK


BETWEEN


GRANT


SCHEMA


BY


GROUP


SECTION


CHAR


HAVING


SELECT


CHARACTER


IN


SET


CHECK


INDICATOR


SMALLINT


CLOSE


INSERT


SOME


COBOL


INT


SQL


COMMIT


INTEGER


SQLCODE


CONTINUE


INTO


SQLERROR


COUNT


IS


SUM


CREATE


LANGUAGE


TABLE


CURRENT


LIKE


TO


CURSOR


MAX


UNION


DEC


MIN


UNIQUE


DECIMAL


MODULE


UPDATE


DECLARE


NOT


USER


DELETE


NULL


VALUES


DESC


NUMERIC


VIEW


DISTINCT


OF


WHENEVER


DOUBLE


ON


WHERE


END


OPEN


WITH


ESCAPE


OPTION


WORK


EXEC


OR



EXISTS


ORDER



(continued)

Examples of valid attribute labels are:

	TYPE, Z_09, VEGETATIONCODING, B, Q_A_1, ATTRIBUTE000000001. 

Example of labels that are not valid are:

	type, 1ATTRIBUTE, _SECONDATTRIBUTE, VALIDATTRIBUTELABEL, Q__ABC, VEGETATION 
CODE, soiltype, SQLERROR and COUNT.

C.6 Suggested Code Sets

The encoding of data content by the sender, based upon the following widely used code sets, will facilitate a more efficient transfer of meaning. It is not the intent of this standard to recommend the coding of all data content, but simply to employ existing code sets where applicable. These sets may be used with the "cs:" convention and the appropriate FIPSPUB number as a domain specification in the Data Dictionary/Domain module.

Each document in the list is preceded by a short subject for reference purposes only.


	CODE SETS
		Catalog of Widely Used Code Sets, FIPSPUB 19-1, 7 Jan 85.

	CONGRESSIONAL DISTRICTS
		Congressional Districts of the United States, FIPSPUB 9, 14 Nov 69.

	COUNTIES
		Counties, and County Equivalents of the States of the United States and District of Columbia, 
FIPSPUB 6-4, 31 Aug 1990.

	COUNTRIES
		Countries, Dependencies, Areas of Special Sovereignty and their Principal Administrative 
Divisions, FIPSPUB 10-3, 9 Feb 84.  Guideline for Implementation of ANSI Codes for the 
Implementation of Names of Countries, Dependencies and Areas of Special Sovereignty, 
FIPSPUB 104, 19 Sep 83.

	CURRENCY
		Codes for Representation of Currencies and Funds, ISO 4217, 15 Jun 78.

	DATES
		Calendar Date, FIPSPUB 4, 1 Nov 68.

	HYDROLOGIC UNITS
		Codes for the Identification of Hydrologic Units in the United States and Caribbean Outlying 
Areas, FIPSPUB 103, 15 Nov 83.

	LOCATIONS
		Representation of Geographic Position Location for Information Interchange, FIPSPUB 70-1, 14 
Nov 86.

	ORGANIZATIONS
		Codes for Identification of Federal and Federally Assisted Organization, FIPSPUB 95, 23 Dec 
82.

	PLACES
		Metropolitan Statistical Areas, FIPSPUB 8-5, 31 Oct 1984.  Guideline:  Codes for Names of 
Populated Places, Primary County Divisions, Other Locational Entities in the United States, 
FIPSPUB 55-1, 30 Dec 83.  Power Plant Identification:  Recommended Practice, IEEE 803-1983 
&IEEE 803A-1983.  Standard Point Location Code (SPLC) Continental Directory, National Motor 
Freight 102-E, 1 May 1984.  National Zip Code and Post Office Directory, U.S.#Postal Service 
Publication 65.

	STATES
		States and Outlying Areas of the United States, FIPSPUB 5-1, 15 Jun 70.

	TIME	
		Representations of Local Time of the Day for Information Interchange, FIPSPUB 58, 01 Feb 79.  
Representations of Universal Time, Local Time Differentials, and United States Time Zone 
References for Information Interchange, FIPSPUB 59, 1 Feb 79.


[Top] [Prev] [Next] [Bottom]
| SDTS Home Page | MCMC Home | Geography | USGS | Search

U.S. Department of the Interior || U.S. Geological Survey
1400 Independence Road, Rolla, MO 65401
For general information call: (573)308-3500
URL: http://mcmcweb.er.usgs.gov/sdts/SDTS_standard_nov97/part1an2.html
Last modified: Monday, 14-Jan-2013 19:27:43 EST
Maintainer: mcmcweb@usgs.gov
Privacy Statement || Disclaimers || FOIA || Accessibility