-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
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
Allow SQLDriverConnect instead of SQLConnect #9
Comments
This looks like a great idea. Looking at the code, I think detail::connection_handle_t doesn't need any of the information that's only used for SQLConnect so there is a bit of work to be done there and then just add some alternate config structs and connection constructors. I might work on it this week. I'll be adding constructors for |
@psykora I made a branch feature/alternate_connects which adds There are some breaking changes. ODBC_Type is now in sqlpp11::odbc instead of |
@Erroneous1: Thanks! I didn't expect so prompt action. 👍 |
@Erroneous1 I cherry-picked your commit into master and the driver connection works great! |
Btw. here is what I had to change to pass compilation under MSVC 2017 15.6 my cmake configure command: |
Yeah I accidentally branched from an old branch instead of master. I'll be
making a new branch soon with the same interface but from master. That's
why I was having cmake issues as well.
…On Thu, Jun 14, 2018, 07:16 psykora ***@***.***> wrote:
Btw. here is what I had to change to pass compilation under MSVC 2017 15.6
***@***.***
<psykora@14d2aa7>
my cmake configure command:
cmake .. -DCMAKE_PREFIX_PATH=C:\work\inst
-DHinnantDate_ROOT_DIR=C:\work\inst\date_prj
-DCMAKE_INSTALL_PREFIX=C:\work\inst\sqlpp11-connector-odbc
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AE-Q6yS9BarbDjX3GSp4eZJ1Bz2o8DX5ks5t8kYFgaJpZM4UkTlj>
.
|
Ok try out feature/SQLDriverConnect instead. This is modified from master instead of an old branch. I am also making giving it a string reference optional since you don't need it if you know the config is correct anyway. |
It works well, I will send you several pull requests and you can check whether it still compiles with clang. I am compiling with MSVC and some of the changes are necessary to pass compilation. |
Currently the ODBC connector is using
SQLConnect
which requires datasource to be defined in the system (Windows) or ini file (Unix).It would be nice to be able to specify connection string during runtime. Something like this (example for MSSQL server)
Driver={SQL Server};Server=SERVER_HOSTNAME\INSTANCE;Database=DBNAME;Uid=DBUSER;Pwd=DBPASS;
The text was updated successfully, but these errors were encountered: