Skip to content

Commit

Permalink
修复final
Browse files Browse the repository at this point in the history
  • Loading branch information
steden committed Nov 3, 2024
1 parent 4181420 commit 5ac19fe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tableSet.go
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ func (receiver *TableSet[Table]) getClient() *gorm.DB {

// 使用final
if receiver.useFinal {
receiver.ormClient.Clauses(clause.From{Tables: []clause.Table{{Name: receiver.tableName + " final"}}})
receiver.ormClient.Clauses(hints.IndexHint{Type: "USE INDEX ", Keys: []string{"final"}})
}
return receiver.ormClient
}
Expand Down

0 comments on commit 5ac19fe

Please sign in to comment.