I have some tables in a odbc conection to which I have access with this code:
con <- dbConnect(odbc::odbc(), uid = usid, pwd = pwd, dsn = "Oracle-dw02-32")
When I use the STR command
str(TF_MDE_DATA_10)
I get this error
Error in str(TF_MDE_DATA_10) : object 'TF_MDE_DATA_10' not found
Is there any similar command to STR to tables in conections?
Thank you.
How is TF_MDE_DATA_10
related to the con
object?
Is
str(TF_MDE_DATA_10)
an R statement ?
@HanOostdijk
It is but TF_MDE_DATA_10 wasn´t a R dataframe.
I solved the problem his way:
# Listar as tabelas acessíveis na ligação
dbListTables(con)
# Fazer uma "preview" dos dados numa tabela.
TF_MDE_DATA_10 <- odbcPreviewObject(con, rowLimit = 0, table = "BDIMDE.TF_MDE_DATA_10")
DR_TF_MDE_DATA_10 <- as.data.frame(colnames(TF_MDE_DATA_10))
system
Closed
April 12, 2023, 2:16pm
4
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed. If you have a query related to it or one of the replies, start a new topic and refer back with a link.