weih
bae684b363
fix(clause): when the value of clause.Eq is an empty array, the SQL should be IN (NULL) ( #6503 )
2023-08-10 13:34:33 +08:00
Clark McCauley
540fb49bcb
Fixed #5355 - Named variables don't work when followed by Windows CRLF line endings ( #5356 )
...
* Fixed #5355 .
* Fixed unit test to test both CRLF and CR line endings
2022-05-22 15:16:01 +08:00
Jinzhu
45e804dd3f
Fix call valuer interface when using nil value
2021-11-29 16:19:11 +08:00
Jinzhu
b8f33a42a4
Add unused argument ( #4871 )
...
* Append unused argument to gorm statement
2021-11-23 17:11:52 +08:00
Jim
5202529ea1
fix (clause/expression): Allow sql stmt terminator ( #4693 )
...
Allow the sql stmt terminator ";" at the end of a named parameter.
Example: select * from table_name where name == @name;
2021-09-20 21:40:48 +08:00
Sec Cake
093694fbf2
Fix extra 'AND' when len(values) == 0 ON IN.NegationBuild() ( #4618 )
2021-08-20 18:06:48 +08:00
Jinzhu
76cd73cb82
Fix wipes out MySQL global variables from the query, close #4515
2021-07-13 18:48:43 +08:00
Jinzhu
9abac96546
Fix Eq, Neq support slice of data
2021-05-31 17:21:27 +08:00
Jinzhu
14e96080d8
Eq, Neq support slice of data
2021-05-31 15:25:38 +08:00
Jinzhu
90476fea7a
Fix Join with slice IN, close #4133
2021-03-04 18:40:47 +08:00
Jinzhu
6c0ee2700a
Allow to use Valuer with Eq expression, #3899
2020-12-30 10:42:13 +08:00
vellotis
51b5208599
Fix building of `clause.Eq` and `clause.Neq` expressions that fail to handle `(*T)(nil)` use cases correctly ( #3848 )
...
* Update tests to cover building `clause.Eq` and `clause.Neq` when value could be a nil pointer of a primitive
* Fix use cases for `clause.Eq` and `clause.Neq` when value is nil pointer of a primitive type
2020-12-11 14:07:23 +08:00
Jinzhu
694e42d6a1
Fix clause.IN with only one value of multiple rows
2020-11-17 19:11:24 +08:00
LeoZhan
832abda7a4
refactor: simplify the writing instead of using struct literal ( #3728 )
2020-11-08 09:41:43 +08:00
Jinzhu
c915471169
Support Expression for OrderBy clause
2020-11-03 10:30:05 +08:00
Jinzhu
08ecef8e0b
Fix NamedArguments with nested struct, close #3596
2020-10-13 15:32:29 +08:00
Jinzhu
c9165fe3ca
Don't panic when using unmatched vars in query, close #3488
2020-09-18 21:42:27 +08:00
Jinzhu
d002c70cf6
Support named argument for struct
2020-09-17 21:52:41 +08:00
Jinzhu
2242ac6c0e
Fix tests & refactor for PR #3429
2020-09-09 10:31:48 +08:00
caelansar
aceb3dad3b
correct generated sql
2020-09-08 21:28:04 +08:00
Jinzhu
496db1f13e
Fix named argument with multiple line SQL, fix #3336
2020-08-31 15:45:56 +08:00
Jinzhu
bba569af2b
Add NamedArg support
2020-07-10 12:28:24 +08:00
Jinzhu
c291c2f42c
Add Scanner, Valuer tests
2020-05-30 21:05:27 +08:00
Jinzhu
c422d75f4b
Add Scopes tests
2020-05-30 19:43:29 +08:00
Jinzhu
ac8708b500
Add FirstOrInit support
2020-05-28 13:12:56 +08:00
Jinzhu
68a7a8207a
Test HasOne Association
2020-05-24 23:07:42 +08:00
Jinzhu
504f42760a
Refactor clause Writer
2020-03-09 17:07:00 +08:00
Jinzhu
6d58b62fd4
Add sqlite migration tests
2020-02-22 20:57:29 +08:00
Jinzhu
0be4817ff9
Finish CreateConstraint
2020-02-22 11:15:51 +08:00
Jinzhu
1f38ec4410
Finish clauses tests
2020-02-08 23:23:45 +08:00
Jinzhu
0160bab7dc
Add clause tests
2020-02-05 18:28:58 +08:00
Jinzhu
46b1c85f88
Add more clauses
2020-02-04 08:56:15 +08:00
Jinzhu
9d5b9834d9
Refactor builder
2020-01-30 19:47:00 +08:00