MINI MINI MANI MO

Path : /opt/oracle/product/18c/dbhomeXE/R/library/OREbase/doc/man/en/
File Upload :
Current File : //opt/oracle/product/18c/dbhomeXE/R/library/OREbase/doc/man/en/ore.sync.Rd

%
% Copyright (c) 2012, 2014, Oracle and/or its affiliates. All rights reserved. 
%
\name{ore.sync}
\alias{ore.sync}
\title{Oracle R Enterprise Object Synchronization Function}
\description{
  Synchronize \code{\linkS4class{ore.frame}} objects the represent
  database tables, views, and queries within the \R
  \code{\link[base]{environment}} for a schema in the Oracle R
  Enterprise session.
}
\usage{
ore.sync(schema, table = NULL, use.keys = TRUE, query = NULL)
}
\arguments{
  \item{schema}{
    A character string specifying the database schema name. Not
    supported with use of argument \code{query}.
  }
  \item{table}{
    An optional character vector specifying the database table or view
    names to use for \code{\linkS4class{ore.frame}} object creation.
  }
  \item{use.keys}{
    A logical value specifying whether primary keys, if they exist,
    should be used for constructing ordered
    \code{\linkS4class{ore.frame}} objects.
  }
  \item{query}{
    An optional named character vector specifying queries to use for
    \code{\linkS4class{ore.frame}} object creation. The element names
    are used as the names of the \code{\linkS4class{ore.frame}} objects
    in the \R \code{\link[base]{environment}} for the default schema.
  }
}
\details{
  Oracle R Enterprise creates proxy objects in \R that correspond to the
  tables or views in the database schema. These proxy objects contain
  metadata used by Oracle R Enterprise internally to provide
  transparency layer functionality.

  By default, function \code{ore.sync} uses the schema given at the time
  of \code{\link{ore.connect}}. The \code{schema} argument can be used
  to select a different schema for which the user has the appropriate
  access privileges.

  When both the \code{table} and \code{query} arguments are \code{NULL}
  in an \code{ore.sync} function call, all tables and views whose name
  do not contain a \code{$} or begin with \code{SYS_} are
  selected. Selecting all of the tables in a database schema can be
  expensive and so the recommended practice is to set either the
  \code{table} or \code{query} argument to limit the the number of
  tables and views represented in the Oracle R Enterprise schema
  environment.

  If argument \code{use.keys} is set to \code{FALSE} or if the table has
  no primary key, the corresponding \code{\linkS4class{ore.frame}}
  object will be unordered; otherwise it will be ordered. For many
  operations on \code{\linkS4class{ore.frame}} objects, for example
  \code{colMeans}, the row order is not important. However for
  operations that require a row ordering, for example \code{diff}, an
  error message is issued specifying that the ordering information is
  not available. A row ordering can be imposed on an
  \code{\linkS4class{ore.frame}} object by setting its row names to one
  or more of its columns.
}
\references{
  \href{http://www.oracle.com/technetwork/database/database-technologies/r/r-enterprise/documentation/index.html}{Oracle R Enterprise}
}
\author{
  Oracle \email{oracle-r-enterprise@oracle.com}
}
\seealso{
  \code{\link{ore.attach}},
  \code{\link{ore.connect}},
  \code{\link{ore.exists}},
  \code{\link{ore.get}},
  \code{\link{ore.ls}},
  \code{\link{ore.rm}},
  \code{\link{row.names<-}}
}
\examples{
if (!interactive())
{
  ore.sync()
  ore.sync("RQUSER", use.keys = FALSE)
  ore.exec("create table TABLE1 as select * from dual")
  ore.exec("create table TABLE2 as select * from dual")
  ore.sync(table = c("TABLE1", "TABLE2"))
  ore.sync("RQUSER", table = c("TABLE1", "TABLE2"))
  ore.sync(query = c("QUERY1" = "select 0 X, 1 Y from dual",
                     "QUERY2" = "select 1 X, 0 Y from dual"))
  ore.drop("TABLE1")
  ore.drop("TABLE2")
}
}
\keyword{environment}
\keyword{database}
\keyword{ORE}

OHA YOOOO