CREATE FILE
This statement is used to create and upload a file to the Doris cluster. This function is usually used to manage files that need to be used in some other commands, such as certificates, public and private keys, and so on.
This command can only be executed by users with admin privileges. A certain file belongs to a certain database. This file can be used by any user with access rights to database.
A single file size is limited to 1MB. A Doris cluster can upload up to 100 files.
grammar:
CREATE FILE "file_name" [IN database] PROPERTIES("key"="value", ...)
illustrate:
Create a file ca.pem , classified as kafka
CREATE FILE "ca.pem" PROPERTIES ( "url" = "https://test.bj.bcebos.com/kafka-key/ca.pem", "catalog" = "kafka" );
Create a file client.key, classified as my_catalog
CREATE FILE "client.key" IN my_database PROPERTIES ( "url" = "https://test.bj.bcebos.com/kafka-key/client.key", "catalog" = "my_catalog", "md5" = "b5bb901bf10f99205b39a46ac3557dd9" );
CREATE, FILE
This command can only be executed by users with amdin privileges. A certain file belongs to a certain database. This file can be used by any user with access rights to database.
File size and quantity restrictions.
This function is mainly used to manage some small files such as certificates. So a single file size is limited to 1MB. A Doris cluster can upload up to 100 files.