Giter Club home page Giter Club logo

Comments (3)

jimhester avatar jimhester commented on June 4, 2024 1

As of 0d196d5 this should be fixed. One slight tweak is SQL Server uses double quotes rather than single quotes to quote identifiers, but with that change everything is now working. @nwstephens I think we can close the magnitude ticket for this as well.

library(DBI);con <- dbConnect(odbc::odbc(), "SQLServer2", UID = 'testuser', PWD = 'test');
dbWriteTable(con, "iris", iris)
iris_result <- dbSendQuery(con, "SELECT * FROM iris WHERE \"Petal.Width\" > ?")
dbBind(iris_result, list(2.3))
dbFetch(iris_result)
#>   Sepal.Length Sepal.Width Petal.Length Petal.Width   Species
#> 1          6.3         3.3          6.0         2.5 virginica
#> 2          7.2         3.6          6.1         2.5 virginica
#> 3          5.8         2.8          5.1         2.4 virginica
#> 4          6.3         3.4          5.6         2.4 virginica
#> 5          6.7         3.1          5.6         2.4 virginica
#> 6          6.7         3.3          5.7         2.5 virginica
dbBind(iris_result, list(2.4))
dbFetch(iris_result)
#>   Sepal.Length Sepal.Width Petal.Length Petal.Width   Species
#> 1          6.3         3.3          6.0         2.5 virginica
#> 2          7.2         3.6          6.1         2.5 virginica
#> 3          6.7         3.3          5.7         2.5 virginica
dbClearResult(iris_result)
dbDisconnect(con)

from odbc.

jimhester avatar jimhester commented on June 4, 2024

I can reproduce this but do not yet know the exact cause or a solution

from odbc.

nwstephens avatar nwstephens commented on June 4, 2024

Magnitude wrote back: I have tried running the script that was reported on github using RStudio (R 3.4.0). I am not able to reproduce the problem. The error I'm getting is HY010: [Microsoft][ODBC Driver Manager] Function sequence error which is coming from the driver manager and has nothing to do with the driver. Following the similar steps in ODBC is not causing any issues. Were you also able to reproduce the problem and getting the cursor error? Currently without the driver logs I am unable to investigate further. If you are getting cursor error then I can try to retrace the steps from the logs and see if I'm also hitting it in ODBCtest.

from odbc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.