search for: sqltabl

Displaying 20 results from an estimated 97 matches for "sqltabl".

Did you mean: sqltable
2000 Mar 08
0
RODBC: follow up
...as in odbcPrimaryKeys(0, table) a Dr. Watson occurs, because table does not give a table name. However, it is always a good idea to prevent Dr. Watsons, even if it is triggered by a stupid user, as in my case. (1, may be Davids comment already solves this?) There are still some problems with sqlTables() and sqlQuery() which should return a data.frame, but only return one line. I tried with MS Access and Oracle, and now odbcGetErrMsg() somewhat explains the problem. sqlTables(0) TABLE_QUALIFIER TABLE_OWNER TABLE_NAME TABLE_TYPE REMARKS 1 C:\\TEMP\\db NA MSysACEs SYSTEM TABLE...
2009 Nov 18
3
Re ading multiple Excel 2007 files with a loop
...el 2007 files one at a time with the following example code using R 2.10.0 on a computer running Windows (XP, I think): library(RODBC) channel <- odbcDriverConnect("DRIVER=Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb); DBQ=U:\\test folder\\testA.xlsx; ReadOnly=False") sqlTables(channel) my.data.A <- sqlFetch(channel, "Sheet1") odbcClose(channel) channel <- odbcDriverConnect("DRIVER=Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb); DBQ=U:\\test folder\\testB.xlsx; ReadOnly=False") sqlTables(channel) my.data.B <- sqlFetch(channe...
2001 Jun 22
4
RODBC
Hi, I have tried to install.packages("RODBC"), but it balks: Installing source package `RODBC'' ... creating cache ./config.cache checking for library containing SQLTables... no configure: error: no ODBC driver manager found ERROR: Configuration failed for package `RODBC'' What am I missing? What and where should "SQLTables" be? In another package? What should I tell my administrators to make an ODBC driver manager available to me? --christi...
2011 Jan 23
3
Problem reading PostgreSQL data with RODBC
Dear list - I am having a problem using RODBC to access records from tables in a PostgreSQL database. There is no problem establishing the connection using chnl <- odbcConnect (dsn= ... etc. The DSN seems to be properly set up using the PostgreSQL Unicode ODBC driver, and sqlTables(chnl) works OK and produces a list of tables in the database (they are all in a schema called 'source'). But > seiz.df <- sqlFetch(chnl, 'source.MAIN') fails with the error message Error in odbcTableExists(channel, sqtable) : 'source.main': table not found on cha...
2007 Mar 06
2
Package RODBC
I have some questions about the RODBC package. library(RODBC) # required for those who want to repeat these lines 1st, I noticed that the following sequence does not work: channel <- odbcConnextExcel("test.xls") tables <- sqlTables(channel) name1 <- tables[1, "TABLE_NAME"] # this should be the name plan1 <- sqlFetch(channel, name1) # bang! odbcClose(channel) However, I can circumvent this with: channel <- odbcConnextExcel("test.xls") tables <- sqlTables(channel) name1 <-...
2006 Apr 01
4
-newbie | RODBC import query
...ble) : 'TEST': table not found on channel OK - so it doesn't seem to find the table TEST in test.dbf. I tried lower-case for TEST (i.e., test), but that doesn't seem to solve the problem. OK, so lets pretend I don't know what the table in test.dbf is called, and use sqlTables instead: table_list <- sqlTables(import_dat) When I then enter table_list in the console, I get [1] TABLE_CAT TABLE_SCHEM TABLE_NAME TABLE_TYPE REMARKS <0 rows> (or 0-length row.names) Meaning, what? It almost seems that its telling me there is nothing in test.dbf. Well, there d...
2007 Jul 17
4
[R-sig-DB] RODBC on Oracle DB
essai <- odbcConnect("ORESTE_prod", uid="osis_r", pwd="12miss15" ,case="oracle") > sqlTables(essai)$ORESTE ... 1315 <NA> ORESTE S_PROFESSIONS_OLD TABLE <NA> 1316 <NA> ORESTE S_PROVENANCES TABLE <NA> 1317 <NA> ORESTE S_SEXES TABLE <NA> 1318...
2012 Nov 26
2
puzzling RODBC error
Dear all, I'm trying to connect to an MSAccess database (ArcGIS personal geodatabase). I keep getting an error about the channel when using sqlQuery(). However, sqlTables() does not complain about the channel and lists all tables in the database. If I try sqlFetch(), then R crashes. I'm happy to hear suggestions on how to solve this. Best regards, Thierry > MDB <- odbcConnectAccess("//inbodata/indata/Projects/PRJ_Watervogels/Geoloket/Telgebieden...
2009 Jan 05
1
error message of RODBC...
channel <- odbcConnectExcel("nuova tabella terapia occupazionale mod.xls") > ## list the spreadsheets > sqlTables(channel) TABLE_CAT TABLE_SCHEM TABLE_NAME 1 c:\\TABELLE DEFINITIVE\\nuova tabella terapia occupazionale mod <NA> 'emi tot 2006 OAI_60g TO FU1$' 2 c:\\TABELLE DEFINITIVE\\nuova tabella terapia occupazionale...
2011 Feb 10
2
Rioja package, creating transfer function, WA, "Error in FUN"
...or full values). Alas, I do not know what this means and have struggled to find similar problems to this online. Is there a step I've missed out between assigning the matrices and the WA function? > SWED=odbcConnectExcel(file.choose()) (SWED is the environmental data > file) > sqlTables(SWED) > Env=sqlFetch(SWED, "Sheet1") > odbcClose(SWED) > Env SampleId WTD Moisture pH EC 1 "N1_1" "20" "91.72700" "3.496674" " 85.02688" 2 "N1_2" " 2" "93.88913" "...
2008 Feb 05
1
SAS ODBC
...sfully connect to the database, but no matter which table I query, I get back an empty table with only the column headers. For example: > sqlQuery(con, "select * from PRICES.DB_PRICES") [1] COMMOD_CURVE START_DATE PRICING_DATE PRICE <0 rows> (or 0-length row.names) sqlTables also returns back an empty table: > sqlTables(con) [1] TABLE_QUALIFIER TABLE_OWNER TABLE_NAME TABLE_TYPE REMARKS <0 rows> (or 0-length row.names) And sqlFetch doesn't work either: > sqlFetch(con, "PRICES.DB_PRICES") Error in odbcTableExists(cha...
2010 Jul 22
1
64 bit use of odbcConnectExcel
...s XP. The little function I wrote below I use often to import the first 1001 lines in an excel sheet to R. This works fine on the 32 bit version of R but fails on the 64 bit [both on the same machine, using the same function, importing the same .xls file]. The message from 64 bit R is: Error in sqlTables(channel1) : first argument is not an open RODBC channel In addition: Warning messages: 1: In odbcDriverConnect(con, tabQuote = c("[", "]"), ...) : [RODBC] ERROR: state IM002, code 0, message [Microsoft][ODBC Driver Manager] Data source name not found and no default driver...
2001 Oct 31
1
shared libraries on FreeBSD 4.*
...with Matrix by adding -L/usr/local/lib to the 'FLIBS' variable in $RHOME/etc/Makeconf. Then, it found the library and installed just fine. RODBC gives me the following error: Installing source package `RODBC' ... creating cache ./config.cache checking for library containing SQLTables... no configure: error: no ODBC driver manager found ERROR: Configuration failed for package `RODBC' I have unixODBC and libiodbc installed in /usr/local/lib and "nm -g" returns the symbol SQLTables in libiodbc.so, libodbc.so, libodbcpsql.so, libpsqlodbc.so. -L/usr/local/lib...
2007 Apr 19
2
element search
Dear R-experts, I have got an excel file as attached. I imported it successful with the commands: library(RODBC) channel <- odbcConnectExcel("data2.xls") tables <- sqlTables(channel) # list the names of the spreadsheets name1 <- tables[1, "TABLE_NAME"] # get the name of the 1st spreadsheet plan1 <- sqlQuery(channel, sprintf("select * from [%s]", name1)) odbcClose(channel) # close it Now I want to store each row in variable. Additionally...
2005 Apr 26
2
writing a data frame in excel format
...d a file in excel format into a R data frame using the RODBC library, but I don't know how write a R data frame in excel format. I don't understand the instructions from RODBC user manual. To read an excel file I use. library(RODBC); conex<-odbcConnectExcel("fis_quim.xls"); sqlTables(conex); data<-sqlFetch(conex,"hoja1"); Suppose I modify data and I want to save it as an excel file, How do I do that? Thanks for your help Mario Alfonso Morales Rivera Profesor Auxiliar. Departamento de Matem??ticas y Estadistica. Universidad de C??rdoba.
2009 Jul 14
2
Proper Paste for Data Member
...ber name such that they evaluate properly. actual code below: doEnv <- function(SOURCEDATA,REGDATA,HOUR,ENVNAME,REPORTNAME) { print(SOURCEDATA) print(REGDATA) print(HOUR) print(ENVNAME) print(REPORTNAME) # blah blah blah ... #Raw Data channel1 <- odbcConnectExcel("Q:/metrics.xls") sqlTables(channel1) sh1 <- sqlFetch(channel1, "Actuals$") close(channel1) # Something here is borked like the Chef himself.... tsSource<-ts(paste("sh1$",ENVNAME,sep=""),start=c(2004,1),freq=52) print(tsSource) plot(tsSource,col="grey",type="n") retur...
2009 Sep 24
2
RODBC problem
...l Spector's book (p. 34), after creating a connection named con I did the following: > con RODBC Connection 3 Details: case=nochange DBQ=c:\temp\test.xls DefaultDir=c:\temp Driver={Microsoft Excel Driver (*.xls)} DriverId=790 MaxBufferSize=2048 PageTimeout=5 > tbls <- sqlTables(con) > tbls TABLE_CAT TABLE_SCHEM TABLE_NAME TABLE_TYPE REMARKS 1 c:\\temp\\test <NA> Sheet1$ SYSTEM TABLE <NA> 2 c:\\temp\\test <NA> Sheet2$ SYSTEM TABLE <NA> 3 c:\\temp\\test <NA> Sheet3$ SYSTEM TABLE <NA>...
2003 Jul 09
2
RODBC and Oracle: error "table does not exist"
...ble reading data from an Oracle data base using RODBC Version 1.0-3, R Version 1.7.1, Windows XP, Oracle8 ODBC Driver Version 8.1.6.4.0: > library(RODBC) > channel <- odbcConnect(dsn="PAV32", case="oracle", believeNRows=FALSE) > # ok, this was succesful > x <- sqlTables(channel) > x[37, ] TABLE_CAT TABLE_SCHEM TABLE_NAME TABLE_TYPE REMARKS 37 <NA> TKF ABTGRNAMEN TABLE <NA> > # ok, so the table I am looking for ("ABTGRNAMEN") is there, but: > sqlFetch(channel, "ABTGRNAMEN") [1] "[RODBC] ER...
2004 Apr 22
4
RODBC installation in debian
...whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ANSI C... none needed checking for library containing SQLTables... no configure: error: "no ODBC driver manager found" ERROR: configuration failed for package 'RODBC' ** Removing '/usr/local/lib/R/site-library/RODBC' R > version platform i686-pc-linux-gnu arch i686 os linux-gnu system i686, linux-gnu status major...
2008 Apr 04
1
RODBC / odbcConnectExcel Issue
Can someone throw light on the following problem I am having with RODBC? There's an Excel file I am trying to read from, it has one sheet named 'nameclass'. Thanks in anticipation. Vishal Belsare > library(RODBC) > con = odbcConnectExcel(file.choose()) > tbls <- sqlTables(con) > tbls TABLE_CAT TABLE_SCHEM TABLE_NAME TABLE_TYPE REMARKS 1 T:\\data\\in\\nameclass <NA> nameclass$ SYSTEM TABLE <NA> > qry = paste("SELECT * FROM '",tbls$TABLE_NAME[1],"'",sep="") > result = sqlQuery(co...