Hello -
I can use the arc.open function to successfully import a local .shp file into R. I can also successfully import regular old SQL tables into R using the sqlQuery function in the RODBC package and an ODBC connection.
But I cannot figure out how to import a feature class from SQL (Running ArcGIS for Server) into R directly? I'd like to be able to import files directly so that I'm working with a live dataset, rather than pulling from a static dataset within a a .gdb file.
Solved! Go to Solution.
Brian,
Thanks for the question, this is something that I'll add a note for me to document in the package documentation. To reference a database, there are a couple of approaches:
r <- arc.open('c:/path/to/my.sde/dbname.layername')
The bridge doesn't currently have the underpinnings to figure out the necessary information directly, but either of the above approaches will give you direct access. Let us know if you need anything else.
Cheers,
Shaun
Brian,
Thanks for the question, this is something that I'll add a note for me to document in the package documentation. To reference a database, there are a couple of approaches:
r <- arc.open('c:/path/to/my.sde/dbname.layername')
The bridge doesn't currently have the underpinnings to figure out the necessary information directly, but either of the above approaches will give you direct access. Let us know if you need anything else.
Cheers,
Shaun