I am executing below commands in R:
我在R中执行以下命令:
dbhandle <- odbcDriverConnect('driver={SQL Server};server=serveripaddress;database=DBName;uid=sa;pwd=pwd;')
FactActivity <- sqlQuery(dbhandle, "SELECT DimCourseID,DimPatientID FROM DWH.FactActivity", as.is=TRUE)
nrow(FactActivity)
In my database I have total 238634 rows but in R I am getting total rows = 237652.
在我的数据库中,我总共有238634行但在R中我得到总行数= 237652。
This is happening for all tables (I tried it for three tables).
所有表都会发生这种情况(我试过三个表)。
Any idea what am I missing which is reducing no of rows in my resultset in R?
知道我错过了什么,这减少了R中我的结果集中没有行?
1 个解决方案
#1
1
I had the same problem, couldn't solve it, eventually switched to using RJDBC with a Java driver to get around it.
我有同样的问题,无法解决它,最终切换到使用RJDBC与Java驱动程序来解决它。
#1
1
I had the same problem, couldn't solve it, eventually switched to using RJDBC with a Java driver to get around it.
我有同样的问题,无法解决它,最终切换到使用RJDBC与Java驱动程序来解决它。