filterByString
Calculates which objects from a table or view match a string expression for the given string columns. SettingCASE_SENSITIVEcan modify case sensitivity in matching for all modes exceptSEARCH. ForSEARCHmode details and limitations, see Full Text Search.Parameters:request-Requestobject containing the parameters for the operation.Returns:Responseobject containing the results of the operation.Throws:GPUdbException- if an error occurs during the operation.filterByString
public FilterByStringResponse filterByString(String tableName, String viewName, String expression, String mode, List<String> columnNames, Map<String, String> options) throws GPUdbException Calculates which objects from a table or view match a string expression for the given string columns. SettingCASE_SENSITIVEcan modify case sensitivity in matching for all modes exceptSEARCH. ForSEARCHmode details and limitations, see Full Text Search.Parameters:tableName- Name of the table on which the filter operation will be performed, in [schema_name.]table_name format, using standard name resolution rules. Must be an existing table or view.viewName- If provided, then this will be the name of the view containing the results, in [schema_name.]view_name format, using standard name resolution rules and meeting table naming criteria. Must not be an already existing table or view. The default value is ”.expression- The expression with which to filter the table.mode- The string filtering mode to apply. See below for details. Supported values:SEARCH: Full text search query with wildcards and boolean operators. Note that for this mode, no column can be specified incolumnNames; all string columns of the table that have text search enabled will be searched.EQUALS: Exact whole-string match (accelerated).CONTAINS: Partial substring match (not accelerated). If the column is a string type (non-charN) and the number of records is too large, it will return 0.STARTS_WITH: Strings that start with the given expression (not accelerated). If the column is a string type (non-charN) and the number of records is too large, it will return 0.REGEX: Full regular expression search (not accelerated). If the column is a string type (non-charN) and the number of records is too large, it will return 0.SEARCH_STATS: Cross-shard BM25 corpus statistics for one (column, query) pair. Returns the merged BM25 statistics (max_doc, doc_count, sum_total_term_freq, per-term doc_freq / total_term_freq) needed by callers that score documents themselves (e.g. text_match_bm25_global SQL function pre-pass). RequiresCOLUMN_NAMESto contain exactly one column with text search enabled. TheVIEW_NAMEfield is ignored — this mode does not produce a result table.
columnNames- List of columns on which to apply the filter. Ignored forSEARCHmode.options- Optional parameters.CREATE_TEMP_TABLE: IfTRUE, a unique temporary table name will be generated in the sys_temp schema and used in place ofviewName. This is always allowed even if the caller does not have permission to create tables. The generated name is returned inQUALIFIED_VIEW_NAME. Supported values:The default value isFALSE.COLLECTION_NAME: [DEPRECATED—please specify the containing schema for the view as part ofviewNameand usecreateSchemato create the schema if non-existent] Name of a schema for the newly created view. If the schema is non-existent, it will be automatically created.CASE_SENSITIVE: IfFALSEthen string filtering will ignore case. Does not apply toSEARCHmode. Supported values:The default value isTRUE.
Map.Returns:Responseobject containing the results of the operation.Throws:GPUdbException- if an error occurs during the operation.