2018-10-28
閱讀量:
949
R連接Redshift數(shù)據(jù)庫
1,首先加載Redhsift的包。 如果不能直接安裝就需要先下載Redshift的包到本地,然后通過本地路徑安裝。
2,使用語法
conn=redshift('jdbc:postgresql://URL','Account','Password')
str_query="select * from table limit 100"
data_test=dbGetQuery(conn,str_query)
當(dāng)然更新一個更簡單的安裝方式:
install.packages("devtools")
devtools::install_github("pingles/redshift-r")
兩行代碼解決。






評論(0)


暫無數(shù)據(jù)
推薦帖子
0條評論
0條評論
0條評論