Skip to content
This repository has been archived by the owner on Jan 10, 2022. It is now read-only.

Commit

Permalink
some changes
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeyglazyrindev committed Oct 27, 2021
1 parent 0791a37 commit f4502bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/postgres_adapter.go
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ func (d *PostgresAdapter) Minute(operatorContext *GormOperatorContext, field *Fi
}

func (d *PostgresAdapter) Second(operatorContext *GormOperatorContext, field *Field, value interface{}, SQLConditionBuilder ISQLConditionBuilder) {
query := fmt.Sprintf(" EXTRACT('second' FROM %s.%s AT TIME ZONE 'UTC')::integer = ? ", operatorContext.TableName, field.DBName)
query := fmt.Sprintf(" FLOOR(EXTRACT('second' FROM %s.%s AT TIME ZONE 'UTC')) = ? ", operatorContext.TableName, field.DBName)
args := value
operatorContext.Tx = SQLConditionBuilder.Build(operatorContext.Tx, query, args)
}
Expand Down

0 comments on commit f4502bc

Please sign in to comment.