Dacian Stanciu
|
4e74c80b67
|
fix: Legacy MsSQL - legacy offset select sql command bug #2446 (#2448)
fix for MsSQL legacy bug
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-on: https://gitea.com/xorm/xorm/pulls/2448
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Dacian Stanciu <daci28@yahoo.com>
Co-committed-by: Dacian Stanciu <daci28@yahoo.com>
|
2024-04-24 13:47:05 +00:00 |
Kos
|
11e96d9654
|
Update internal/statements/legacy_select.go (#2400)
fix #2399, When Oracle enables USE_LEGACY_LIMIT_OFFSET, the Where condition fails
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-on: https://gitea.com/xorm/xorm/pulls/2400
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Kos <kos@noreply.gitea.com>
Co-committed-by: Kos <kos@noreply.gitea.com>
|
2024-02-05 11:13:17 +00:00 |
Lunny Xiao
|
0f085408af
|
some refactors for write functions (#2342)
Reviewed-on: https://gitea.com/xorm/xorm/pulls/2342
|
2023-10-25 07:11:18 +00:00 |
FlyingOnion
|
551de3767c
|
modify limit offset implement (#2188)
Oracle and SQLServer specific: When `LIMIT OFFSET` function is needed, use `OFFSET <offset> ROWS FETCH NEXT <limit> ROWS ONLY` to replace legacy subquery.
SQLServer specific: When `ORDER BY` is not set and `OFFSET FETCH` is set, set `statement.orderStr` to `1` (`ORDER BY 1`). See [here](https://learn.microsoft.com/zh-cn/sql/t-sql/queries/select-order-by-clause-transact-sql?view=sql-server-ver16).
MySQL specific: When limit is 0 and offset > 0, use `LIMIT 9223372036854775807` ($2^{63}-1$). See comments [here](15d171ea55/internal/statements/query.go (L314) ).
Reviewed-on: https://gitea.com/xorm/xorm/pulls/2188
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: FlyingOnion <731677080@qq.com>
Co-committed-by: FlyingOnion <731677080@qq.com>
|
2023-09-20 02:07:03 +00:00 |