差分

移動先: 案内検索

Tep3

38 バイト追加, 2022年2月25日 (金) 18:07
ClientsをClientsとOthersに分ける Clients以下は寺ごと(ノートごと)に出し入れする
<pre>
エクスポート
\COPY (select ie_id, user_id, jiin_id, table_order, created_at, updated_at from clients where jiin_id = 1 and nusi = true order by ie_id asc, jiin_id asc) TO '/Users/jq/3tep_gomi/clients_1.csv' WITH CSV DELIMITER ',' FORCE QUOTE * NULL AS '' HEADER;
\COPY (select ie_id, user_id, jiin_id, table_order, created_at, updated_at from clients where jiin_id = 2 and nusi = true order by ie_id asc, jiin_id asc) TO '/Users/jq/3tep_gomi/clients_2.csv' WITH CSV DELIMITER ',' FORCE QUOTE * NULL AS '' HEADER;
...
<pre>
インポート
\COPY clients(id, user_id, note_id, line, created_at, updated_at) FROM '/Users/jq/3tep_gomi/clients_1.csv' WITH CSV DELIMITER ',';
\COPY clients(id, user_id, note_id, line, created_at, updated_at) FROM '/Users/jq/3tep_gomi/clients_2.csv' WITH CSV DELIMITER ',';
...

案内メニュー