Get pool rows by line number so they stay in order

Because otherwise the errors don't line up correctly.
This commit is contained in:
Eli Ribble 2026-04-16 04:01:44 +00:00
parent a9077b6c36
commit d352b0d932
No known key found for this signature in database

View file

@ -195,6 +195,7 @@ func getUploadDetailPool(ctx context.Context, file *models.FileuploadFile) (*Upl
}
pool_rows, err := models.FileuploadPools.Query(
models.SelectWhere.FileuploadPools.CSVFile.EQ(file.ID),
sm.OrderBy(models.FileuploadPools.Columns.LineNumber).Asc(),
).All(ctx, db.PGInstance.BobDB)
if err != nil {
return nil, fmt.Errorf("Failed to query pools for %d: %w", file.ID, err)