You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Clone method of QueryExpressionMap should copy everything(all its fields).
Actual Behavior
When clone method is being used from methods like getManyAndCount, count query is missing comment field which wasn't cloned from QueryExpressionMap.
Seems that "comment" field is the last field added in QueryExpressionMap but this field was missed to be added on clone method.
// include the output in code tags like these!
1. query: /* a comment */ SELECT "simple"."id" AS "simple_id" FROM "sample" "simple"
2. query: SELECT COUNT(1) AS "cnt" FROM "sample" "simple" (missing /* a comment */)
Steps to Reproduce
Create a query builder
Add a comment there
call getManyAndCount
Result:
First main query contains the comment, second query for getting the count does not contain the comment.
Issue Description
Expected Behavior
Clone method of QueryExpressionMap should copy everything(all its fields).
Actual Behavior
When clone method is being used from methods like getManyAndCount, count query is missing comment field which wasn't cloned from QueryExpressionMap.
Seems that "comment" field is the last field added in QueryExpressionMap but this field was missed to be added on clone method.
Steps to Reproduce
Result:
First main query contains the comment, second query for getting the count does not contain the comment.
My Environment
Additional Context
Relevant Database Driver(s)
aurora-data-api
aurora-data-api-pg
better-sqlite3
cockroachdb
cordova
expo
mongodb
mysql
nativescript
oracle
postgres
react-native
sap
sqlite
sqlite-abstract
sqljs
sqlserver
Are you willing to resolve this issue by submitting a Pull Request?
The text was updated successfully, but these errors were encountered: