[R] RODBC connections w/o specific database

Pete Cap
2007-04-16T15:10:21Z

Folks,

I'm writing a gui wrapper around RODBC (having abandoned RMySQL) and some
custom analysis scripts.  I'm hoping that I could get some advice.

All of my users will have access to a database server.  I am going to limit
their access to certain databases--a sizeable warehouse in a SAN, and then
smaller storage that they can use for temp files and personal tables.  I want to
present these to the user using a tktree widget, rather like you might see in
Enterprise Guide, with the top level of each tree being a specific database and
branches being tables.

Can I get some advice on a good way to accomplish this?

Right now I can create and connect to a DSN that does not specify a database.  I
suppose that upon connection I could use sqlQuery to get the names of databases
and their tables, then use the result to populate the tree.  However, once a
table has been selected, would I need to create a new connection (since the
existing connection does not specify a database) or could I use the existing one
for everything and just specify database and table in my queries?

Also, any additional advice on would be appreciated if anyone has any.

Thanks,

Pete


---------------------------------


	[[alternative HTML version deleted]]