split partition.sql into table and function parts

Makes it easier to patch partition functions on an already existing
database.
delete outdated entries from location_area_country