OmniSciDB
a5dc49c757
|
Functions | |
bool | bool_from_string_literal (const Parser::StringLiteral *str_literal) |
void | parse_copy_params (const std::list< std::unique_ptr< NameValueAssign >> &options_, import_export::CopyParams ©_params, std::vector< std::string > &warnings, std::string &deferred_copy_from_partitions_) |
bool | expr_is_null (const Analyzer::Expr *expr) |
std::string | unescape (std::string s) |
void | parse_options (const rapidjson::Value &payload, std::list< std::unique_ptr< NameValueAssign >> &nameValueList, bool stringToNull=false, bool stringToInteger=false) |
Literal * | parse_insert_literal (const rapidjson::Value &literal) |
ArrayLiteral * | parse_insert_array_literal (const rapidjson::Value &array) |
void | validate_shard_column_type (const ColumnDescriptor &cd) |
size_t | shard_column_index (const std::string &name, const std::list< ColumnDescriptor > &columns) |
size_t | sort_column_index (const std::string &name, const std::list< ColumnDescriptor > &columns) |
void | set_string_field (rapidjson::Value &obj, const std::string &field_name, const std::string &field_value, rapidjson::Document &document) |
std::string | serialize_key_metainfo (const ShardKeyDef *shard_key_def, const std::vector< SharedDictionaryDef > &shared_dict_defs) |
template<typename LITERAL_TYPE , typename ASSIGNMENT , typename VALIDATE = DefaultValidate<LITERAL_TYPE>> | |
decltype(auto) | get_property_value (const NameValueAssign *p, ASSIGNMENT op, VALIDATE validate=VALIDATE()) |
decltype(auto) | get_storage_type (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_frag_size_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_frag_size_dataframe_def (DataframeTableDescriptor &df_td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_max_chunk_size_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_max_chunk_size_dataframe_def (DataframeTableDescriptor &df_td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_delimiter_def (DataframeTableDescriptor &df_td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_header_def (DataframeTableDescriptor &df_td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_page_size_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_max_rows_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_skip_rows_def (DataframeTableDescriptor &df_td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_partions_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_shard_count_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_vacuum_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_sort_column_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
decltype(auto) | get_max_rollback_epochs_def (TableDescriptor &td, const NameValueAssign *p, const std::list< ColumnDescriptor > &columns) |
void | get_table_definitions (TableDescriptor &td, const std::unique_ptr< NameValueAssign > &p, const std::list< ColumnDescriptor > &columns) |
void | get_table_definitions_for_ctas (TableDescriptor &td, const std::unique_ptr< NameValueAssign > &p, const std::list< ColumnDescriptor > &columns) |
void | get_dataframe_definitions (DataframeTableDescriptor &df_td, const std::unique_ptr< NameValueAssign > &p, const std::list< ColumnDescriptor > &columns) |
void | parse_elements (const rapidjson::Value &payload, std::string element_name, std::string &table_name, std::list< std::unique_ptr< TableElement >> &table_element_list) |
shared::TableKey | get_table_key (const std::vector< std::string > &table) |
lockmgr::LockedTableDescriptors | acquire_query_table_locks (const std::string &insert_table_db_name, const std::string &query_str, const QueryStateProxy &query_state_proxy, const std::optional< std::string > &insert_table_name={}) |
bool | user_can_access_table (const Catalog_Namespace::SessionInfo &session_info, const TableDescriptor *td, const AccessPrivileges access_priv) |
std::string | generateUniqueTableName (std::string name) |
void | recordRename (SubstituteMap &sMap, std::string oldName, std::string newName) |
std::string | loadTable (Catalog_Namespace::Catalog &catalog, SubstituteMap &sMap, std::string tableName) |
bool | hasData (SubstituteMap &sMap, std::string tableName) |
void | checkNameSubstition (SubstituteMap &sMap) |
void | disable_foreign_tables (const TableDescriptor *td) |
std::optional< std::string > | get_string_option (const NameValueAssign *option, const std::string &option_name) |
Variables | |
static const std::map< const std::string, const TableDefFuncPtr > | tableDefFuncMap |
static const std::map< const std::string, const DataframeDefFuncPtr > | dataframeDefFuncMap |
static constexpr char const * | EMPTY_NAME {""} |
lockmgr::LockedTableDescriptors Parser::anonymous_namespace{ParserNode.cpp}::acquire_query_table_locks | ( | const std::string & | insert_table_db_name, |
const std::string & | query_str, | ||
const QueryStateProxy & | query_state_proxy, | ||
const std::optional< std::string > & | insert_table_name = {} |
||
) |
Definition at line 4614 of file ParserNode.cpp.
Referenced by Parser::InsertIntoTableAsSelectStmt::execute(), Parser::CreateTableAsSelectStmt::execute(), and Parser::ExportQueryStmt::execute().
bool Parser::anonymous_namespace{ParserNode.cpp}::bool_from_string_literal | ( | const Parser::StringLiteral * | str_literal | ) |
Definition at line 1080 of file ParserNode.cpp.
References Parser::StringLiteral::get_stringval().
Referenced by parse_copy_params(), and Parser::ExportQueryStmt::parseOptions().
void Parser::anonymous_namespace{ParserNode.cpp}::checkNameSubstition | ( | SubstituteMap & | sMap | ) |
Definition at line 5235 of file ParserNode.cpp.
References EMPTY_NAME.
Referenced by Parser::RenameTableStmt::execute().
void Parser::anonymous_namespace{ParserNode.cpp}::disable_foreign_tables | ( | const TableDescriptor * | td | ) |
Definition at line 5249 of file ParserNode.cpp.
References StorageType::FOREIGN_TABLE, TableDescriptor::storageType, and TableDescriptor::tableName.
Referenced by Parser::RenameTableStmt::execute().
bool Parser::anonymous_namespace{ParserNode.cpp}::expr_is_null | ( | const Analyzer::Expr * | expr | ) |
Definition at line 1650 of file ParserNode.cpp.
References Analyzer::Constant::get_is_null(), SQLTypeInfo::get_type(), Analyzer::Expr::get_type_info(), and kNULLT.
Referenced by Parser::CaseExpr::normalize().
std::string Parser::anonymous_namespace{ParserNode.cpp}::generateUniqueTableName | ( | std::string | name | ) |
Definition at line 5200 of file ParserNode.cpp.
References run_benchmark_import::result, and to_string().
Referenced by Parser::RenameTableStmt::execute().
void Parser::anonymous_namespace{ParserNode.cpp}::get_dataframe_definitions | ( | DataframeTableDescriptor & | df_td, |
const std::unique_ptr< NameValueAssign > & | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 3084 of file ParserNode.cpp.
Referenced by Parser::CreateDataframeStmt::execute().
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_delimiter_def | ( | DataframeTableDescriptor & | df_td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2918 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_frag_size_dataframe_def | ( | DataframeTableDescriptor & | df_td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2896 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_frag_size_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2888 of file ParserNode.cpp.
References to_string(), and Parser::validate_and_get_fragment_size().
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_header_def | ( | DataframeTableDescriptor & | df_td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2929 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_max_chunk_size_dataframe_def | ( | DataframeTableDescriptor & | df_td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2910 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_max_chunk_size_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2903 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_max_rollback_epochs_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 3023 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_max_rows_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2955 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_page_size_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2943 of file ParserNode.cpp.
References File_Namespace::FileBuffer::getMinPageSize(), and to_string().
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_partions_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2968 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_property_value | ( | const NameValueAssign * | p, |
ASSIGNMENT | op, | ||
VALIDATE | validate = VALIDATE() |
||
) |
Definition at line 2873 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_shard_count_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_skip_rows_def | ( | DataframeTableDescriptor & | df_td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2961 of file ParserNode.cpp.
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_sort_column_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 3012 of file ParserNode.cpp.
References sort_column_index().
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_storage_type | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2880 of file ParserNode.cpp.
std::optional<std::string> Parser::anonymous_namespace{ParserNode.cpp}::get_string_option | ( | const NameValueAssign * | option, |
const std::string & | option_name | ||
) |
Definition at line 7086 of file ParserNode.cpp.
References CHECK, Parser::NameValueAssign::get_name(), and Parser::NameValueAssign::get_value().
Referenced by Parser::DumpRestoreTableStmtBase::DumpRestoreTableStmtBase().
void Parser::anonymous_namespace{ParserNode.cpp}::get_table_definitions | ( | TableDescriptor & | td, |
const std::unique_ptr< NameValueAssign > & | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 3048 of file ParserNode.cpp.
Referenced by Parser::CreateTableStmt::executeDryRun().
void Parser::anonymous_namespace{ParserNode.cpp}::get_table_definitions_for_ctas | ( | TableDescriptor & | td, |
const std::unique_ptr< NameValueAssign > & | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 3062 of file ParserNode.cpp.
Referenced by Parser::CreateTableAsSelectStmt::execute().
shared::TableKey Parser::anonymous_namespace{ParserNode.cpp}::get_table_key | ( | const std::vector< std::string > & | table | ) |
Definition at line 4603 of file ParserNode.cpp.
References CHECK, and lockmgr::instance().
decltype(auto) Parser::anonymous_namespace{ParserNode.cpp}::get_vacuum_def | ( | TableDescriptor & | td, |
const NameValueAssign * | p, | ||
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 3001 of file ParserNode.cpp.
bool Parser::anonymous_namespace{ParserNode.cpp}::hasData | ( | SubstituteMap & | sMap, |
std::string | tableName | ||
) |
Definition at line 5230 of file ParserNode.cpp.
References EMPTY_NAME.
Referenced by Parser::RenameTableStmt::execute().
std::string Parser::anonymous_namespace{ParserNode.cpp}::loadTable | ( | Catalog_Namespace::Catalog & | catalog, |
SubstituteMap & | sMap, | ||
std::string | tableName | ||
) |
Definition at line 5210 of file ParserNode.cpp.
References EMPTY_NAME, and Catalog_Namespace::Catalog::getMetadataForTable().
Referenced by Parser::RenameTableStmt::execute().
void Parser::anonymous_namespace{ParserNode.cpp}::parse_copy_params | ( | const std::list< std::unique_ptr< NameValueAssign >> & | options_, |
import_export::CopyParams & | copy_params, | ||
std::vector< std::string > & | warnings, | ||
std::string & | deferred_copy_from_partitions_ | ||
) |
Definition at line 1091 of file ParserNode.cpp.
References import_export::CopyParams::add_metadata_columns, import_export::CopyParams::array_begin, import_export::CopyParams::array_delim, import_export::CopyParams::array_end, bool_from_string_literal(), import_export::CopyParams::buffer_size, CHECK, import_export::CopyParams::connection_string, import_export::CopyParams::credential_string, import_export::CopyParams::delimiter, import_export::CopyParams::dsn, import_export::CopyParams::escape, import_export::CopyParams::file_sort_order_by, import_export::CopyParams::file_sort_regex, g_enable_add_metadata_columns, import_export::CopyParams::geo_coords_comp_param, import_export::CopyParams::geo_coords_encoding, import_export::CopyParams::geo_coords_srid, import_export::CopyParams::geo_coords_type, import_export::CopyParams::geo_explode_collections, import_export::CopyParams::geo_layer_name, import_export::CopyParams::geo_validate_geometry, Geospatial::geos_validation_available(), Parser::IntLiteral::get_intval(), Parser::StringLiteral::get_stringval(), import_export::CopyParams::has_header, import_export::kAuto, import_export::kDelimitedFile, import_export::kDouble, kENCODING_GEOINT, kENCODING_NONE, import_export::kFile, import_export::kFloat, import_export::kGeoFile, kGEOMETRY, import_export::kHasHeader, import_export::kInt, import_export::kNoHeader, import_export::kNone, import_export::kParquetFile, import_export::kPoint, import_export::kRasterFile, import_export::kRegexParsedFile, import_export::kSmallInt, import_export::kWorld, import_export::CopyParams::line_delim, import_export::CopyParams::line_regex, import_export::CopyParams::line_start_regex, import_export::CopyParams::lonlat, import_export::CopyParams::max_import_batch_row_count, import_export::CopyParams::max_reject, import_export::CopyParams::null_str, import_export::CopyParams::password, import_export::CopyParams::plain_text, import_export::CopyParams::quote, import_export::CopyParams::quoted, import_export::CopyParams::raster_drop_if_all_null, import_export::CopyParams::raster_import_bands, import_export::CopyParams::raster_import_dimensions, import_export::CopyParams::raster_point_compute_angle, import_export::CopyParams::raster_point_transform, import_export::CopyParams::raster_point_type, import_export::CopyParams::raster_scanlines_per_thread, import_export::CopyParams::regex_path_filter, import_export::CopyParams::s3_access_key, import_export::CopyParams::s3_endpoint, import_export::CopyParams::s3_max_concurrent_downloads, import_export::CopyParams::s3_region, import_export::CopyParams::s3_secret_key, import_export::CopyParams::s3_session_token, import_export::CopyParams::source_srid, import_export::CopyParams::source_type, import_export::CopyParams::sql_order_by, import_export::CopyParams::threads, to_string(), import_export::CopyParams::trim_spaces, and import_export::CopyParams::username.
Referenced by Parser::CopyTableStmt::execute().
void Parser::anonymous_namespace{ParserNode.cpp}::parse_elements | ( | const rapidjson::Value & | payload, |
std::string | element_name, | ||
std::string & | table_name, | ||
std::list< std::unique_ptr< TableElement >> & | table_element_list | ||
) |
Definition at line 3097 of file ParserNode.cpp.
References CHECK, Parser::column_from_json(), logger::FATAL, json_str(), and LOG.
Referenced by Parser::CreateDataframeStmt::CreateDataframeStmt(), and Parser::CreateTableStmt::CreateTableStmt().
ArrayLiteral* Parser::anonymous_namespace{ParserNode.cpp}::parse_insert_array_literal | ( | const rapidjson::Value & | array | ) |
Definition at line 2444 of file ParserNode.cpp.
References CHECK, and parse_insert_literal().
Referenced by Parser::InsertValuesStmt::InsertValuesStmt().
Literal* Parser::anonymous_namespace{ParserNode.cpp}::parse_insert_literal | ( | const rapidjson::Value & | literal | ) |
Definition at line 2410 of file ParserNode.cpp.
References CHECK, json_i64(), json_str(), sql_constants::kMaxNumericPrecision, and run_benchmark_import::type.
Referenced by Parser::InsertValuesStmt::InsertValuesStmt(), and parse_insert_array_literal().
void Parser::anonymous_namespace{ParserNode.cpp}::parse_options | ( | const rapidjson::Value & | payload, |
std::list< std::unique_ptr< NameValueAssign >> & | nameValueList, | ||
bool | stringToNull = false , |
||
bool | stringToInteger = false |
||
) |
Definition at line 2029 of file ParserNode.cpp.
References CHECK, json_double(), json_i64(), and unescape().
Referenced by Parser::AlterUserStmt::AlterUserStmt(), Parser::CopyTableStmt::CopyTableStmt(), Parser::CreateDataframeStmt::CreateDataframeStmt(), Parser::CreateDBStmt::CreateDBStmt(), Parser::CreateModelStmt::CreateModelStmt(), Parser::CreateTableAsSelectStmt::CreateTableAsSelectStmt(), Parser::CreateTableStmt::CreateTableStmt(), Parser::CreateUserStmt::CreateUserStmt(), Parser::DumpRestoreTableStmtBase::DumpRestoreTableStmtBase(), Parser::ExportQueryStmt::ExportQueryStmt(), Parser::OptimizeTableStmt::OptimizeTableStmt(), and Parser::ValidateStmt::ValidateStmt().
void Parser::anonymous_namespace{ParserNode.cpp}::recordRename | ( | SubstituteMap & | sMap, |
std::string | oldName, | ||
std::string | newName | ||
) |
Definition at line 5206 of file ParserNode.cpp.
Referenced by Parser::RenameTableStmt::execute().
std::string Parser::anonymous_namespace{ParserNode.cpp}::serialize_key_metainfo | ( | const ShardKeyDef * | shard_key_def, |
const std::vector< SharedDictionaryDef > & | shared_dict_defs | ||
) |
Definition at line 2840 of file ParserNode.cpp.
References Parser::ShardKeyDef::get_column(), and set_string_field().
Referenced by Parser::CreateDataframeStmt::execute(), Parser::CreateTableAsSelectStmt::execute(), and Parser::CreateTableStmt::executeDryRun().
void Parser::anonymous_namespace{ParserNode.cpp}::set_string_field | ( | rapidjson::Value & | obj, |
const std::string & | field_name, | ||
const std::string & | field_value, | ||
rapidjson::Document & | document | ||
) |
Definition at line 2827 of file ParserNode.cpp.
Referenced by serialize_key_metainfo().
size_t Parser::anonymous_namespace{ParserNode.cpp}::shard_column_index | ( | const std::string & | name, |
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2794 of file ParserNode.cpp.
References validate_shard_column_type().
Referenced by Parser::CreateTableStmt::executeDryRun().
size_t Parser::anonymous_namespace{ParserNode.cpp}::sort_column_index | ( | const std::string & | name, |
const std::list< ColumnDescriptor > & | columns | ||
) |
Definition at line 2811 of file ParserNode.cpp.
Referenced by get_sort_column_def().
std::string Parser::anonymous_namespace{ParserNode.cpp}::unescape | ( | std::string | s | ) |
Definition at line 1997 of file ParserNode.cpp.
Referenced by heavydb._samlutils::get_saml_response(), and parse_options().
bool Parser::anonymous_namespace{ParserNode.cpp}::user_can_access_table | ( | const Catalog_Namespace::SessionInfo & | session_info, |
const TableDescriptor * | td, | ||
const AccessPrivileges | access_priv | ||
) |
Definition at line 5005 of file ParserNode.cpp.
References cat(), CHECK, Catalog_Namespace::SessionInfo::get_currentUser(), Catalog_Namespace::SessionInfo::getCatalog(), lockmgr::instance(), DBObject::loadKey(), DBObject::setPrivileges(), TableDBObjectType, and TableDescriptor::tableName.
Referenced by Parser::OptimizeTableStmt::execute().
void Parser::anonymous_namespace{ParserNode.cpp}::validate_shard_column_type | ( | const ColumnDescriptor & | cd | ) |
Definition at line 2785 of file ParserNode.cpp.
References ColumnDescriptor::columnType, and kENCODING_DICT.
Referenced by shard_column_index().
|
static |
Definition at line 3077 of file ParserNode.cpp.
|
static |
Definition at line 5198 of file ParserNode.cpp.
Referenced by checkNameSubstition(), Parser::RenameTableStmt::execute(), hasData(), and loadTable().
|
static |
Definition at line 3036 of file ParserNode.cpp.