MSQQL Server quotes should be [ ] instead of " " #157
Labels
No Label
backport/done
backport/v1
blocked
db
oracle
db
sqlserver
duplicate
feature
cache
frontport/done
frontport/main
invalid
kind
breaking
kind
bug
kind
build
kind
dependencies
kind
docs
kind
driver
kind
enhancement
kind
feature
kind
performance
kind
proposal
kind
question
kind
refactor
kind
testing
need
feedback
need
test
proposal:accepted
RaspBerry Pi
regression
skip-changelog
upstream
wip
wontfix
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: xorm/xorm#157
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
MSSQL Server allows you to quote table/db names with
"
, but it is finnicky on Linux systems using FreeTDS. My recommended fix is to use[ ]
quoting instead. I will upload a patch once I finish.I also have a test case below, the issue is on Linux UnixODBC using FreeTDS driver with SQL Server 2008.
TEST CASE
In sql:
Xorm:
SQL Generated:
Error Generated:
Issue replicated within iSql Console - Also notice the col value when I fix the table name but not the cols:
A good idea. Expecting your pull request.
I'm still working on this, it is slightly more complex than I was originally expecting due to the fact that the quote characters are different on each side. With my current solution, this minor change affects almost every file in the repo; so I am trying to find something a bit more creative.
@dlasley, We have a new plan that will avoid most of quote strings. The quote only display before or after a reserved word. So I think maybe you can continue your work after our changes. @nashtsai
@nashtsai - Sounds great, I can't wait to see the changes. Would you mind updating this thread when complete so that I may resume any work that will be necessary to complete this?
@dlasley Of course.
@dlasley, sorry about things has gone slow recently, I am not able to verify MSSQL myself, would you mind switch to tidy-up/quotes branch for "core", "xorm", and "tests" repos to check it out
@nashtsai - no worries, we all get busy! I have pulled the branches and tests are passing from the Linux box. Thanks for the hard work