Functions for Working with Files
file
Reads file as a String. The file content is not parsed, so any information is read as one string and placed into the specified column.
Syntax
file(path)
Arguments
path
— The relative path to the file from user_files_path. Path to file support following wildcards:*
,?
,{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 strings:
Query:
INSERT INTO table SELECT file('a.txt'), file('b.txt');
See Also
当前内容版权归 ClickHouse 或其关联方所有,如需对内容或内容相关联开源项目进行关注与资助,请访问 ClickHouse .