Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 201E763303E for ; Fri, 20 Nov 2009 11:03:14 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 53749-05 for ; Fri, 20 Nov 2009 15:03:06 +0000 (UTC) X-Greylist: delayed 00:12:12.972236 by SQLgrey-1.7.6 Received: from smtp.cl.nioo.knaw.nl (smtp.cl.nioo.knaw.nl [194.171.24.210]) by mail.postgresql.org (Postfix) with ESMTP id CC049632C27 for ; Fri, 20 Nov 2009 11:03:03 -0400 (AST) Received: from ctemail1.nioo.int ([10.112.37.30]) by smtp.cl.nioo.knaw.nl with Microsoft SMTPSVC(6.0.3790.3959); Fri, 20 Nov 2009 15:50:38 +0100 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: Re: Sqldf - error message Date: Fri, 20 Nov 2009 15:50:37 +0100 Message-ID: <1276C0564833F043AB4C85ED8DA9CFE502AF0561@ctemail1.nioo.int> In-Reply-To: <162867790911200637l1c16438apc4bfa3ebef0210d2@mail.gmail.com> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [SQL] Sqldf - error message Thread-Index: Acpp8BA16GSSm/w0SEKQXhjNOVe6xAAAKaew References: <1276C0564833F043AB4C85ED8DA9CFE502AF054F@ctemail1.nioo.int> <162867790911200637l1c16438apc4bfa3ebef0210d2@mail.gmail.com> From: "Marvelde, Luc te" To: "Pavel Stehule" Cc: X-OriginalArrivalTime: 20 Nov 2009 14:50:38.0479 (UTC) FILETIME=[D2E549F0:01CA69F0] X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.599 tagged_above=-10 required=5 tests=BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 200911/67 X-Sequence-Number: 33418 Nothing is wrong with the data... Everything is there in the dataframe. = All the names are case sensitive, but the way it is spelled is = correct.... So that cant be the problem Luc=20 -----Original Message----- From: Pavel Stehule [mailto:pavel.stehule@gmail.com]=20 Sent: vrijdag 20 november 2009 15:38 To: Marvelde, Luc te Cc: pgsql-sql@postgresql.org Subject: Re: [SQL] Sqldf - error message Hello 2009/11/20 Marvelde, Luc te : > Hi All! > > I just discovered sqldf and im very enthousiastic, as I am a big fan=20 > of R and I often get frustrated using Access for datamanagement. > > I tried running some queries from Access in R, and it works very well. > However, I have problems with some queries. > > If I run this SQL query: > >> sqldf("SELECT > + dbo_tbl_Terrein.RingCentraleNaam, > + dbo_tbl_Broedsels.BroedselID > + FROM ((dbo_tbl_BroedselLocatie > + INNER JOIN dbo_tbl_Broedsels ON dbo_tbl_BroedselLocatie.BroedselID = =3D > dbo_tbl_Broedsels.BroedselID) > + INNER JOIN dbo_tbl_Nestkasten ON dbo_tbl_BroedselLocatie.NestkastID=20 > + =3D > dbo_tbl_Nestkasten.NestkastID) > + INNER JOIN dbo_tbl_Terrein ON dbo_tbl_Nestkasten.TerreinNummer =3D > dbo_tbl_Terrein.TerreinNummer > + WHERE (((dbo_tbl_Terrein.RingCentraleNaam)=3D'Oosterhout a/d=20 > + Waal'));") > > I get the following message: > > Error in sqliteExecStatement(con, statement, bind.data) : > =A0 RS-DBI driver: (error in statement: no such column: > dbo_tbl_Broedsels.BroedselID) > > ( I also tried removing the 'dbo_tbl_'=A0 part of the dataframe names, = > but still the same problem occurred) I thing, you have a problem with data. Probably some creating script was = broken or some similar. The message is clean. Your database has not = column BroedselID. Recheck your query, please. Im not sure - maybe = SQLite identifiers are case sensitive. Maybe are defined as case = sensitive. Regards Pavel Stehule > > Now ofcoarse I looked on google, because I was sure someone would have = > had the same problem.. And yes, I found this website... > > http://code.google.com/p/sqldf/ > > They say: > This happens when you try to use variable with a dot in it (as dots=20 > have special meaning to SQL) or if you try to use SQL92 reserved = keywords. > SQLite/RSQLite replaces dots with underscores and changes keywords=20 > words so that they can be used. The keywords in question can be found=20 > by entering the following at the R command line: > > .SQL92Keywords > > In this list of keywords, i cannot find any word that is close to the=20 > error... So, i was wondering if someone knows how to solve it.=20 > preferably i do not want to change all variable names, as these names=20 > come from the 'big main database' of the institute. > > The site also says that SQLite/RSQLite can fix the problem... but then = > when i look in their help, i cannot see how i can easily use those=20 > commands... > > Anyone? > > Kind regards, > > Luc te Marvelde > New member :) > > > >