mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-24 10:40:49 +00:00
896 B
896 B
toc_priority | toc_title |
---|---|
43 | Files |
Functions for Working with Files
file(path)
Reads file as a String. The file can contain subqueries, condition, names of columns and any other information that will be read as one line.
Syntax
file(path)
Arguments
path
— The relative path to the file fromuser_files_path
. Path to file support following globs in read-only mode:*
,?
,{abc,def}
and{N..M}
whereN
,M
— numbers,'abc', 'def'
— strings.
Example
Inserting data from files a.txt and b.txt into a table as different rows.
Query:
INSERT INTO table SELECT file('a.txt'), file('b.txt')
See Also