We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'm using snake case, when using multiple lines ``, sometimes the column/table alias do not get replaced.
``
The first myModel.studentId, just before the or, do not get replaced in this example
myModel.studentId
or
this will not work
.innerJoin(MyModel, 'myModel', 'myModel.foreignId = another.foreignId') .leftJoin( Message, 'msg', ` msg.receiverType = :userType and msg.receiverId = :userId and msg.senderType = 'Something' and msg.senderId = myModel.studentId or msg.receiverType = 'Something' and msg.receiverId = myModel.studentId and msg.senderType = :userType and msg.senderId = :userId ` )
this one will
using .replace(/\s+/g, ' ') will also work
.replace(/\s+/g, ' ')
The text was updated successfully, but these errors were encountered:
@talski I'm facing a similar issue, did you find a way to fix the issue?
Sorry, something went wrong.
@akashjobanputra I'm just removing the spaces before running the query
.innerJoin(MyModel, 'myModel', 'myModel.foreignId = another.foreignId') .leftJoin( Message, 'msg', ` msg.receiverType = :userType and msg.receiverId = :userId and msg.senderType = 'Something' and msg.senderId = myModel.studentId or msg.receiverType = 'Something' and msg.receiverId = myModel.studentId and msg.senderType = :userType and msg.senderId = :userId `.replace(/\s+/g, ' ') )
putting this code .replace(/\s+/g, ' ') will replace all new lines with a simple space
No branches or pull requests
I'm using snake case, when using multiple lines
``
, sometimes the column/table alias do not get replaced.The first
myModel.studentId
, just before theor
, do not get replaced in this examplethis will not work
this one will
using
.replace(/\s+/g, ' ')
will also workThe text was updated successfully, but these errors were encountered: