All Downloads are FREE. Search and download functionalities are using the official Maven repository.

datasource.default.xml Maven / Gradle / Ivy

There is a newer version: 5.0.0
Show newest version
<?xml version="1.0"?>
<!--
 Licensed to the Apache Software Foundation (ASF) under one
 or more contributor license agreements.  See the NOTICE file
 distributed with this work for additional information
 regarding copyright ownership.  The ASF licenses this file
 to you under the Apache License, Version 2.0 (the
 "License"); you may not use this file except in compliance
 with the License.  You may obtain a copy of the License at

     http://www.apache.org/licenses/LICENSE-2.0

 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 See the License for the specific language governing permissions and
 limitations under the License.
-->
<DATASOURCE_DEF NAME="kylin" ID="default">
    <PROPERTY NAME="sql.default-converted-enabled" VALUE="true"/>
    <PROPERTY NAME="sql.allow-no-offset" VALUE="true"/>
    <PROPERTY NAME="sql.allow-fetch-no-rows" VALUE="true"/>
    <PROPERTY NAME="sql.allow-no-orderby-with-fetch" VALUE="true"/>
    <PROPERTY NAME="sql.keyword-default-escape" VALUE="true"/>
    <PROPERTY NAME="sql.keyword-default-uppercase" VALUE="true"/>
    <PROPERTY NAME="sql.case-sensitive" VALUE="false"/>
    <PROPERTY NAME="metadata.enable-cache" VALUE="false"/>
    <!--Min-->
    <FUNCTION_DEF ID="1" EXPRESSION="MIN($0)"/>
    <!--Max-->
    <FUNCTION_DEF ID="3" EXPRESSION="MAX($0)"/>
    <!--CurrentDate-->
    <FUNCTION_DEF ID="5" EXPRESSION="CURRENT_DATE"/>
    <!--CurrentDateTime-->
    <FUNCTION_DEF ID="6" EXPRESSION="CURRENT_TIMESTAMP"/>
    <!--Date-->
    <FUNCTION_DEF ID="7" EXPRESSION="CAST($0 AS DATE)"/>
    <!--DayOfMonth-->
    <FUNCTION_DEF ID="8" EXPRESSION="EXTRACT(DAY FROM $0)"/>
    <!--DayOfYear-->
    <FUNCTION_DEF ID="9" EXPRESSION="DAYOFYEAR($0)"/>
    <!--Month-->
    <FUNCTION_DEF ID="10" EXPRESSION="EXTRACT(MONTH FROM $0)"/>
    <!--Quarter-->
    <FUNCTION_DEF ID="11" EXPRESSION="EXTRACT(QUARTER FROM $0)"/>
    <!--Year-->
    <FUNCTION_DEF ID="12" EXPRESSION="EXTRACT(YEAR FROM $0)"/>
    <!--IsNotNull-->
    <FUNCTION_DEF ID="13" EXPRESSION="$0 IS NOT NULL"/>
    <!--IsNull-->
    <FUNCTION_DEF ID="14" EXPRESSION="$0 IS NULL"/>
    <!--NullToZero-->
    <FUNCTION_DEF ID="15" EXPRESSION="COALESCE($0, 0)"/>
    <!--ZeroToNull-->
    <FUNCTION_DEF ID="16" EXPRESSION="NULLIF($0, 0)"/>
    <!--FirstInRange-->
    <FUNCTION_DEF ID="17" EXPRESSION="first_value($0) over($1)"/>
    <!--MovingAvg-->
    <FUNCTION_DEF ID="18" EXPRESSION="avg($0) over($1)"/>
    <!--MovingCount-->
    <FUNCTION_DEF ID="19" EXPRESSION="count($0) over($1)"/>
    <!--MovingMax-->
    <FUNCTION_DEF ID="20" EXPRESSION="max($0) over($1)"/>
    <!--MovingMin-->
    <FUNCTION_DEF ID="21" EXPRESSION="min($0) over($1)"/>
    <!--MovingSum-->
    <FUNCTION_DEF ID="22" EXPRESSION="sum($0) over($1)"/>
    <!--RunningStdevP-->
    <FUNCTION_DEF ID="23" EXPRESSION="STDDEV_POP($0) OVER($1)"/>
    <!--LeftStr-->
    <FUNCTION_DEF ID="24" EXPRESSION="SUBSTRING($0, 1, $1)"/>
    <!--Length-->
    <FUNCTION_DEF ID="25" EXPRESSION="CHAR_LENGTH($0)"/>
    <!--Lower-->
    <FUNCTION_DEF ID="26" EXPRESSION="LOWER($0)"/>
    <!--SubStr-->
    <FUNCTION_DEF ID="27" EXPRESSION="SUBSTRING($0, $1, $2)"/>
    <!--initcap-->
    <FUNCTION_DEF ID="28" EXPRESSION="INITCAP($0)"/>
    <!--Trim-->
    <FUNCTION_DEF ID="29" EXPRESSION="TRIM($0)"/>
    <!--Upper-->
    <FUNCTION_DEF ID="30" EXPRESSION="UPPER($0)"/>
    <!--Abs-->
    <FUNCTION_DEF ID="31" EXPRESSION="ABS($0)"/>
    <!--Acos-->
    <FUNCTION_DEF ID="32" EXPRESSION="ACOS($0)"/>
    <!--Asin-->
    <FUNCTION_DEF ID="34" EXPRESSION="ASIN($0)"/>
    <!--Atan-->
    <FUNCTION_DEF ID="36" EXPRESSION="ATAN($0)"/>
    <!--Atan2-->
    <FUNCTION_DEF ID="37" EXPRESSION="ATAN2($1, $0)"/>
    <!--Ceiling-->
    <FUNCTION_DEF ID="39" EXPRESSION="CEIL($0)"/>
    <!--Cos-->
    <FUNCTION_DEF ID="40" EXPRESSION="COS($0)"/>
    <!--Degrees-->
    <FUNCTION_DEF ID="42" EXPRESSION="DEGREES($0)"/>
    <!--Exp-->
    <FUNCTION_DEF ID="43" EXPRESSION="EXP($0)"/>
    <!--Floor-->
    <FUNCTION_DEF ID="44" EXPRESSION="FLOOR($0)"/>
    <!--Int-->
    <FUNCTION_DEF ID="45" EXPRESSION="FLOOR($0)"/>
    <!--Int2-->
    <FUNCTION_DEF ID="46" EXPRESSION="FLOOR($0)"/>
    <!--Ln-->
    <FUNCTION_DEF ID="47" EXPRESSION="LN($0)"/>
    <!--Log-->
    <FUNCTION_DEF ID="48" EXPRESSION="LN($0)/LN($1)"/>
    <!--Log10-->
    <FUNCTION_DEF ID="49" EXPRESSION="LOG10($0)"/>
    <!--Mod-->
    <FUNCTION_DEF ID="50" EXPRESSION="$0-FLOOR($0/$1)*$1"/>
    <!--Power-->
    <FUNCTION_DEF ID="51" EXPRESSION="POWER($0, $1)"/>
    <!--Radians-->
    <FUNCTION_DEF ID="53" EXPRESSION="RADIANS($0)"/>
    <!--Round-->
    <FUNCTION_DEF ID="55" EXPRESSION="ROUND($0, 0)"/>
    <!--Sin-->
    <FUNCTION_DEF ID="56" EXPRESSION="SIN($0)"/>
    <!--Sqrt-->
    <FUNCTION_DEF ID="58" EXPRESSION="SQRT($0)"/>
    <!--Tan-->
    <FUNCTION_DEF ID="59" EXPRESSION="TAN($0)"/>
    <!--Trunc-->
    <FUNCTION_DEF ID="61" EXPRESSION="CAST($0 AS INTEGER)"/>
    <!--Median-->
    <FUNCTION_DEF ID="63" EXPRESSION="MEDIAN($0)"/>
    <!--Daysbetween-->
    <FUNCTION_DEF ID="64" EXPRESSION="TIMESTAMPDIFF(day, $0, $1)"/>
    <!--DateAdd-->
    <FUNCTION_DEF ID="65" EXPRESSION="TIMESTAMPADD(day, $1, $0)"/>
    <!--AddMonths-->
    <FUNCTION_DEF ID="66" EXPRESSION="TIMESTAMPADD(month, $1, $0)"/>
    <!--CurrentTime-->
    <FUNCTION_DEF ID="67" EXPRESSION="CURRENT_TIME"/>
    <!--DayofWeek-->
    <FUNCTION_DEF ID="68" EXPRESSION="DAYOFWEEK($0)"/>
    <!--Monthsbetween-->
    <FUNCTION_DEF ID="69" EXPRESSION="TIMESTAMPDIFF(month, $0, $1)"/>
    <!--Week-->
    <FUNCTION_DEF ID="70" EXPRESSION="WEEK($0)"/>
    <!--NulltoEmpty-->
    <FUNCTION_DEF ID="71" EXPRESSION="COALESCE($0, '')"/>
    <!--StrBeginsWith-->
    <FUNCTION_DEF ID="72"
                  EXPRESSION="case when SUBSTRING($0 from 1 for CHAR_LENGTH('$1') ) =$1 then 1 else 0 end"/>
    <!--Concat-->
    <FUNCTION_DEF ID="73" EXPRESSION="concat ($0 , $1)"/>
    <!--StrEndsWith-->
    <FUNCTION_DEF ID="74"
                  EXPRESSION="case when SUBSTRING($0 from  (CHAR_LENGTH($0)-CHAR_LENGTH($1)+1) for CHAR_LENGTH($1) ) =$1 then 1 else 0 end"/>
    <!--LTrim-->
    <FUNCTION_DEF ID="76" EXPRESSION="TRIM( LEADING ' '  FROM $0)"/>
    <!--Position-->
    <FUNCTION_DEF ID="77" EXPRESSION="POSITION($0 IN $1)"/>
    <!--StrReplace-->
    <FUNCTION_DEF ID="78" EXPRESSION="REPLACE($0, $1, $2)"/>
    <!--RightStr-->
    <FUNCTION_DEF ID="79"
                  EXPRESSION="SUBSTRING($0 FROM (char_length($0) -$1 +1) FOR $1)"/>
    <!--RTrim-->
    <FUNCTION_DEF ID="80" EXPRESSION="TRIM(TRAILING ' '  FROM $0)"/>
    <!--Round2-->
    <FUNCTION_DEF ID="81" EXPRESSION="ROUND($0, $1)"/>
    <!--CORRELATION -->
    <FUNCTION_DEF ID="82" EXPRESSION="CORR($0, $1)"/>
    <!--Random number-->
    <FUNCTION_DEF ID="83" EXPRESSION="RAND()"/>

    <!--CAST VARCHAR-->
    <FUNCTION_DEF ID="101" EXPRESSION="CAST($0 AS VARCHAR)"/>

    <FUNCTION_DEF ID="201" EXPRESSION="CAST($0 AS TIMESTAMP)"/>
    <FUNCTION_DEF ID="202" EXPRESSION="CAST($0 AS DOUBLE)"/>

    <TYPE_DEF ID="Any" EXPRESSION="ANY"/>

    <TYPE_DEF ID="Integer" EXPRESSION="INTEGER"/>
    <TYPE_DEF ID="Int" EXPRESSION="INT"/>
    <TYPE_DEF ID="BigInt" EXPRESSION="BIGINT"/>
    <TYPE_DEF ID="TinyInt" EXPRESSION="TINYINT"/>
    <TYPE_DEF ID="SmallInt" EXPRESSION="SMALLINT"/>
    <TYPE_DEF ID="Short" EXPRESSION="SHORT"/>
    <TYPE_DEF ID="Long" EXPRESSION="LONG"/>

    <TYPE_DEF ID="Numeric" EXPRESSION="NUMERIC($p, $s)"/>
    <TYPE_DEF ID="Decimal" EXPRESSION="DECIMAL($p, $s)"/>
    <TYPE_DEF ID="Real" EXPRESSION="REAL"/>
    <TYPE_DEF ID="Double" EXPRESSION="DOUBLE"/>
    <TYPE_DEF ID="Float" EXPRESSION="FLOAT"/>

    <TYPE_DEF ID="Char" EXPRESSION="CHAR($p)"/>
    <TYPE_DEF ID="VarChar" EXPRESSION="VARCHAR($p)"/>
    <TYPE_DEF ID="String" EXPRESSION="STRING"/>

    <TYPE_DEF ID="Binary" EXPRESSION="BINARY"/>
    <TYPE_DEF ID="Byte" EXPRESSION="BYTE"/>
    <TYPE_DEF ID="Boolean" EXPRESSION="BOOLEAN"/>

    <TYPE_DEF ID="Date" EXPRESSION="DATE"/>
    <TYPE_DEF ID="Time" EXPRESSION="TIME"/>
    <TYPE_DEF ID="DateTime" EXPRESSION="DATETIME"/>
    <TYPE_DEF ID="TimeStamp" EXPRESSION="TIMESTAMP"/>
</DATASOURCE_DEF>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy