Qore SqlUtil Module Reference
1.2
|
Functions | |
hash | SqlUtil::cop_append (any column, string arg) |
returns a hash for the "append" operator with the given argument More... | |
hash | SqlUtil::cop_as (any column, string arg) |
returns a hash for the "as" operator with the given argument More... | |
hash | SqlUtil::cop_avg (any column) |
returns a hash for the "avg" operator; returns average column values More... | |
hash | SqlUtil::cop_count (string column="") |
returns a hash for the "count" operator; returns row counts More... | |
hash | SqlUtil::cop_distinct (any column) |
returns a hash for the "distinct" operator with the given argument; returns distinct column values More... | |
hash | SqlUtil::cop_divide (any column1, any column2) |
returns a hash for the "/" operator with the given arguments More... | |
hash | SqlUtil::cop_lower (any column) |
returns a hash for the "lower" operator with the given argument; returns a column value in lower case More... | |
hash | SqlUtil::cop_max (any column) |
returns a hash for the "max" operator; returns maximum column values More... | |
hash | SqlUtil::cop_min (any column) |
returns a hash for the "min" operator; returns minimum column values More... | |
hash | SqlUtil::cop_minus (any column1, any column2) |
returns a hash for the "-" operator with the given arguments More... | |
hash | SqlUtil::cop_multiply (any column1, any column2) |
returns a hash for the "*" operator with the given arguments More... | |
hash | SqlUtil::cop_over (any column, string arg) |
returns a hash for the "over" clause More... | |
hash | SqlUtil::cop_plus (any column1, any column2) |
returns a hash for the "+" operator with the given arguments More... | |
hash | SqlUtil::cop_prepend (any column, string arg) |
returns a hash for the "prepend" operator with the given argument More... | |
hash | SqlUtil::cop_seq (string seq) |
returns a hash for the "seq" operator with the given argument giving the sequence name whose value should be returned More... | |
hash | SqlUtil::cop_upper (any column) |
returns a hash for the "upper" operator with the given argument; returns a column value in upper case More... | |
hash | SqlUtil::cop_value (any arg) |
returns a hash for the "value" operator with the given argument More... | |
hash | SqlUtil::cop_year (any column) |
returns a hash for the "year" operator with the given argument More... | |
hash | SqlUtil::cop_year_day (any column) |
returns a hash for the "year_day" operator with the given argument More... | |
hash | SqlUtil::cop_year_hour (any column) |
returns a hash for the "year_hour" operator with the given argument More... | |
hash | SqlUtil::cop_year_month (any column) |
returns a hash for the "year_month" operator with the given argument More... | |
hash | SqlUtil::make_cop (string cop, any column, any arg) |
returns a hash with cop , column , and arg keys More... | |
These are functions that can be used in the "columns"
argument for select statements:
Column operator functions can be nested as in the following example:
returns a hash for the "append"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
arg | the text to append (ie concatenate) to the row values in the output column |
returns a hash for the "as"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
arg | the new name of the output column |
hash SqlUtil::cop_avg | ( | any | column | ) |
returns a hash for the "avg"
operator; returns average column values
column | the column specification for the column (string name or dot notation for use in joins) |
returns a hash for the "count"
operator; returns row counts
hash SqlUtil::cop_distinct | ( | any | column | ) |
returns a hash for the "distinct"
operator with the given argument; returns distinct column values
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_divide | ( | any | column1, |
any | column2 | ||
) |
returns a hash for the "/"
operator with the given arguments
column1 | the column specification for the first argument (string name or dot notation for use in joins) |
column2 | the column specification for the second argument (string name or dot notation for use in joins) |
arg | the new name of the output column |
hash SqlUtil::cop_lower | ( | any | column | ) |
returns a hash for the "lower"
operator with the given argument; returns a column value in lower case
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_max | ( | any | column | ) |
returns a hash for the "max"
operator; returns maximum column values
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_min | ( | any | column | ) |
returns a hash for the "min"
operator; returns minimum column values
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_minus | ( | any | column1, |
any | column2 | ||
) |
returns a hash for the "-"
operator with the given arguments
column1 | the column specification for the first argument (string name or dot notation for use in joins) |
column2 | the column specification for the second argument (string name or dot notation for use in joins) |
arg | the new name of the output column |
hash SqlUtil::cop_multiply | ( | any | column1, |
any | column2 | ||
) |
returns a hash for the "*"
operator with the given arguments
column1 | the column specification for the first argument (string name or dot notation for use in joins) |
column2 | the column specification for the second argument (string name or dot notation for use in joins) |
arg | the new name of the output column |
returns a hash for the "over"
clause
hash SqlUtil::cop_plus | ( | any | column1, |
any | column2 | ||
) |
returns a hash for the "+"
operator with the given arguments
column1 | the column specification for the first argument (string name or dot notation for use in joins) |
column2 | the column specification for the second argument (string name or dot notation for use in joins) |
arg | the new name of the output column |
returns a hash for the "prepend"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
arg | the text to prepend to the row values in the output column |
returns a hash for the "seq"
operator with the given argument giving the sequence name whose value should be returned
seq | the name of the sequence whose value should be returned |
hash SqlUtil::cop_upper | ( | any | column | ) |
returns a hash for the "upper"
operator with the given argument; returns a column value in upper case
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_value | ( | any | arg | ) |
returns a hash for the "value"
operator with the given argument
arg | the value to be returned in the column |
hash SqlUtil::cop_year | ( | any | column | ) |
returns a hash for the "year"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_year_day | ( | any | column | ) |
returns a hash for the "year_day"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_year_hour | ( | any | column | ) |
returns a hash for the "year_hour"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
hash SqlUtil::cop_year_month | ( | any | column | ) |
returns a hash for the "year_month"
operator with the given argument
column | the column specification for the column (string name or dot notation for use in joins) |
returns a hash with cop
, column
, and arg
keys
cop | the column operator (one of SQL Column Operators) |
column | the column name |
arg | the argument to the operator |