Sort out all the non-nullable columns with empty values.

This commit is contained in:
Lynn "Zhorken" Vaughan 2014-02-21 16:21:36 -05:00
parent 7b2743be75
commit 5b759feaa2
4 changed files with 5 additions and 8 deletions

View file

@ -23,7 +23,7 @@ id,pocket_id,identifier
22,8,plot-advancement
23,8,unused
24,1,loot
25,6,
25,6,all-mail
26,2,vitamins
27,2,healing
28,2,pp-recovery
@ -34,7 +34,7 @@ id,pocket_id,identifier
34,3,standard-balls
35,1,dex-completion
36,1,scarves
37,4,
37,4,all-machines
38,7,flutes
39,3,apricorn-balls
40,8,apricorn-box

1 id pocket_id identifier
23 22 8 plot-advancement
24 23 8 unused
25 24 1 loot
26 25 6 all-mail
27 26 2 vitamins
28 27 2 healing
29 28 2 pp-recovery
34 34 3 standard-balls
35 35 1 dex-completion
36 36 1 scarves
37 37 4 all-machines
38 38 7 flutes
39 39 3 apricorn-balls
40 40 8 apricorn-box

View file

@ -23,7 +23,7 @@ item_category_id,local_language_id,name
22,9,Plot advancement
23,9,Unused
24,9,Loot
25,9,
25,9,All mail
26,9,Vitamins
27,9,Healing
28,9,PP recovery
@ -34,7 +34,7 @@ item_category_id,local_language_id,name
34,9,Standard balls
35,9,Dex completion
36,9,Scarves
37,9,
37,9,All machines
38,9,Flutes
39,9,Apricorn balls
40,9,Apricorn Box

1 item_category_id local_language_id name
23 22 9 Plot advancement
24 23 9 Unused
25 24 9 Loot
26 25 9 All mail
27 26 9 Vitamins
28 27 9 Healing
29 28 9 PP recovery
34 34 9 Standard balls
35 35 9 Dex completion
36 36 9 Scarves
37 37 9 All machines
38 38 9 Flutes
39 39 9 Apricorn balls
40 40 9 Apricorn Box

View file

@ -261,9 +261,6 @@ def load(session, tables=[], directory=None, drop_tables=False, verbose=False, s
for column_name, value in zip(column_names, csvs):
column = table_obj.c[column_name]
# Oracle treats empty strings as NULL
if not column.nullable and value == '' and oranames:
value = ' '
if column.nullable and value == '':
# Empty string in a nullable column really means NULL
value = None

View file

@ -1062,7 +1062,7 @@ class LocationArea(TableBase):
create_translation_table('location_area_prose', LocationArea, 'prose',
relation_lazy='joined',
name = Column(Unicode(64), nullable=False, index=True,
name = Column(Unicode(64), nullable=True, index=True,
info=dict(description="The name", format='plaintext', official=False)),
)