「Heroku」の版間の差分

提供: wikipokpok
移動先: 案内検索
3行目: 3行目:
 
  heroku pg:psql -c "select * from clients_id_seq"
 
  heroku pg:psql -c "select * from clients_id_seq"
  
idで名前と戒名を紐付ける
+
idで名前と戒名を紐付ける<br>
ie_idはあけておく <br>登録の確定により値が入る
+
ie_idはあけておく 登録の確定により値が入る
 
  heroku pg:psql -c "\copy clients (id,name,yomi,ie_id,nusi,user_id,jiin_id,created_at,updated_at,ie_id_v) from '/home/shudo/an_meibo.csv' with csv"
 
  heroku pg:psql -c "\copy clients (id,name,yomi,ie_id,nusi,user_id,jiin_id,created_at,updated_at,ie_id_v) from '/home/shudo/an_meibo.csv' with csv"
  

2019年2月2日 (土) 16:23時点における版

heroku pg:psql -c "\d clients"
heroku pg:psql -c "select * from clients_id_seq"

idで名前と戒名を紐付ける
ie_idはあけておく 登録の確定により値が入る

heroku pg:psql -c "\copy clients (id,name,yomi,ie_id,nusi,user_id,jiin_id,created_at,updated_at,ie_id_v) from '/home/shudo/an_meibo.csv' with csv"
heroku pg:psql -c "\copy kaimyous (content,user_id,jiin_id,client_id,created_at,updated_at,date,ie_id,g_age,relationship,ie_id_v) from '/home/shudo/an_kaimyou.csv' with csv"

scheduleのデータ移行 新しいie_id,client_idは空 履歴に出てこない

heroku pg:psql -c "\copy schedules (datetime,content,jiin_id,user_id,created_at,updated_at,ie_id,client_id,ie_id_v) from '/home/shudo/an_yotei.csv' with csv"

journalデータ移行準備

SELECT * FROM `siwakemeisai` JOIN siwake ON siwakemeisai.`dennpyouBanngou` = siwake.id

schedule_id,client_idは空 それぞれ紐付けできない


heroku pg:backups:capture --app shrxxxxx-xxx-xxx
heroku pg:backups -a shrxxxxx-xxx-xxx
heroku pg:backups:download