Returns the current canoical database definition as defined in this file.
Optionally, pass a DBI data source to enable syntax specific to that database.
-Currently, this enables "TYPE=InnoDB" for MySQL databases.
+Currently, this enables "ENGINE=InnoDB" for MySQL databases.
=cut
my $local_options = '';
if ( $datasrc =~ /^dbi:mysql/i ) {
- $local_options = 'TYPE=InnoDB';
+ $local_options = 'ENGINE=InnoDB';
}
###
'payip', 'varchar', 'NULL', 15, '', '',
'geocode', 'varchar', 'NULL', 20, '', '',
'censustract', 'varchar', 'NULL', 20, '', '', # 7 to save space?
+ 'censusyear', 'char', 'NULL', 4, '', '',
+ 'district', 'varchar', 'NULL', 20, '', '',
'tax', 'char', 'NULL', 1, '', '',
'otaker', 'varchar', 'NULL', 32, '', '',
'usernum', 'int', 'NULL', '', '', '',
'coord_auto', 'char', 'NULL', 1, '', '',
'country', 'char', '', 2, '', '',
'geocode', 'varchar', 'NULL', 20, '', '',
+ 'district', 'varchar', 'NULL', 20, '', '',
'location_type', 'varchar', 'NULL', 20, '', '',
'location_number', 'varchar', 'NULL', 20, '', '',
'location_kind', 'char', 'NULL', 1, '', '',
'index' => [ [ 'custnum' ], [ 'billpkgnum' ] ],
},
- 'cust_main_county' => { #county+state+country are checked off the
- #cust_main_county for validation and to provide
- # a tax rate.
+ 'cust_main_county' => { #district+city+county+state+country are checked
+ #off the cust_main_county for validation and to
+ #provide a tax rate.
'columns' => [
'taxnum', 'serial', '', '', '', '',
+ 'district', 'varchar', 'NULL', 20, '', '',
'city', 'varchar', 'NULL', $char_d, '', '',
'county', 'varchar', 'NULL', $char_d, '', '',
'state', 'varchar', 'NULL', $char_d, '', '',
'primary_key' => 'taxnum',
'unique' => [],
# 'unique' => [ ['taxnum'], ['state', 'county'] ],
- 'index' => [ [ 'city' ], [ 'county' ], [ 'state' ], [ 'country' ],
+ 'index' => [ [ 'district' ], [ 'city' ], [ 'county' ], [ 'state' ],
+ [ 'country' ],
[ 'taxclass' ],
],
},
'last_bill', @date_type, '', '',
'susp', @date_type, '', '',
'adjourn', @date_type, '', '',
+ 'resume', @date_type, '', '',
'cancel', @date_type, '', '',
'expire', @date_type, '', '',
'contract_end', @date_type, '', '',
'part_svc' => {
'columns' => [
- 'svcpart', 'serial', '', '', '', '',
- 'svc', 'varchar', '', $char_d, '', '',
- 'svcdb', 'varchar', '', $char_d, '', '',
- 'disabled', 'char', 'NULL', 1, '', '',
- 'preserve', 'char', 'NULL', 1, '', '',
+ 'svcpart', 'serial', '', '', '', '',
+ 'svc', 'varchar', '', $char_d, '', '',
+ 'svcdb', 'varchar', '', $char_d, '', '',
+ 'disabled', 'char', 'NULL', 1, '', '',
+ 'preserve', 'char', 'NULL', 1, '', '',
+ 'selfservice_access', 'varchar', 'NULL', $char_d, '', '',
],
'primary_key' => 'svcpart',
'unique' => [],
'_password_encoding', 'varchar', 'NULL', $char_d, '', '',
'sec_phrase', 'varchar', 'NULL', $char_d, '', '',
'popnum', 'int', 'NULL', '', '', '',
+ 'sectornum', 'int', 'NULL', '', '', '',
'uid', 'int', 'NULL', '', '', '',
'gid', 'int', 'NULL', '', '', '',
'finger', 'varchar', 'NULL', 2*$char_d, '', '',
'server', 'varchar', 'NULL', 64, '', '',
'community', 'varchar', 'NULL', 50, '', '',
'description', 'varchar', '', 200, 'RADIUS Client', '',
+ 'svcnum', 'int', 'NULL', '', '', '',
],
'primary_key' => 'nasnum',
'unique' => [ [ 'nasname' ], ],
#'agentnum', 'int', 'NULL', '', '', '',
'towername', 'varchar', '', $char_d, '', '',
'disabled', 'char', 'NULL', 1, '', '',
+ 'latitude', 'decimal', 'NULL', '10,7', '', '',
+ 'longitude','decimal', 'NULL', '10,7', '', '',
+ 'altitude', 'decimal', 'NULL', '', '', '',
+ 'coord_auto', 'char', 'NULL', 1, '', '',
],
'primary_key' => 'towernum',
'unique' => [ [ 'towername' ] ], # , 'agentnum' ] ],
],
'primary_key' => 'ratedetailnum',
'unique' => [ [ 'ratenum', 'orig_regionnum', 'dest_regionnum' ] ],
- 'index' => [ [ 'ratenum', 'dest_regionnum' ] ],
+ 'index' => [ [ 'ratenum', 'dest_regionnum' ],
+ [ 'ratenum', 'ratetimenum' ]
+ ],
},
'rate_region' => {
'charged_party', 'varchar', 'NULL', $char_d, '', '',
# how it was rated internally...
- 'rated_price', 'decimal', 'NULL', '10,4', '', '',
- 'rated_seconds', 'int', 'NULL', '', '', '',
- 'rated_minutes', 'double precision', 'NULL', '', '', '',
+ 'rated_pretty_dst', 'varchar', 'NULL', $char_d, '', '',
+ 'rated_regionname', 'varchar', 'NULL', $char_d, '', '',
+ 'rated_price', 'decimal', 'NULL', '10,4', '', '',
+ 'rated_seconds', 'int', 'NULL', '', '', '',
+ 'rated_minutes', 'double precision', 'NULL', '', '', '',
+ 'rated_granularity', 'int', 'NULL', '', '', '',
+ 'rated_ratedetailnum', 'int', 'NULL', '', '', '',
+ 'rated_classnum', 'int', 'NULL', '', '', '',
+ 'rated_ratename', 'varchar', 'NULL', $char_d, '', '',
'carrierid', 'int', 'NULL', '', '', '',