class CreateCities < ActiveRecord::Migration
  def self.up
    create_table :cities do |t|
      t.string :name
      t.integer :region_id
    end
    add_index :cities, :region_id

    City.create(:name => '北京市', :region_id => 1)
    City.create(:name => '天津市', :region_id => 2)
    City.create(:name => '石家庄市', :region_id => 3)
    City.create(:name => '唐山市', :region_id => 3)
    City.create(:name => '秦皇岛市', :region_id => 3)
    City.create(:name => '邯郸市', :region_id => 3)
    City.create(:name => '邢台市', :region_id => 3)
    City.create(:name => '保定市', :region_id => 3)
    City.create(:name => '张家口市', :region_id => 3)
    City.create(:name => '承德市', :region_id => 3)
    City.create(:name => '沧州市', :region_id => 3)
    City.create(:name => '廊坊市', :region_id => 3)
    City.create(:name => '衡水市', :region_id => 3)
    City.create(:name => '太原市', :region_id => 4)
    City.create(:name => '大同市', :region_id => 4)
    City.create(:name => '阳泉市', :region_id => 4)
    City.create(:name => '长治市', :region_id => 4)
    City.create(:name => '晋城市', :region_id => 4)
    City.create(:name => '朔州市', :region_id => 4)
    City.create(:name => '晋中市', :region_id => 4)
    City.create(:name => '运城市', :region_id => 4)
    City.create(:name => '忻州市', :region_id => 4)
    City.create(:name => '临汾市', :region_id => 4)
    City.create(:name => '吕梁市', :region_id => 4)
    City.create(:name => '呼和浩特市', :region_id => 5)
    City.create(:name => '包头市', :region_id => 5)
    City.create(:name => '乌海市', :region_id => 5)
    City.create(:name => '赤峰市', :region_id => 5)
    City.create(:name => '通辽市', :region_id => 5)
    City.create(:name => '鄂尔多斯市', :region_id => 5)
    City.create(:name => '呼伦贝尔市', :region_id => 5)
    City.create(:name => '巴彦淖尔市', :region_id => 5)
    City.create(:name => '乌兰察布市', :region_id => 5)
    City.create(:name => '兴安盟', :region_id => 5)
    City.create(:name => '锡林郭勒盟', :region_id => 5)
    City.create(:name => '聽阿拉善盟聽', :region_id => 5)
    City.create(:name => '沈阳市', :region_id => 6)
    City.create(:name => '大连市', :region_id => 6)
    City.create(:name => '鞍山市', :region_id => 6)
    City.create(:name => '抚顺市', :region_id => 6)
    City.create(:name => '本溪市', :region_id => 6)
    City.create(:name => '丹东市', :region_id => 6)
    City.create(:name => '锦州市', :region_id => 6)
    City.create(:name => '营口市', :region_id => 6)
    City.create(:name => '阜新市', :region_id => 6)
    City.create(:name => '辽阳市', :region_id => 6)
    City.create(:name => '盘锦市', :region_id => 6)
    City.create(:name => '铁岭市', :region_id => 6)
    City.create(:name => '朝阳市', :region_id => 6)
    City.create(:name => '葫芦岛市', :region_id => 6)
    City.create(:name => '长春市', :region_id => 7)
    City.create(:name => '吉林市', :region_id => 7)
    City.create(:name => '四平市', :region_id => 7)
    City.create(:name => '辽源市', :region_id => 7)
    City.create(:name => '通化市', :region_id => 7)
    City.create(:name => '白山市', :region_id => 7)
    City.create(:name => '松原市', :region_id => 7)
    City.create(:name => '白城市', :region_id => 7)
    City.create(:name => '延边朝鲜族自治州', :region_id => 7)
    City.create(:name => '哈尔滨市', :region_id => 8)
    City.create(:name => '齐齐哈尔市', :region_id => 8)
    City.create(:name => '鸡西市', :region_id => 8)
    City.create(:name => '鹤岗市', :region_id => 8)
    City.create(:name => '双鸭山市', :region_id => 8)
    City.create(:name => '大庆市', :region_id => 8)
    City.create(:name => '伊春市', :region_id => 8)
    City.create(:name => '佳木斯市', :region_id => 8)
    City.create(:name => '七台河市', :region_id => 8)
    City.create(:name => '牡丹江市', :region_id => 8)
    City.create(:name => '黑河市', :region_id => 8)
    City.create(:name => '绥化市', :region_id => 8)
    City.create(:name => '大兴安岭地区', :region_id => 8)
    City.create(:name => '上海市', :region_id => 9)
    City.create(:name => '南京市', :region_id => 10)
    City.create(:name => '无锡市', :region_id => 10)
    City.create(:name => '徐州市', :region_id => 10)
    City.create(:name => '常州市', :region_id => 10)
    City.create(:name => '苏州市', :region_id => 10)
    City.create(:name => '南通市', :region_id => 10)
    City.create(:name => '连云港', :region_id => 10)
    City.create(:name => '淮安市', :region_id => 10)
    City.create(:name => '盐城市', :region_id => 10)
    City.create(:name => '扬州市', :region_id => 10)
    City.create(:name => '镇江市', :region_id => 10)
    City.create(:name => '泰州市', :region_id => 10)
    City.create(:name => '宿迁市', :region_id => 10)
    City.create(:name => '杭州市', :region_id => 11)
    City.create(:name => '宁波市', :region_id => 11)
    City.create(:name => '温州市', :region_id => 11)
    City.create(:name => '嘉兴市', :region_id => 11)
    City.create(:name => '湖州市', :region_id => 11)
    City.create(:name => '绍兴市', :region_id => 11)
    City.create(:name => '金华市', :region_id => 11)
    City.create(:name => '衢州市', :region_id => 11)
    City.create(:name => '舟山市', :region_id => 11)
    City.create(:name => '台州市', :region_id => 11)
    City.create(:name => '丽水市', :region_id => 11)
    City.create(:name => '合肥市', :region_id => 12)
    City.create(:name => '芜湖市', :region_id => 12)
    City.create(:name => '蚌埠市', :region_id => 12)
    City.create(:name => '淮南市', :region_id => 12)
    City.create(:name => '马鞍山市', :region_id => 12)
    City.create(:name => '淮北市', :region_id => 12)
    City.create(:name => '铜陵市', :region_id => 12)
    City.create(:name => '安庆市', :region_id => 12)
    City.create(:name => '黄山市', :region_id => 12)
    City.create(:name => '滁州市', :region_id => 12)
    City.create(:name => '阜阳市', :region_id => 12)
    City.create(:name => '宿州市', :region_id => 12)
    City.create(:name => '巢湖市', :region_id => 12)
    City.create(:name => '六安市', :region_id => 12)
    City.create(:name => '亳州市', :region_id => 12)
    City.create(:name => '池州市', :region_id => 12)
    City.create(:name => '宣城市', :region_id => 12)
    City.create(:name => '福州市', :region_id => 13)
    City.create(:name => '厦门市', :region_id => 13)
    City.create(:name => '莆田市', :region_id => 13)
    City.create(:name => '三明市', :region_id => 13)
    City.create(:name => '泉州市', :region_id => 13)
    City.create(:name => '漳州市', :region_id => 13)
    City.create(:name => '南平市', :region_id => 13)
    City.create(:name => '龙岩市', :region_id => 13)
    City.create(:name => '宁德市', :region_id => 13)
    City.create(:name => '南昌市', :region_id => 14)
    City.create(:name => '景德镇市', :region_id => 14)
    City.create(:name => '萍乡市', :region_id => 14)
    City.create(:name => '九江市', :region_id => 14)
    City.create(:name => '新余市', :region_id => 14)
    City.create(:name => '鹰潭市', :region_id => 14)
    City.create(:name => '赣州市', :region_id => 14)
    City.create(:name => '吉安市', :region_id => 14)
    City.create(:name => '宜春市', :region_id => 14)
    City.create(:name => '抚州市', :region_id => 14)
    City.create(:name => '上饶市', :region_id => 14)
    City.create(:name => '济南市', :region_id => 15)
    City.create(:name => '青岛市', :region_id => 15)
    City.create(:name => '淄博市', :region_id => 15)
    City.create(:name => '枣庄市', :region_id => 15)
    City.create(:name => '东营市', :region_id => 15)
    City.create(:name => '烟台市', :region_id => 15)
    City.create(:name => '潍坊市', :region_id => 15)
    City.create(:name => '威海市', :region_id => 15)
    City.create(:name => '济宁市', :region_id => 15)
    City.create(:name => '泰安市', :region_id => 15)
    City.create(:name => '日照市', :region_id => 15)
    City.create(:name => '莱芜市', :region_id => 15)
    City.create(:name => '临沂市', :region_id => 15)
    City.create(:name => '德州市', :region_id => 15)
    City.create(:name => '聊城市', :region_id => 15)
    City.create(:name => '滨州市', :region_id => 15)
    City.create(:name => '菏泽市', :region_id => 15)
    City.create(:name => '郑州市', :region_id => 16)
    City.create(:name => '开封市', :region_id => 16)
    City.create(:name => '洛阳市', :region_id => 16)
    City.create(:name => '平顶山市', :region_id => 16)
    City.create(:name => '焦作市', :region_id => 16)
    City.create(:name => '鹤壁市', :region_id => 16)
    City.create(:name => '新乡市', :region_id => 16)
    City.create(:name => '安阳市', :region_id => 16)
    City.create(:name => '濮阳市', :region_id => 16)
    City.create(:name => '许昌市', :region_id => 16)
    City.create(:name => '漯河市', :region_id => 16)
    City.create(:name => '三门峡市', :region_id => 16)
    City.create(:name => '南阳市', :region_id => 16)
    City.create(:name => '商丘市', :region_id => 16)
    City.create(:name => '信阳市', :region_id => 16)
    City.create(:name => '周口市', :region_id => 16)
    City.create(:name => '驻马店市', :region_id => 16)
    City.create(:name => '武汉市', :region_id => 17)
    City.create(:name => '黄石市', :region_id => 17)
    City.create(:name => '襄樊市', :region_id => 17)
    City.create(:name => '十堰市', :region_id => 17)
    City.create(:name => '荆州市', :region_id => 17)
    City.create(:name => '宜昌市', :region_id => 17)
    City.create(:name => '荆门市', :region_id => 17)
    City.create(:name => '鄂州市', :region_id => 17)
    City.create(:name => '孝感市', :region_id => 17)
    City.create(:name => '黄冈市', :region_id => 17)
    City.create(:name => '咸宁市', :region_id => 17)
    City.create(:name => '随州市', :region_id => 17)
    City.create(:name => '恩施州', :region_id => 17)
    City.create(:name => '长沙市', :region_id => 18)
    City.create(:name => '株洲市', :region_id => 18)
    City.create(:name => '湘潭市', :region_id => 18)
    City.create(:name => '衡阳市', :region_id => 18)
    City.create(:name => '邵阳市', :region_id => 18)
    City.create(:name => '岳阳市', :region_id => 18)
    City.create(:name => '常德市', :region_id => 18)
    City.create(:name => '张家界市', :region_id => 18)
    City.create(:name => '益阳市', :region_id => 18)
    City.create(:name => '郴州市', :region_id => 18)
    City.create(:name => '永州市', :region_id => 18)
    City.create(:name => '怀化市', :region_id => 18)
    City.create(:name => '娄底市', :region_id => 18)
    City.create(:name => '湘西州', :region_id => 18)
    City.create(:name => '广州市', :region_id => 19)
    City.create(:name => '深圳市', :region_id => 19)
    City.create(:name => '珠海市', :region_id => 19)
    City.create(:name => '汕头市', :region_id => 19)
    City.create(:name => '韶关市', :region_id => 19)
    City.create(:name => '佛山市', :region_id => 19)
    City.create(:name => '江门市', :region_id => 19)
    City.create(:name => '湛江市', :region_id => 19)
    City.create(:name => '茂名市', :region_id => 19)
    City.create(:name => '肇庆市', :region_id => 19)
    City.create(:name => '惠州市', :region_id => 19)
    City.create(:name => '梅州市', :region_id => 19)
    City.create(:name => '汕尾市', :region_id => 19)
    City.create(:name => '河源市', :region_id => 19)
    City.create(:name => '阳江市', :region_id => 19)
    City.create(:name => '清远市', :region_id => 19)
    City.create(:name => '东莞市', :region_id => 19)
    City.create(:name => '中山市', :region_id => 19)
    City.create(:name => '潮州市', :region_id => 19)
    City.create(:name => '揭阳市', :region_id => 19)
    City.create(:name => '云浮市', :region_id => 19)
    City.create(:name => '南宁市', :region_id => 20)
    City.create(:name => '柳州市', :region_id => 20)
    City.create(:name => '桂林市', :region_id => 20)
    City.create(:name => '梧州市', :region_id => 20)
    City.create(:name => '北海市', :region_id => 20)
    City.create(:name => '防城港市', :region_id => 20)
    City.create(:name => '钦州市', :region_id => 20)
    City.create(:name => '贵港市', :region_id => 20)
    City.create(:name => '玉林市', :region_id => 20)
    City.create(:name => '百色市', :region_id => 20)
    City.create(:name => '贺州市', :region_id => 20)
    City.create(:name => '河池市', :region_id => 20)
    City.create(:name => '来宾市', :region_id => 20)
    City.create(:name => '崇左市', :region_id => 20)
    City.create(:name => '海口市', :region_id => 21)
    City.create(:name => '三亚市', :region_id => 21)
    City.create(:name => '重庆市', :region_id => 22)
    City.create(:name => '成都市', :region_id => 23)
    City.create(:name => '自贡市', :region_id => 23)
    City.create(:name => '攀枝花市', :region_id => 23)
    City.create(:name => '泸州市', :region_id => 23)
    City.create(:name => '德阳市', :region_id => 23)
    City.create(:name => '绵阳市', :region_id => 23)
    City.create(:name => '广元市', :region_id => 23)
    City.create(:name => '遂宁市', :region_id => 23)
    City.create(:name => '内江市', :region_id => 23)
    City.create(:name => '乐山市', :region_id => 23)
    City.create(:name => '南充市', :region_id => 23)
    City.create(:name => '宜宾市', :region_id => 23)
    City.create(:name => '广安市', :region_id => 23)
    City.create(:name => '达州市', :region_id => 23)
    City.create(:name => '眉山市', :region_id => 23)
    City.create(:name => '雅安市', :region_id => 23)
    City.create(:name => '巴中市', :region_id => 23)
    City.create(:name => '资阳市', :region_id => 23)
    City.create(:name => '阿坝州', :region_id => 23)
    City.create(:name => '甘孜州', :region_id => 23)
    City.create(:name => '凉山州', :region_id => 23)
    City.create(:name => '贵阳市', :region_id => 24)
    City.create(:name => '六盘水市', :region_id => 24)
    City.create(:name => '遵义市', :region_id => 24)
    City.create(:name => '安顺市', :region_id => 24)
    City.create(:name => '铜仁地区', :region_id => 24)
    City.create(:name => '毕节地区', :region_id => 24)
    City.create(:name => '黔西南州', :region_id => 24)
    City.create(:name => '黔东南州', :region_id => 24)
    City.create(:name => '黔南州', :region_id => 24)
    City.create(:name => '昆明市', :region_id => 25)
    City.create(:name => '曲靖市', :region_id => 25)
    City.create(:name => '玉溪市', :region_id => 25)
    City.create(:name => '保山市', :region_id => 25)
    City.create(:name => '昭通市', :region_id => 25)
    City.create(:name => '丽江市', :region_id => 25)
    City.create(:name => '普洱市', :region_id => 25)
    City.create(:name => '临沧市', :region_id => 25)
    City.create(:name => '文山州', :region_id => 25)
    City.create(:name => '红河州', :region_id => 25)
    City.create(:name => '西双版纳州', :region_id => 25)
    City.create(:name => '楚雄州', :region_id => 25)
    City.create(:name => '大理州', :region_id => 25)
    City.create(:name => '德宏州', :region_id => 25)
    City.create(:name => '怒江州', :region_id => 25)
    City.create(:name => '迪庆州', :region_id => 25)
    City.create(:name => '拉萨市', :region_id => 26)
    City.create(:name => '昌都地区', :region_id => 26)
    City.create(:name => '山南地区', :region_id => 26)
    City.create(:name => '日喀则地区', :region_id => 26)
    City.create(:name => '那曲地区', :region_id => 26)
    City.create(:name => '阿里地区', :region_id => 26)
    City.create(:name => '林芝地区', :region_id => 26)
    City.create(:name => '西安市', :region_id => 27)
    City.create(:name => '铜川市', :region_id => 27)
    City.create(:name => '宝鸡市', :region_id => 27)
    City.create(:name => '咸阳市', :region_id => 27)
    City.create(:name => '渭南市', :region_id => 27)
    City.create(:name => '延安市', :region_id => 27)
    City.create(:name => '汉中市', :region_id => 27)
    City.create(:name => '榆林市', :region_id => 27)
    City.create(:name => '安康市', :region_id => 27)
    City.create(:name => '商洛市', :region_id => 27)
    City.create(:name => '兰州市', :region_id => 28)
    City.create(:name => '嘉峪关市', :region_id => 28)
    City.create(:name => '金昌市', :region_id => 28)
    City.create(:name => '白银市', :region_id => 28)
    City.create(:name => '天水市', :region_id => 28)
    City.create(:name => '武威市', :region_id => 28)
    City.create(:name => '张掖市', :region_id => 28)
    City.create(:name => '平凉市', :region_id => 28)
    City.create(:name => '酒泉市', :region_id => 28)
    City.create(:name => '庆阳市', :region_id => 28)
    City.create(:name => '定西市', :region_id => 28)
    City.create(:name => '陇南市', :region_id => 28)
    City.create(:name => '临夏州', :region_id => 28)
    City.create(:name => '甘南州', :region_id => 28)
    City.create(:name => '西宁市', :region_id => 29)
    City.create(:name => '海东地区', :region_id => 29)
    City.create(:name => '海北藏族自治州', :region_id => 29)
    City.create(:name => '黄南藏族自治州', :region_id => 29)
    City.create(:name => '海南藏族自治州', :region_id => 29)
    City.create(:name => '果洛藏族自治州', :region_id => 29)
    City.create(:name => '玉树藏族自治州', :region_id => 29)
    City.create(:name => '海西蒙古族藏族自治州', :region_id => 29)
    City.create(:name => '银川市', :region_id => 30)
    City.create(:name => '石嘴山市', :region_id => 30)
    City.create(:name => '吴忠市', :region_id => 30)
    City.create(:name => '固原市', :region_id => 30)
    City.create(:name => '中卫市', :region_id => 30)
    City.create(:name => '乌鲁木齐市', :region_id => 31)
    City.create(:name => '克拉玛依市', :region_id => 31)
    City.create(:name => '吐鲁番地区', :region_id => 31)
    City.create(:name => '哈密地区', :region_id => 31)
    City.create(:name => '和田地区', :region_id => 31)
    City.create(:name => '阿克苏地区', :region_id => 31)
    City.create(:name => '喀什地区', :region_id => 31)
    City.create(:name => '克孜勒苏柯尔克孜自治州', :region_id => 31)
    City.create(:name => '巴音郭楞蒙古自治州', :region_id => 31)
    City.create(:name => '昌吉回族自治州', :region_id => 31)
    City.create(:name => '博尔塔拉蒙古自治州', :region_id => 31)
    City.create(:name => '伊犁哈萨克自治州', :region_id => 31)
    City.create(:name => '塔城地区', :region_id => 31)
    City.create(:name => '阿勒泰地区', :region_id => 31)
  end

  def self.down
    drop_table :cities
  end
end
