manual python

2
U U s s i i n n g g   A A r r c c G G I I S S   D D e e s s k k t t o o p p 1 1 2 2 0 0 You •rst create a domain and enter the codes and descriptions, or specify the numeric range. A coded value domain can apply to any type of attribute—text, numeric, date, and so on. The domain type must match the data type you’re creating the domain for (if the •eld is integer, the domain type must also be integer). You then associate the domain with a •eld in one or more feature classes or tables in the geodatabase. T T o o   c c r r e e a a t t e e   a a   d d o o m m a a i i n n , ,  r r i i g g h h t t - - c c l l i i c c k k   t t h h e e   g g e e o o d d a a t t a a b b a a s s e e   i i n n   t t h h e e   C C a a t t a a l l o o g g   t t r r e e e e   a a n n d d   c c l l i i c c k k   P P r r o o p p e e r r t t i i e e s s . .  S S e e l l e e c c t t   t t h h e e   D D o o m m a a i i n n s s   t t a a b b   o o n n   t t h h e e   D D a a t t a a b b a a s s e e   P P r r o o p p e e r r t t i i e e s s   d d i i a a l l o o g g   b b o o x x . . De•ning a code domain—select Coded V V a a l l u u e e s s   i i n n   t t h h e e   D D o o m m a a i i n n   T T y  y p p e e   b b o o x x . . De•ning a range domain—select Range in the D D o o m m a a i i n n   T T y  y p p e e   b b o o x x . . E E n n t t e e r r   t t h h e e   n n a a m m e e   a a n n d d   d d e e s s c c r r i i p p t t i i o o n n C C l l i i c c k k   i i n n   t t h h e e   b b o o x x   t t o o   select the •eld type E E n n t t e e r r   t t h h e e   m m i i n n i i m m u u m m   a a n n d d   m m a a x x i i m m u u m m   v v a a l l u u e e s s   f f  o o r r   t t h h e e   r r a a n n g g e e E E n n t t e e r r   t t h h e e   c c o o d d e e   v v a a l l u u e e s s   a a n n d d   d d e e s s c c r r i i p p t t i i o o n n s s C C l l i i c c k k   a a n n y  y w w h h e e r r e e   i i n n   t t h h e e   row to select the •eld C C l l i i c c k k   t t h h i i s s   b b o o x x   t t o o   s s e e l l e e c c t t   t t h h e e   d d o o m m a a i i n n   f f  r r o o m m   t t h h e e   l l i i s s t t    After creating a d omain, associate it with a •eld by a a c c c c e e s s s s i i n n g g   t t h h e e   p p r r o o p p e e r r t t i i e e s s   f f  o o r r   t t h h e e   f f  e e a a t t u u r r e e   c c l l a a s s s s   o o r r   t t a a b b l l e e . .  R R i i g g h h t t - - c c l l i i c c k k   t t h h e e   f f  e e a a t t u u r r e e   c c l l a a s s s s   i i n n   t t h h e e   C C a a t t a a l l o o g g   t t r r e e e e , ,  c c l l i i c c k k   P P r r o o p p e e r r t t i i e e s s , ,  a a n n d d   s s e e l l e e c c t t   t t h h e e   F F i i e e l l d d s s   t t a a b b . .

Upload: mathias-eder

Post on 08-Jan-2016

9 views

Category:

Documents


0 download

DESCRIPTION

manual python

TRANSCRIPT

Page 1: Manual Python

7/17/2019 Manual Python

http://slidepdf.com/reader/full/manual-python 1/2

UU ss ii nn gg  AArr cc GG II SS  DD ee ss kk tt oo pp 

112200

You •rst create a domain and enter the codes and descriptions, or specify the numeric range. A coded value domaincan apply to any type of attribute—text, numeric, date, and so on. The domain type must match the data type you’re

creating the domain for (if the •eld is integer, the domain type must also be integer).

You then associate the domain with a •eld in one or more feature classes or tables in the geodatabase.

TT oo  cc rr ee aa tt ee  a

a  dd oo mm aa 

i

i nn ,, rr ii gg hh tt --cc ll ii cc kk  

