---
title: orc (DataFrameReader)
description: "DataFrameReader.orc method in PySpark: Loads ORC files and returns the result as a DataFrame."
canonical_url: https://docs.databricks.com/gcp/en/pyspark/reference/classes/dataframereader/orc
---

# orc (DataFrameReader)

Loads ORC files and returns the result as a `DataFrame`.

## Syntax

```
orc(path, **options)
```

## Parameters

| Parameter | Type        | Description              |
| --------- | ----------- | ------------------------ |
| `path`    | str or list | One or more input paths. |

## Returns

`DataFrame`

## Examples

Write a DataFrame into an ORC file and read it back.

```python
import tempfile
with tempfile.TemporaryDirectory(prefix="orc") as d:
    spark.createDataFrame(
        [{"age": 100, "name": "Alice"}]
    ).write.mode("overwrite").format("orc").save(d)

    spark.read.orc(d).show()
    # +---+------------+
    # |age|        name|
    # +---+------------+
    # |100|Alice|
    # +---+------------+
```
