rstudio / db.rstudio.com Goto Github PK
View Code? Open in Web Editor NEWWebsite dedicated to all things R and Databases
Home Page: http://db.rstudio.com
License: Creative Commons Attribution Share Alike 4.0 International
Website dedicated to all things R and Databases
Home Page: http://db.rstudio.com
License: Creative Commons Attribution Share Alike 4.0 International
cc @nwstephens
I think it would be really helpful, if there was an article about adding and more importantly updating existing records in a database through R, and the best practices to use. There are many excellent resources on downloading, cleaning and transforming data in R, but data warehousing is a crucial piece missing in the data pipeline.
Provide some FAQ level answers to common issues users have reported when connecting and using a database. It should consist mostly of links to other articles, such as:
And links to the Known Issues sections of those databases we have documented issues for.
The main idea is to have a very visible "Troubleshooting" link in the page that users can go in. We can update it as users report to use that they couldn't find what they were looking for.
Another idea is to include the link to community.rstudio.com to also cover non-customers who are still having issues.
MySQL does not have a boolean type and uses TINYINT instead. Therefore, if you write logical values they will get returned as integers. Please make a note in the documentation.
Add a section to Impala about cleaning up your metadata. If you create a table in Impala and then drop the Hive metadata, you will need to invalidate the Impala metadata.
impala_con <- dbConnect(odbc::odbc(), "Impala")
dbWriteTable(impala_con, "mtcars", mtcars)
hive_con <- dbConnect(odbc::odbc(), "Hive")
dbRemoveTable(hive_con, "mtcars")
dbReadTable(impala_con, "mtcars") # succeeds
dbExistsTable(impala_con, "mtcars") # fails
dbGetQuery(odbcCon, "INVALIDATE METADATA mtcars")
dbExistsTable(impala_con, "mtcars") # succeeds
This happens because dropping the Hive metadata does not drop the Impala metadata. More information can be found here.
Put together an article that discusses steps to take during and after a Shiny app that uses a database as it's source is built. Using an example, the plan is to show how to use the following tools to improve the app's performance:
pool
packageprofvis
, and possibly shinyloadtest
, after the app is completeshow_query()
and explain()
to troubleshoot long running queriesThe article should also include links to these pages:
Under the "Connection Settings" header, then the "Driver" bullet.
In "See the Drivers section for setup information", the word Driver is a hyperlink to https://db.rstudio.com/redshift/drivers which loads a "Page Not found" page.
It is not entirely clear to me if the expected behavior is to lead to the anchor tag above https://db.rstudio.com/redshift/#driver-options or if there was supposed to be a page in the location it links to.
The PostgreSQL has identical behavior, except the link that isn't found is https://db.rstudio.com/postgresql/drivers and I do not seem to see an anchor tag on the page that would make sense for it to jump to.
Most references are pointed to RPostgreSQL
package, need to make sure all are pointed to that package instead of RPostgres
And instead use named parameters to dbConnect()
Expand on the ideas on this thread:
https://community.rstudio.com/t/why-does-rstudio-documentation-recommend-odbc-vs-jdbc-drivers/2381/5
cc @hadley
It looks like we need to add connection pages, such as this one for MS SQL (https://db.rstudio.com/databases/microsoft-sql-server/), for the new drivers we offer:
Can you add examples as comments to this Issue? I'll be glad to create each page
In the /dplyr page
cc @krlmlr
The current pool page doesn't go into much detail about where and when to use different pool
functions.
For example:
pool
objectpoolCheckout()
poolReturn()
poolClose()
The current page also only has guidance when using dplyr
to query, but not using custom SQL.
Add:
{{ template "_internal/google_analytics.html" . }}
To a new footer-custom.html file inside the layouts/partial folder
Under the Availability header the code block for installing dbplyr reads:
devtools::install_github("tidyvers/dbplyr")
It should instead read:
devtools::install_github("tidyverse/dbplyr")
@hannesmuehleisen - I think that we should include MonetDB and MonetDBLite-R to the Databases section. Any suggestions or objections to that? If none, would you have any recommendations for connecting that are different from what in the README in the repo (https://github.com/hannesmuehleisen/MonetDBLite-R)?
^^ Should have been self evident :p
Add a table that lists supported data types for each data source. For example:
Supported Teradata Data Types
R type | Teradata type |
---|---|
factor | VARCHAR(255) |
time | VARCHAR(255) |
date | VARCHAR(255) |
binary | BLOB |
integer | INTEGER |
double | BINARY_DOUBLE |
character | VARCHAR(255) |
logical | DECIMAL |
list | VARCHAR(255) |
Unsupported types will throw an error. See r-dbi/odbc#238.
Add page to explain how to switch between databases using dbplyr
and DBI
/odbc
.
It should include how to use our functions and function arguments, such as in_schema()
and dbListTables(...schema_name="")
, and some DB specific commands like Oracle's SET SCHEMA
. Also, cross reference those DB specific commands to their respective page in the site.
The following links, which can be found on https://db.rstudio.com/best-practices/dashboards/#full-example, are broken:
Add the Environment Variables feature in RSC as an option in this page: http://db.rstudio.com/best-practices/portable-code/
Ref: https://blog.rstudio.com/2018/04/12/rstudio-connect-1-6-0-a-year-in-the-making/
dbplot
in the best practice visualization articledbplot
to the packages pageUsing https
instead of http
makes the site render incorrectly
Look into updating the ODBC drivers installation instructions for Linux: rstudio/rstudio#2463
This is something that comes up whenever I talk about databases, and it would be good to have "official" guidelines that we can direct people to. Since DBI and dplyr overlap a lot in their database functionality, users (especially newbies) are often at a loss on the topic of which one to choose.
In the olden times, when dplyr only supported SELECT-power statements, the rule was easy. Now, not so much. However, that may still be a good rule of thumb as non-SELECT statements in dplyr have not been time-tested yet.
Whatever the official recommendation is, we should have one, so that the answer to "Which package to use?" is not completely the opinion of whomever happens to be answering it.
cc @hadley
Update http://db.rstudio.com/databases/big-query/ with info from the updated README in bigrquery: r-dbi/bigrquery#202
I think you need a short section on managing credentials in between "run queries safely" and "deploying content". This would basically say that you should never store a password in your R script and never type it into the console.
For now, this section would discuss three options to avoid this:
rstudioapi::askForPassword()
Looks like there's a broken link on this page - https://db.rstudio.com/rstudio/connections/
Hi
I was looking to correct an error but it already has been corrected here cddf2dc
but it is not yet online.
https://db.rstudio.com/databases/postgresql/
html file has not been rebuilt and deployed
cheers
The content of this page: http://db.rstudio.com/advanced/snippets/ , needs to be sourced from here: https://rstudio.github.io/rstudio-extensions/rstudio-connections.html
See: r-dbi/RPostgres#201
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.