tt hh ee  g

g ee oo dd aa 

tt aa bb aa 

s

s ee  ii nn  tt hh ee  CC aa 

tt aa ll oo gg  

tt rr ee ee  a

a nn dd  cc ll ii cc kk  PP rr oo pp ee rr tt ii ee ss 

.. SS ee ll ee cc tt  

tt hh ee  DD oo mm aa ii nn ss  tt aa bb  oo nn  tt hh ee  DD aa tt aa bb aa ss ee  

P

P rr oo pp ee rr tt ii ee ss 

 

d

d i

i a

a l

l o

o g

 

b

b o

o x

x .

.

De•ning a code domain—select Coded

VV aa l

l u

u ee ss 

 

i

i n

 

tt hh ee  D

D o

o mm aa 

i

i n

 

TT y y pp ee  b

b o

o xx ..

De•ning a range domain—select Range in the

D

D o

o mm aa 

i

i n

 

TT y y pp ee  b

b o

o xx ..

E

E n

n t

t e

e r

 

t

t h

h e

 

n

n a

a m

m e

 

a

a nn dd  dd ee 

s

s cc rr ii pp tt ii oo nn 

C

l

i

c

k

 

i

n

 

t

h

e

 

b

o

x

 

t

o

 select the •eld type

E

E n

n t

t e

e r

 

t

t h

h e

 

m

m i

i n

n i

i m

m u

u m

 

a

a n

n d

 

mm aa x

x ii mm uu mm  v

v a

a ll uu ee 

s

 

f

f  o

o rr  t

t h

h e

 

rr aa n

n g

g e

EE nn tt ee rr  t

t hh ee 

 

cc oo dd ee 

 

v

v a

a l

l u

u e

e s

 

a

a n

n d

 

dd ee s

s cc rr ii pp tt ii oo nn ss 

C

C ll ii cc kk  a

a nn y y ww 

hh ee rr ee 

 

ii nn  t

t hh ee 

 

row to select the •eld 

C

l

i

c

k

 

t

h

i

s

 

b

o

x

 

t

o

 

s

e

l

e

c

t

 

t

h

e

 

d

o

m

a

i

n

 

f

f  

r

o

m

 

t

h

e

 

l

i

s

t

 

 After creating a domain, associate it with a •eld by

a

a cc cc ee ss 

s

s i

i n

n g

 

tt hh ee  p

p rr oo pp ee rr tt ii ee ss 

 

ff  oo rr  tt hh ee  ff  ee aa tt uu rr ee  cc ll aa 

s

s s

 

o

o rr  

tt aa bb ll ee .. RR ii gg hh tt --cc ll ii cc kk  tt hh ee  ff  ee aa 

tt uu rr ee  cc ll aa s

s s

s  i

i nn  tt hh ee  CC aa 

tt aa l

l o

o g

g  

tt rr ee ee ,, cc ll ii cc kk  PP rr oo pp ee rr tt ii ee ss ,, a

a nn dd  s

s ee ll ee cc tt  tt hh ee  FF ii ee ll dd ss 

 tt aa bb ..

Page 2: Manual Python

7/17/2019 Manual Python

http://slidepdf.com/reader/full/manual-python 2/2

22  •

•  GG ee oo gg rr aa pp hh ii cc  DD aa tt aa  MM aa nn aa gg ee mm ee nn tt 

112211

Domains are created at the geodatabase level (for the entire geodatabase rather than for a feature dataset or individualfeature class) so they can be assigned to any of the feature classes or tables in the geodatabase. For example, a single

 paving type domain could be assigned to both a Paving_type attribute in a highways feature class and a Surface_type

attribute in a streets feature class. Domains are managed using the Domains property page, which can be accessed

from the geodatabase’s properties dialog box, or from the Feature Class or Table Properties dialog box. The Domains

 property page can be used to delete an attribute domain from the geodatabase or modify an existing domain.

Code domains constrain the values you can enter when editing attributes in ArcMap—a drop-down menu lets you

choose from the valid attribute values. A range domain doesn’t constrain the value that can be entered, but when you

