If you obscure connection details, by using config for example, then the resulting connections pane can be a bit odd. The following connection uses config to store the credentials:
con <- connection_open(
RPostgres::Postgres(),
host = get("host"),
user = get("user"),
password = get("pwd"),
port = get("port"),
dbname = get("database")",
bigint = "integer"
)
Then this connection is made, the following shows up in the RStudio IDE:

Notice that get("database") persists in the connections pane. The name of the database is "retail", as evidenced when the following code is used:
con <- dbConnect(
odbc::odbc(),
driver = "PostgreSQL",
host = get("host"),
user = get("user"),
password = get("pwd"),
port = get("port"),
database = get("database"),
bigint = "integer"
)

In this case, the actual database name ("retail") is shown in the connections pane.
If you obscure connection details, by using
configfor example, then the resulting connections pane can be a bit odd. The following connection usesconfigto store the credentials:Then this connection is made, the following shows up in the RStudio IDE:
Notice that
get("database")persists in the connections pane. The name of the database is "retail", as evidenced when the following code is used:In this case, the actual database name ("retail") is shown in the connections pane.