% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/ddc.R
\name{orc2dframe}
\alias{orc2dframe}
\title{Load an ORC file into a distributed data frame}
\usage{
orc2dframe(url, selectedStripes = "",
  hdfsConfigurationFile = paste(system.file(package = "hdfsconnector"),
  "/conf/hdfs.json", sep = ""))
}
\arguments{
\item{url}{File URL. Examples: '/tmp/file.orc', 'hdfs:///file.orc'.}

\item{selectedStripes}{ORC stripes to include. Stripes need to be consecutive. If not specified defaults to all the stripes in the ORC file.}

\item{hdfsConfigurationFile}{By default: \code{paste(system.file(package='hdfsconnector'),'/conf/hdfs.json',sep='')}.

                             Options are:
                             \itemize{
                                 \item webhdfsPort: webhdfs port, integer
                                 \item hdfsPort: hdfs namenode port, integer
                                 \item hdfsHost: hdfs namenode host, string
                                 \item hdfsUser: hdfs username, string
                             }

                             An example file is:

                                 \{ \cr
                                 "webhdfsPort": 50070, \cr
                                 "hdfsPort": 9000, \cr
                                 "hdfsHost": "172.17.0.3", \cr
                                 "hdfsUser": "jorgem" \cr
                                 \}}
}
\value{
A distributed data frame representing the ORC file.
}
\description{
Load an ORC file into a distributed data frame
}
\section{Partitioning between executors}{


We generate as many partitions as the total number of ORC stripes.

E.g. let’s say the customer tries to load /tmp/*.orc which expands to /tmp/file1.orc with 2 stripes and /tmp/file2.orc with 3 stripes. We’ll end up with 2 + 3 = 5 partitions.

If globbing is not used we only load one file and the number of partitions will be equal to the number of stripes.
}

\section{Details}{


Type conversions work as follows:
               \tabular{ll}{
                   ORC type          |\tab R type        \cr
                   -                 |\tab -             \cr
                   byte/short/int    |\tab integer       \cr
                   float/double      |\tab numeric       \cr
                   long              |\tab numeric       \cr
                   bool              |\tab logical       \cr
                   string/binary     |\tab character     \cr
                   char/varchar      |\tab character     \cr
                   decimal           |\tab character     \cr
                   timestamp/date    |\tab character     \cr
                   union             |\tab not supported \cr
                   struct            |\tab dataframe     \cr
                   map               |\tab dataframe     \cr
                   list              |\tab list
               }
}
\examples{
df <- orc2dframe(url=paste(system.file(package='HPdata'),'/tests/data/TestOrcFile.test1.orc',sep=''))
}