validate your edits, any values that are outside the range will generate a warning so you can •x the error (see ‘Checking

y yoouurr ddaattaa ff oorr eerrrroorrss’’ iinn CChhaapptteerr 33) )..

U

U

s

s

i

i

n

n

g

g

 

s

s

u

u

b

b

t

t

y

y

p

p

e

e

s

s

 

t

t

o

o

 

a

a

s

s

s

s

i

i

g

g

n

n

 

d

d

e

e

f

a

a

u

u

l

l

t

t

 

v

v

a

a

l

l

u

u

e

e

s

s

 

a

a

n

n

d

d

 

d

d

o

o

m

m

a

a

i

i

n

n

s

s

S

S

u

u

b

b

t

t

y

 y

p

p

e

e

s

s

 

a

a

r

r

e

e

 

b

b

a

a

s

s

e

e

d

d

 

o

o

n

n

 

c

c

a

a

t

t

e

e

g

g

o

o

r

r

i

i

e

e

s

s

 

o

o

r

r

 

c

c

l

l

a

a

s

s

s

s

e

e

s

s

 

w

w

i

i

t

t

h

h

i

i

n

n

 

a

a

 

f

e

e

a

a

t

t

u

u

r

r

e

e

 

c

c

l

l

a

a

s

s

s

s

 

o

o

r

r

 

t

t

a

a

b

b

l

l

e

e

,

,

 

a

a

n

n

d

d

 

a

a

r

r

e

e

 

a

a

 

w

w

a

a

y

 y

 

o

o

f

 

a

a

s

s

s

s

i

i

g

g

n

n

i

i

n

n

g

g

 

d

d

e

e

f

a

a

u

u

l

l

t

t

 

v

v

a

a

l

l

u

u

e

e

s

s

 

and attribute domains without having to create separate feature classes or tables for each category. For example, in a

water network, it may be that transmission water mains can have a pressure between 40 and 100 psi, while distribution

water mains can have a pressure between 50 and 75 psi. Rather than creating separate feature classes for transmission

and distribution water mains, you’d create two subtypes—“transmission mains” and “distribution mains”—within the

water mains feature class. You could then assign different range domains for the water pressure •eld to each. Subtypes

ccaann aallssoo bbee uusseedd ttoo aassssiiggnn ddiiff ff eerreenntt ttooppoollooggy y rruulleess ttoo ddiiff ff eerreenntt tty yppeess ooff  ff eeaattuurreess wwiitthhiinn aa ff eeaattuurree ccllaassss ((sseeee tthhee pprreevviioouuss section, ‘Ensuring spatial data integrity’).

The subtype for a feature in a feature class or a record in a table is determined by its subtype code value. The •eld

you’re using to de•ne subtypes must be short or long integer. If the values are currently stored as text attributes in

the table (as category values often are), you’ll need to add an integer •eld to the table and assign a numeric code to

each category value (see ‘Adding •elds and calculating attribute values’ in Chapter 5). For example, if you’re creating

subtypes for a parcel feature class using a general landuse code, and the categories are “residential,” “non-residential,”

and “undeveloped,” you’d need to add a new •eld to the feature class and assign an integer value to each feature based

on its landuse category—say 0, 1, and 2, respectively. You’d then use this new •eld to create the subtypes.

When editing a •eld with a code domain (in ArcMap), the attribute value is selected

f

f  

r

o

m

 

a

 

d

r

o

p

-

-

d

o

w

n

 

l

i

s

t

.

.

WW ii tt hh oo uu tt  tt hh ee  dd oo mm aa i

i nn ,, vv aa 

l

l u

u ee ss 

 hh aa vv ee  tt oo  bb ee  tt y y pp ee dd  

ii nn .. NN oo tt  o

o nn ll y y  dd oo ee ss 

 tt hh ee  dd oo mm aa ii nn  s

s a

a vv ee  tt ii mm ee ,, ii tt  

a

l

s

o

 

h

e

l

p

s

 

p

r

e

v

e

n

t

 

d

a

t

a

 

e

n

t

r

y

 y 

 

e

r

r

o

r

s

.

.