updated
This commit is contained in:
parent
5dd63276cf
commit
dd07901869
@ -64,7 +64,7 @@ func (g *GormDatabase) SyncRows(persistencia dto.Persistencia, rawData *[]map[st
|
|||||||
|
|
||||||
// Procesar lote
|
// Procesar lote
|
||||||
if len(batch) == batchSize || i == len(*rawData)-1 {
|
if len(batch) == batchSize || i == len(*rawData)-1 {
|
||||||
config.Log.Info(logPrefix+" Procesando batch de %d registros", len(batch))
|
config.Log.Println(logPrefix+" Procesando batch de %d registros", len(batch))
|
||||||
|
|
||||||
if len(persistencia.UpdateBy) > 0 {
|
if len(persistencia.UpdateBy) > 0 {
|
||||||
// Updates con múltiples campos
|
// Updates con múltiples campos
|
||||||
@ -81,7 +81,7 @@ func (g *GormDatabase) SyncRows(persistencia dto.Persistencia, rawData *[]map[st
|
|||||||
whereValues = append(whereValues, val)
|
whereValues = append(whereValues, val)
|
||||||
}
|
}
|
||||||
if len(whereParts) < len(persistencia.UpdateBy) {
|
if len(whereParts) < len(persistencia.UpdateBy) {
|
||||||
config.Log.Warnf("⚠️ Registro incompleto para update (faltan claves): %+v", row)
|
config.Log.Debugf("⚠️ Registro incompleto para update (faltan claves): %+v", row)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user