|
@@ -195,14 +195,19 @@ func GetNewIndexAndDataFromJiaYue() (indexList []*response.IndexResp, err error)
|
|
|
|
|
|
// TODO:测试
|
|
|
endTime := time.Date(2023, 6, 8, 0, 0, 0, 0, time.Local).Format(utils.FormatDateTime)
|
|
|
- indexCond += fmt.Sprintf(`CREATE_TIME <= TO_DATE (%s, 'yyyy-mm-dd hh:mi:ss')`, endTime)
|
|
|
+ indexCond += fmt.Sprintf(`CREATE_TIME <= TO_DATE ('%s', 'yyyy-mm-dd hh:mi:ss')`, endTime)
|
|
|
//indexPars = append(indexPars, endTime)
|
|
|
sourceArr := []string{"bloomberg", "bloomberg_tmp"}
|
|
|
if len(sourceArr) > 0 {
|
|
|
- indexCond += fmt.Sprintf(` AND SOURCE_TYPE IN (%s)`, utils.GetOracleInReplace(len(sourceArr)))
|
|
|
+ str := ``
|
|
|
for _, s := range sourceArr {
|
|
|
- indexPars = append(indexPars, s)
|
|
|
+ str += fmt.Sprintf(`'%s',`, s)
|
|
|
}
|
|
|
+ str = strings.TrimRight(str, ",")
|
|
|
+ indexCond += fmt.Sprintf(` AND SOURCE_TYPE IN (%s)`, str)
|
|
|
+ //for _, s := range sourceArr {
|
|
|
+ // indexPars = append(indexPars, s)
|
|
|
+ //}
|
|
|
}
|
|
|
|
|
|
indexes, e := jiayue.GetDictIndex(indexCond, indexPars, "CREATE_TIME ASC")
|