similar to: Functions Accessing Databases

Displaying 20 results from an estimated 3000 matches similar to: "Functions Accessing Databases"

2010 Jul 05
1
SMB Trans2 Response and STATUS_OBJECT_NAME_NOT_FOUND
Good Morning, let me explain the problem: i need to establish a connection with a Windows host (Windows 7) via smbclient (from ubuntu linux), to run a script which needs to get some file informations (eg. size, version, etc..). Connection and authentication works perfectly. From linux, i can execute the following command: smb: \> allinfo test.txt altname: test.txt create_time: Thu 01 Jul
2012 Mar 24
2
RC / methods package
(I think this is being caused by the new methods package in RC.) In the RC (March 24) some of my packages are generating a Note Note: Method with signature "MySQLConnection#integer" chosen for function "coerce", target signature "TSMySQLConnection#integer". "dbObjectId#integer" would also be valid This is coming from a call to dbGetQuery() in package
2020 Nov 15
2
How to read NTFS ADS (alternate data steams) using libsmbclient?
Hi Samba team, We have a Windows SMB share which contains some files with ADS (alternate data streams). In our client C/C++ code that runs on a Linux client, we want to retrieve the list of ADS of a file and download all the streams, similar to what is provided by smbclient's interactive session (allinfo, get). But as we evaluate libsmbclient (as we'd like to do above in code), we
2008 May 12
1
Insert a recorde into a table using SQL
Dear list, I want to insert a recorde into a SQLite table by dbGetQuery(), but there is a problem when the value contains quotation mark. > dd<-data.frame(txt=c("having both ' and \" in character.","OK")) > library(RSQLite) Loading required package: DBI > con<-dbConnect(dbDriver("SQLite"),":memory:") >
2006 Dec 20
1
DBI + ROracle problem with parser ?? (PR#9424)
Full_Name: Christian Hoffmann Version: 2.4.0 OS: Win 2000 Submission from: (NULL) (193.134.202.252) Database queries using the combination DBI + ROracle are handicapped by quirks in the pipeline between the textual representation of the query and the database engine Oracle. Comments and linefeed at start are interfering: dbGetQuery(conn, query): works: dbGetQuery(conn, "select *
2020 Oct 08
0
Lahman Baseball Data Using R DBI Package
Hi Philip, You've probably realized by now that R doesn't like column names that start with a number. If you try to access an R-dataframe column named 2B or 3B with the familiar "$" notation, you'll get an error: > library(DBI) > library(RSQLite) > con2 <- dbConnect(SQLite(), "~/R_Dir/lahmansbaseballdb.sqlite") > Hack12Batting <-
2011 Feb 28
1
Data type problem when extract data from SQLite to R by using RSQLite
Hi there, When I extract data from SQLite to R, the data types (or modes) of the extracted data seems to be determined by the value of the first row. Please see the following example. When I put the missing values first, the column extracted is of the mode character. > str(dbGetQuery(sql.industry, + "select pya_var from annual_data3 + order by
2020 Oct 08
1
Lahman Baseball Data Using R DBI Package
This is really a feature of SQL, not R. SQL requires that you double quote column names that start with numbers, include spaces, etc., or that are SQL key words. E.g., > d <- data.frame(Order=c("sit","stay","heel"), Where=c("here","there","there"), From=c("me","me","you")) >
2017 Oct 24
2
Creating a data table (frame?) from a SQL Statement?
Hello, I'm new to R so this is probably a simple question for somebody. I have an RScript that reads a CSV on the disk using read.table(...). It then does a boxM test using that data. However, I'm now trying to load the same data via an SQL command, but I can't seem to get the data structure defined so R will like it -- using the included "iris" dataset. I've tried
2010 Dec 10
1
help with RSQLite adding a new column
I'm new to using sql so I'm having difficulties (and worries) in adding a new column of data to a table I have. Its a very large file (around 5 Gb) which is why I'm having to use SQL I have a table with variables ID, IDrec and IDdes and the variables IDrec and IDdes give a mapping of some other values but the other values are associated with the ID variable (think of IDrec and IDdes
2020 Oct 03
1
Lahman Baseball Data Using R DBI Package
The double quotes are required by SQL if a name is not of the form letter-followed-by-any-number-of-letters-or-numbers or if the name is a SQL keyword like 'where' or 'select'. If you are doing this from a function, you may as well quote all the names. -Bill On Fri, Oct 2, 2020 at 6:18 PM Philip <herd_dog at cox.net> wrote: > The \?2B\? worked. Have no idea why. Can
2009 Dec 30
1
seg-fault... but on what
I got the following after running succesfully through this loop 28 million times... the loop opens text files in a directory and inserts line by line into a database... *** caught segfault *** address 0xc0000010, cause 'memory not mapped' Traceback: 1: .getGeneric(f, where, package) 2: getGeneric("coerce", where = where) 3: as(obj, "integer") 4:
2009 Dec 18
1
The RSQLite version of dbGetQuery drops colums
Hi all, I just noticed (the hard way of course) that when a query returns 0 rows, the columns in the resulting data.frame get dropped as well. See the following example code (where conn is an active connection to an SQLite db): > dbGetQuery(conn, "select 1 as hey, 2 as ho where 1") hey ho 1 1 2 > dbGetQuery(conn, "select 1 as hey, 2 as ho where 0") data frame
2020 Oct 02
3
Lahman Baseball Data Using R DBI Package
I?m trying to pull data from one table (batting) in the Lahman Baseball database. Notice X2B for doubles and X3B for triples ? fourth and fifth from the right. The dbGetQuery function runs fine when I leave there two out but I get error messages (in red) when I include 2B/3B or X2B/X3B. Can anyone give me some direction? Thanks, Philip Heinrich
2002 Sep 12
1
DBI / MySQL problems
Hi. I frequently use RMySQL package to interface R with MySQL databases. I was having a try with package DBI and I got the following error: > library(RMySQL) > library(DBI) > drv <- dbDriver("MySQL") > ch <- dbConnect(drv, dbname="mydb", user="myuser", password="mypasswd") > ibm <- dbGetQuery(ch,"select * from table where
2017 Jan 25
2
Enconding
Hola. Tengo un problema incómodo. En el servidor de BD, existe esta tabla: SELECT * FROM motivodebito 1;"Débito presentado extemporáneamente." 2;"Corresponde la aplicación del nomenclador GCBA vigente al momento de la prestación." 3;"No registra convenio de prestaciones vigente al momento de la prestación." 4;"Débito presentado sin documentación ni
2010 Nov 07
1
using variable in rmysql query
Dear All, I am using this query it returns id : id <- dbGetQuery(con1,"SELECT id FROM tenants WHERE name LIKE '%consim%'") But In my case the string "consim" is there in another variable(it is coming from configuration file); > str <- "consim" I am trying to replace the string some this like, but it not working: > id <-
2008 Jan 08
1
Problems with modifying data in a MySQL database
Using the package /RMySQL/ I have established a connection ('con1') to a MySQL-Database called 'mc'. This database contains a table called 'mc_2000' which has 200000 observations on several variables. One of these variables is called 'B5' (type 'double'). When I generate a numeric vector in R called 'B6' that has the same length as 'B5': How
2011 Feb 16
1
Rjdbc dbGetquery execution error
Rjdbc consistently gives me an execution error with postgresql 9.0s JDBC4 driver. It's probably something trivial so am including my code below: library("RJDBC") param <- 249 param2 <- 188129 postgres <- JDBC("org.postgresql.Driver", ".m2/repository/postgresql/postgresql/9.0-801.jdbc4/postgresql-9.0-801.jdbc4.jar") con <- dbConnect(postgres,
2004 Nov 25
3
Searching for a string in RSQLite
I'd like to search for a particular string in an SQLite database using RSQLite, but I'm running into problems constructing the query properly, because of embedded quotes and parens in the string. Is there a function that escapes these for me, or some other fixup that would let me do the queries below? In the real situation I don't have control over what strings get searched for.