Skip to content

Commit f103766

Browse files
soyeric128Chasen-Zhang
authored andcommitted
Update index.md
1 parent 72005f0 commit f103766

File tree

1 file changed

+18
-2
lines changed
  • docs/en/guides/40-load-data/04-transform

1 file changed

+18
-2
lines changed

docs/en/guides/40-load-data/04-transform/index.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,11 +72,27 @@ The FILES option, on the other hand, enables you to explicitly specify one or mo
7272

7373
### CASE_SENSITIVE
7474

75-
The CASE_SENSITIVE parameter determines whether column names in the queried *Parquet* files are treated with case sensitivity:
75+
The CASE_SENSITIVE parameter determines whether column names in the queried Parquet files are treated with case sensitivity:
7676

77-
- `CASE_SENSITIVE => false` (default): Column names are treated as case-insensitive, meaning `b` and `B` are considered the same. However, queries will fail if the column name in the file does not match the queried column name exactly.
77+
- `CASE_SENSITIVE => false` (default): Column names are treated as case-insensitive, meaning `b` and `B` are considered the same.
7878
- `CASE_SENSITIVE => true`: Column names are treated as case-sensitive, meaning only exact matches (including case) are valid. For example, querying `B` will succeed if the column in the file is named `B`, but not if it is named `b`.
7979

80+
For example, if you have a column named `MinTemp` in a Parquet file, you can query it using one of the following statements when `CASE_SENSITIVE` is set to `false`:
81+
82+
```sql
83+
SELECT MinTemp FROM '@mystage/weather.parquet'(CASE_SENSITIVE=>false);
84+
85+
SELECT MINTEMP FROM '@mystage/weather.parquet'(CASE_SENSITIVE=>false);
86+
87+
SELECT mintemp FROM '@mystage/weather.parquet'(CASE_SENSITIVE=>false);
88+
```
89+
90+
When `CASE_SENSITIVE` is set to `true`, you must use the exact column name as it appears in the file, as shown below:
91+
92+
```sql
93+
SELECT `MinTemp` FROM '@mystage/weather.parquet'(CASE_SENSITIVE=>true);
94+
```
95+
8096
### table_alias
8197

8298
When working with staged files in a SELECT statement where no table name is available, you can assign an alias to the files. This allows you to treat the files as a table, with its fields serving as columns within the table. This is useful when working with multiple tables within the SELECT statement or when selecting specific columns. Here's an example:

0 commit comments

Comments
 (0)