Hi i have to table with IDs in each one.
I want to make a join (as in sql) by the ID. Is any way to use the RODBC
package (or other) in local tables (not a access, mysql, sql, etc. ) and
made the join?
Thanks in advance
__
R-help@stat.math.ethz.ch
On Tue, 28 Aug 2007, Jorge Cornejo Donoso wrote:
Hi i have to table with IDs in each one.
And what is a 'table'? If these are data frames, see ?merge. If they are
tables (which are arrays in R), then still use merge() if they can be
converted to data frames.
I want to make a join (as in
Hi i have to table with IDs in each one.
I want to make a join (as in sql) by the ID. Is any way to use the RODBC
package (or other) in local tables (not a access, mysql, sql, etc. ) and
made the join?
With RODBC it would be normal SQL, so
I guess with local tables you mean data frames?
then
Cornejo Donoso
Verzonden: dinsdag 28 augustus 2007 22:05
Aan: r-help@stat.math.ethz.ch
Onderwerp: [R] sql query over local tables
Hi i have to table with IDs in each one.
I want to make a join (as in sql) by the ID. Is any way to
use the RODBC package (or other) in local tables
Jorge Cornejo Donoso wrote:
Hi i have to table with IDs in each one.
I want to make a join (as in sql) by the ID. Is any way to use the RODBC
package (or other) in local tables (not a access, mysql, sql, etc. ) and
made the join?
I guess you are looking for ?merge
Uwe Ligges
I assume that by local tables you mean data frames in R.
You can use the merge function in the base of R, as others have already
mentioned, or if you want to use SQL syntax you can use the sqldf
package. See example 4 on the sqldf home page:
http://sqldf.googlecode.com
On 8/28/07, Jorge