@931876502
2016-09-29T16:42:24.000000Z
字数 282
阅读 387
postgresql
postgresql重置自增主键:
TRUNCATE TABLE order_to_restore ;
ALTER SEQUENCE order_to_restore_otr_id_seq RESTART WITH 1;
导出表数据到CSV文件:
copy (SELECT ip_format,ip,country, area, region, city, county FROM analytics_ip_data where area is not null) to '/tmp/ip/analytics_ip_data.csv' DELIMITER ',' CSV;