SAPHANA学习(26):SQL Function 分类汇总
Posted tangtoms
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了SAPHANA学习(26):SQL Function 分类汇总相关的知识,希望对你有一定的参考价值。
3.12 Aggregate Functions
/*12. Aggregate Functions*/
/*
Aggregate functions are analytic functions that calculate an aggregate value based on a group of rows.
AUTO_CORR Function (Aggregate)
AVG Function (Aggregate)
CORR Function (Aggregate)
CORR_SPEARMAN Function (Aggregate)
COUNT Function (Aggregate)
CROSS_CORR Function (Aggregate)
DFT Function (Aggregate)
FIRST_VALUE Function (Aggregate)
LAST_VALUE Function (Aggregate)
MAX Function (Aggregate)
MEDIAN Function (Aggregate)
MIN Function (Aggregate)
NTH_VALUE Function (Aggregate)
STDDEV Function (Aggregate)
STDDEV_POP Function (Aggregate)
STDDEV_SAMP Function (Aggregate)
STRING_AGG Function (Aggregate)
SUM Function (Aggregate)
VAR Function (Aggregate)
VAR_POP Function (Aggregate)
VAR_SAMP Function (Aggregate)
*/
3.13 Array Functions
/*13.Array Functions*/
/*
CARDINALITY Function (Array)
MEMBER_AT Function (Array)
SUBARRAY Function (Array)
TRIM_ARRAY Function (Array)
*/
3.14 Data Type Conversion Functions
/*14.Data Type Conversion Functions*/
/*
CAST Function (Data Type Conversion)
TO_ALPHANUM Function (Data Type Conversion)
TO_BIGINT Function (Data Type Conversion)
TO_BINARY Function (Data Type Conversion)
TO_BLOB Function (Data Type Conversion)
TO_BOOLEAN Function (Data Type Conversion)
TO_CLOB Function (Data Type Conversion)
TO_DATE Function (Data Type Conversion)
TO_DATS Function (Data Type Conversion)
TO_DECIMAL Function (Data Type Conversion)
TO_DOUBLE Function (Data Type Conversion)
TO_FIXEDCHAR Function (Data Type Conversion)
TO_INT Function (Data Type Conversion)
TO_INTEGER Function (Data Type Conversion)
TO_JSON_BOOLEAN (Data Type Conversion)
TO_NCLOB Function (Data Type Conversion)
TO_NVARCHAR Function (Data Type Conversion)
TO_REAL Function (Data Type Conversion)
TO_SECONDDATE Function (Data Type Conversion)
TO_SMALLDECIMAL Function (Data Type Conversion)
TO_SMALLINT Function (Data Type Conversion)
TO_TIME Function (Data Type Conversion)
TO_TIMESTAMP Function (Data Type Conversion)
TO_TINYINT Function (Data Type Conversion)
TO_VARCHAR Function (Data Type Conversion)
*/
3.15 Datetime Functions
/*15.Datetime Functions*/
/*
ADD_DAYS Function (Datetime)
ADD_MONTHS Function (Datetime)
ADD_MONTHS_LAST Function (Datetime)
ADD_NANO100 Function (Datetime)
ADD_SECONDS Function (Datetime)
ADD_WORKDAYS Function (Datetime)
ADD_YEARS Function (Datetime)
CURRENT_DATE Function (Datetime)
CURRENT_MVCC_SNAPSHOT_TIMESTAMP Function (Datetime)
CURRENT_TIME Function (Datetime)
CURRENT_TIMESTAMP Function (Datetime)
CURRENT_UTCDATE Function (Datetime)
CURRENT_UTCTIME Function (Datetime)
CURRENT_UTCTIMESTAMP Function (Datetime)
DAYNAME Function (Datetime)
DAYOFMONTH Function (Datetime)
DAYOFYEAR Function (Datetime)
DAYS_BETWEEN Function (Datetime)
EXTRACT Function (Datetime)
HOUR Function (Datetime)
ISOWEEK Function (Datetime)
LAST_DAY Function (Datetime)
LOCALTOUTC Function (Datetime)
MINUTE Function (Datetime)
MONTH Function (Datetime)
MONTHNAME Function (Datetime)
MONTHS_BETWEEN Function (Datetime)
NANO100_BETWEEN Function (Datetime)
NEXT_DAY Function (Datetime)
NOW Function (Datetime)
QUARTER Function (Datetime)
SECOND Function (Datetime)
SECONDS_BETWEEN Function (Datetime)
UTCTOLOCAL Function (Datetime)
WEEK Function (Datetime)
WEEKDAY Function (Datetime)
WORKDAYS_BETWEEN Function (Datetime)
YEAR Function (Datetime)
YEARS_BETWEEN Function (Datetime)
*/
3.16 Fulltext Functions
/*16.Fulltext Functions*/
/*
INDEXING_ERROR_CODE Function (Fulltext)
INDEXING_ERROR_MESSAGE Function (Fulltext)
INDEXING_STATUS Function (Fulltext)
LANGUAGE Function (Fulltext)
MIMETYPE Function (Fulltext)
PLAINTEXT Function (Fulltext)
SCORE Function (Fulltext)
*/
3.17 Hierarchy Functions
/*17.Hierarchy Functions*/
/*
Generator functions
HIERARCHY Generator Function
HIERARCHY_LEVELED Generator Function
HIERARCHY_SPANTREE Generator Function
HIERARCHY_TEMPORAL Generator Function
Navigation functions
HIERARCHY_ANCESTORS Navigation Function
HIERARCHY_ANCESTORS_AGGREGATE Navigation Function
HIERARCHY_DESCENDANTS Navigation Function
HIERARCHY_DESCENDANTS_AGGREGATE Navigation Function
HIERARCHY_SIBLINGS Navigation Function
Scalar functions
HIERARCHY_COMPOSITE_ID Scalar Function
*/
3.18 JSON Functions
/*18.JSON Functions*/
/*
JSON_QUERY Function (JSON)
JSON_TABLE Function (JSON)
JSON_VALUE Function (JSON)
*/
3.19 Miscellaneous Functions
/*19. Miscellaneous Functions*/
/*
ALLOW_PRECISION_LOSS Function (Miscellaneous)
COALESCE Function (Miscellaneous)
CONVERT_CURRENCY Function (Miscellaneous)
CONVERT_UNIT Function (Miscellaneous)
CURRENT_CONNECTION Function (Miscellaneous)
CURRENT_IDENTITY_VALUE Function (Miscellaneous)
CURRENT_OBJECT_SCHEMA Function (Miscellaneous)
CURRENT_SCHEMA Function (Miscellaneous)
CURRENT_SITE_ID Function (Miscellaneous)
CURRENT_TRANSACTION_ISOLATION_LEVEL Function (Miscellaneous)
CURRENT_UPDATE_STATEMENT_SEQUENCE Function (Miscellaneous)
CURRENT_UPDATE_TRANSACTION Function (Miscellaneous)
CURRENT_USER Function (Miscellaneous)
CURRENT_USER_ID Function (Miscellaneous)
EXPRESSION_MACRO Function (Miscellaneous)
GREATEST Function (Miscellaneous)
GROUPING Function (Miscellaneous)
GROUPING_ID Function (Miscellaneous)
HASH_MD5 Function (Miscellaneous)
HASH_SHA256 Function (Miscellaneous)
IFNULL Function (Miscellaneous)
LEAST Function (Miscellaneous)
MAP Function (Miscellaneous)
NEWUID Function (Miscellaneous)
NULLIF Function (Miscellaneous)
RECORD_COMMIT_TIMESTAMP Function (Miscellaneous)
RECORD_ID Function (Miscellaneous)
RESULT_CACHE_ID Function (Miscellaneous)
RESULT_CACHE_REFRESH_TIME Function (Miscellaneous)
SESSION_CONTEXT Function (Miscellaneous)
SESSION_USER Function (Miscellaneous)
SYSUUID Function (Miscellaneous)
WIDTH_BUCKET Function (Miscellaneous)
XMLEXTRACT Function (Miscellaneous)
XMLEXTRACTVALUE Function (Miscellaneous)
*/
3.20 Numeric Functions
/*20.Numeric Functions*/
/*
ABS Function (Numeric)
ACOS Function (Numeric)
ASIN Function (Numeric)
ATAN Function (Numeric)
ATAN2 Function (Numeric)
BITAND Function (Numeric)
BITCOUNT Function (Numeric)
BITNOT Function (Numeric)
BITOR Function (Numeric)
BITSET Function (Numeric)
BITUNSET Function (Numeric)
BITXOR Function (Numeric)
CEIL Function (Numeric)
COS Function (Numeric)
COSH Function (Numeric)
COT Function (Numeric)
EXP Function (Numeric)
FLOOR Function (Numeric)
LN Function (Numeric)
LOG Function (Numeric)
MOD Function (Numeric)
NDIV0 Function (Numeric)
POWER Function (Numeric)
RAND Function (Numeric)
RAND_SECURE Function (Numeric)
ROUND Function (Numeric)
SIGN Function (Numeric)
SIN Function (Numeric)
SINH Function (Numeric)
SQRT Function (Numeric)
TAN Function (Numeric)
TANH Function (Numeric)
UMINUS Function (Numeric)
*/
3.21 Security Functions
/*21. Security Functions*/
/*
ENCRYPTION_ROOT_KEYS_EXTRACT_KEYS Function (Security)
ENCRYPTION_ROOT_KEYS_HAS_BACKUP_PASSWORD Function (Security)
ESCAPE_DOUBLE_QUOTES Function (Security)
ESCAPE_SINGLE_QUOTES Function (Security)
GENERATE_PASSWORD Function (Security)
IS_SQL_INJECTION_SAFE Function (Security)
*/
3.22 Series Data Functions
/*22.Series Data Functions*/
/*
SERIES_DISAGGREGATE Function (Series Data)
SERIES_ELEMENT_TO_PERIOD Function (Series Data)
SERIES_GENERATE Function (Series Data)
SERIES_PERIOD_TO_ELEMENT Function (Series Data)
SERIES_ROUND Function (Series Data) [page 339]
*/
3.23 String Functions
/*23.String Functions*/
/*
ABAP_ALPHANUM Function (String)
ABAP_LOWER Function (String)
ABAP_NUMC Function (String)
ABAP_UPPER Function (String)
ASCII Function (String)
BINTOHEX Function (String)
BINTONHEX Function (String)
BINTOSTR Function (String)
CHAR Function (String)
CONCAT Function (String)
CONCAT_NAZ Function (String)
HAMMING_DISTANCE Function (String)
HEXTOBIN Function (String)
HEXTONUM Function (String)
INITCAP Function (String)
LCASE Function (String)
LEFT Function (String)
LENGTH Function (String)
LOCATE Function (String)
LOCATE_REGEXPR Function (String)
LOWER Function (String)
LPAD Function (String)
LTRIM Function (String)
NCHAR Function (String)
NORMALIZE Function (String)
NUMTOHEX Function (String)
OCCURRENCES_REGEXPR Function (String)
REPLACE Function (String)
REPLACE_REGEXPR Function (String)
RIGHT Function (String)
RPAD Function (String)
RTRIM Function (String)
SOUNDEX Function (String)
STRTOBIN Function (String)
SUBSTR_AFTER Function (String)
SUBSTR_BEFORE Function (String)
SUBSTRING Function (String)
SUBSTRING_REGEXPR Function (String)
TRIM Function (String)
UCASE Function (String)
UNICODE Function (String)
UPPER Function (String)
XMLTABLE Function (String)
*/
3.24 Window Functions and the Window Specification
/*24.Window Functions and the Window Specification*/
/*
<function_name> <window_specification>
<window_specification> ::= OVER ( { [ <window_partition_by_clause> ] [ <window_order_by_clause> ] [ <window_frame_clause> ] } )
<function_name> ::=
BINNING | CUBIC_SPLINE_APPROX | CUME_DIST | DENSE_RANK | LAG | LEAD
| LINEAR_APPROX | NTILE | PERCENT_RANK | PERCENTILE_CONT | PERCENTILE_DISC
| RANDOM_PARTITION | RANK | ROW_NUMBER | SERIES_FILTER | WEIGHTED_AVG
| <window_aggregate_functions>
| <spatial_functions>
<window_partition_by_clause> ::= PARTITION BY <expression> [ { , <expression> } ... ]
<window_order_by_clause> ::= ORDER BY <window_order_by_expression> [ {, <window_order_by_expression> } ... ]
<window_order_by_expression> ::= <column> [ <collate_clause> ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ]
<collate_clause> ::= COLLATE <collation_name>
<window_frame_clause> ::= <window_frame_unit> <window_frame_extent>
<window_frame_extent> ::= { <window_frame_start> | <window_frame_between> }
<window_frame_unit> ::= ROWS
<window_frame_start> ::= { UNBOUNDED PRECEDING | <window_frame_preceding> | CURRENT ROW }
<window_frame_preceding> ::= <unsigned_integer> PRECEDING
<window_frame_between> ::= BETWEEN <lower_window_frame_bound> AND <upper_window_frame_bound>
<lower_window_frame_bound> ::= <window_frame_bound>
<upper_window_frame_bound> ::= <window_frame_bound>
<window_frame_bound> := { <window_frame_start> | UNBOUNDED FOLLOWING | <window_frame_following> }
<window_frame_following> ::= <unsigned_integer> FOLLOWING
<window_aggregate_functions> ::= <aggregate_function_name> ( <arguments> ) <window_specification>
<aggregate_function_name> ::=
AVG | CORR | CORR_SPEARMAN | COUNT | FIRST_VALUE | LAST_VALUE
| MAX | MEDIAN | MIN | NTH_VALUE | STDDEV | SUM | VAR
*/
以上是关于SAPHANA学习(26):SQL Function 分类汇总的主要内容,如果未能解决你的问题,请参考以下文章