Welcome to RStudio Community!! And thanks for the thorough post!
RStudio Server definitely changes some things (LD_LIBRARY_PATH, PATH, etc.) that could cause trouble.
I would compare environment variables between the place where it works and the place where it doesn't.
Also, it might be worth trying with isql from the
- terminal outside RStudio
- R session outside RStudio
- terminal inside RStudio
- R session inside RStudio (can even do
system("isql"))
If you can isolate the problem to odbc, then I believe you are deeper than I know how to go, and might have something to do with how odbc is loading libraries.
I normally configure system-wide (rather than in a user-specific location) by using:
- /etc/odbc.ini
- /etc/odbcinst.ini
I know there are user specific analogues for odbc.ini (~/.odbc.ini, maybe?), and there may be similar for odbcinst.ini (which points at driver .so files). It may be worth taking a look at those to see if they resolve your issue!!