You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: data_migration/src/syncService.js
+10-5
Original file line number
Diff line number
Diff line change
@@ -12,9 +12,9 @@ const sequelize = new Sequelize(config.get('POSTGRES_URL'), {
12
12
logging: false
13
13
})
14
14
15
-
constSYNC_START_DATE='2020-01-01'
15
+
// const SYNC_START_DATE = '2020-01-01'
16
16
17
-
asyncfunctionmigrateUserTerms(){
17
+
asyncfunctionmigrateUserTerms(startDate){
18
18
constinformixTableName='user_terms_of_use_xref'
19
19
constdatabaseName='common_oltp'
20
20
letrunning=true
@@ -29,7 +29,7 @@ async function migrateUserTerms () {
29
29
if(data.length<1)running=false
30
30
for(leti=0;i<data.length;i+=1){
31
31
consttermsOfUseId=data[i].terms_of_use_id
32
-
constuserQuery=`select * from ${informixTableName} WHERE terms_of_use_id = ${termsOfUseId} AND create_date > DATE("${SYNC_START_DATE}") order by user_id asc`
32
+
constuserQuery=`select * from ${informixTableName} WHERE terms_of_use_id = ${termsOfUseId} AND create_date > DATE("${startDate}") order by user_id asc`
0 commit comments