forked from docs/doc-exports
dli_sqlreference_20240227
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com> Co-authored-by: Su, Xiaomeng <suxiaomeng1@huawei.com> Co-committed-by: Su, Xiaomeng <suxiaomeng1@huawei.com>
This commit is contained in:
parent
03485beee6
commit
76a5b1ee83
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -8,9 +8,15 @@
|
|||||||
</th>
|
</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody><tr id="dli_08_00005__row01821691115"><td class="cellrowborder" valign="top" width="26.91%" headers="mcps1.3.1.1.3.1.1 "><p id="dli_08_00005__p1518161613115">2023-05-11</p>
|
<tbody><tr id="dli_08_00005__row12859104143211"><td class="cellrowborder" valign="top" width="26.91%" headers="mcps1.3.1.1.3.1.1 "><p id="dli_08_00005__p18859546324">2024-02-27</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="73.09%" headers="mcps1.3.1.1.3.1.2 "><p id="dli_08_00005__p44066501444">This is the first official release.</p>
|
<td class="cellrowborder" valign="top" width="73.09%" headers="mcps1.3.1.1.3.1.2 "><p id="dli_08_00005__p48595423211">Modified the following section:</p>
|
||||||
|
<p id="dli_08_00005__p1731818143210">Added the description that DDS is fully compatible with the MongoDB protocol to <a href="dli_08_0230.html">Creating a DLI Table and Associating It with DDS</a>.</p>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr id="dli_08_00005__row01821691115"><td class="cellrowborder" valign="top" width="26.91%" headers="mcps1.3.1.1.3.1.1 "><p id="dli_08_00005__p1518161613115">2023-05-11</p>
|
||||||
|
</td>
|
||||||
|
<td class="cellrowborder" valign="top" width="73.09%" headers="mcps1.3.1.1.3.1.2 "><p id="dli_08_00005__p44066501444">This issue is the first official release.</p>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
<a name="dli_08_0055"></a><a name="dli_08_0055"></a>
|
<a name="dli_08_0055"></a><a name="dli_08_0055"></a>
|
||||||
|
|
||||||
<h1 class="topictitle1">window_function</h1>
|
<h1 class="topictitle1">window_function</h1>
|
||||||
<div id="body8662426"><div class="section" id="dli_08_0055__en-us_topic_0093946997_s725b4b21e0854eb99cec49e92e9a9037"><h4 class="sectiontitle">Syntax</h4><p id="dli_08_0055__en-us_topic_0093946997_ae993f759894247638bf3ecca5718669e">None.</p>
|
<div id="body8662426"><div class="section" id="dli_08_0055__en-us_topic_0093946997_s725b4b21e0854eb99cec49e92e9a9037"><h4 class="sectiontitle">Syntax</h4><p id="dli_08_0055__en-us_topic_0093946997_ae993f759894247638bf3ecca5718669e">None</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0055__en-us_topic_0093946997_s56396fccaf6b4c75a0eb3caf42191d58"><h4 class="sectiontitle">Description</h4><p id="dli_08_0055__en-us_topic_0093946997_a2e36b1947c8a4894930509659ca8f788">Analysis window function. For details, see <a href="dli_08_0069.html">Window Functions</a>.</p>
|
<div class="section" id="dli_08_0055__en-us_topic_0093946997_s56396fccaf6b4c75a0eb3caf42191d58"><h4 class="sectiontitle">Description</h4><p id="dli_08_0055__en-us_topic_0093946997_a2e36b1947c8a4894930509659ca8f788">Analysis window function.</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr id="dli_08_0058__en-us_topic_0093946969_r0ab4c604cfef45b2962fc14b482d4d7d"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.2.7.1.1 "><p id="dli_08_0058__en-us_topic_0093946969_acaa294c729e240c8a9ec4b6dbe7fe46f">STRING</p>
|
<tr id="dli_08_0058__en-us_topic_0093946969_r0ab4c604cfef45b2962fc14b482d4d7d"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.2.7.1.1 "><p id="dli_08_0058__en-us_topic_0093946969_acaa294c729e240c8a9ec4b6dbe7fe46f">STRING</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.2.2.7.1.2 "><p id="dli_08_0058__en-us_topic_0093946969_a40258709ca0048638f9e84a836cc6b34">Character string</p>
|
<td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.2.2.7.1.2 "><p id="dli_08_0058__en-us_topic_0093946969_a40258709ca0048638f9e84a836cc6b34">String</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="10.979999999999999%" headers="mcps1.3.2.2.7.1.3 "><p id="dli_08_0058__en-us_topic_0093946969_a7e30ac8546624938966395f5d2f22d6a">-</p>
|
<td class="cellrowborder" valign="top" width="10.979999999999999%" headers="mcps1.3.2.2.7.1.3 "><p id="dli_08_0058__en-us_topic_0093946969_a7e30ac8546624938966395f5d2f22d6a">-</p>
|
||||||
</td>
|
</td>
|
||||||
@ -152,7 +152,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr id="dli_08_0058__en-us_topic_0093946969_row46625912111351"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.2.7.1.1 "><p id="dli_08_0058__en-us_topic_0093946969_p18602527111351">CHAR</p>
|
<tr id="dli_08_0058__en-us_topic_0093946969_row46625912111351"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.2.7.1.1 "><p id="dli_08_0058__en-us_topic_0093946969_p18602527111351">CHAR</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.2.2.7.1.2 "><p id="dli_08_0058__en-us_topic_0093946969_p30409710111351">Fixed-length character string</p>
|
<td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.2.2.7.1.2 "><p id="dli_08_0058__en-us_topic_0093946969_p30409710111351">Fixed-length string</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="10.979999999999999%" headers="mcps1.3.2.2.7.1.3 "><p id="dli_08_0058__en-us_topic_0093946969_p47267470111351">-</p>
|
<td class="cellrowborder" valign="top" width="10.979999999999999%" headers="mcps1.3.2.2.7.1.3 "><p id="dli_08_0058__en-us_topic_0093946969_p47267470111351">-</p>
|
||||||
</td>
|
</td>
|
||||||
@ -165,7 +165,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr id="dli_08_0058__en-us_topic_0093946969_rb9fa3fa3a0c74c2883dd952a47f4fd12"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.2.7.1.1 "><p id="dli_08_0058__en-us_topic_0093946969_ac51d06b3c03247d0a491e1570c59c893">VARCHAR</p>
|
<tr id="dli_08_0058__en-us_topic_0093946969_rb9fa3fa3a0c74c2883dd952a47f4fd12"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.2.7.1.1 "><p id="dli_08_0058__en-us_topic_0093946969_ac51d06b3c03247d0a491e1570c59c893">VARCHAR</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.2.2.7.1.2 "><p id="dli_08_0058__en-us_topic_0093946969_a99ad87e5b639412eb6d0a2b9137bd8f3">Variable-length character string</p>
|
<td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.2.2.7.1.2 "><p id="dli_08_0058__en-us_topic_0093946969_a99ad87e5b639412eb6d0a2b9137bd8f3">Variable-length string</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="10.979999999999999%" headers="mcps1.3.2.2.7.1.3 "><p id="dli_08_0058__en-us_topic_0093946969_a19dd2cfccdc448d2860b0d4e2e14d531">-</p>
|
<td class="cellrowborder" valign="top" width="10.979999999999999%" headers="mcps1.3.2.2.7.1.3 "><p id="dli_08_0058__en-us_topic_0093946969_a19dd2cfccdc448d2860b0d4e2e14d531">-</p>
|
||||||
</td>
|
</td>
|
||||||
@ -196,7 +196,7 @@
|
|||||||
</div></div>
|
</div></div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s3fd96a757f754df4af005180d997834c"><h4 class="sectiontitle">INT</h4><p id="dli_08_0058__en-us_topic_0093946969_a3172e5e52d124b7190abf797dd78ff08">Signed integer with a storage space of 4 bytes. Its value ranges from –2147483648 to 2147483647. If this field is NULL, value 0 is used by default.</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s3fd96a757f754df4af005180d997834c"><h4 class="sectiontitle">INT</h4><p id="dli_08_0058__en-us_topic_0093946969_a3172e5e52d124b7190abf797dd78ff08">Signed integer with a storage space of 4 bytes. Its value ranges from –2147483648 to 2147483647. If this field is NULL, value 0 is used by default.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s2fed4222fc754407bdcecd755afe4530"><h4 class="sectiontitle">STRING</h4><p id="dli_08_0058__en-us_topic_0093946969_ab1a62456d0ec4ce1a94944f78c004037">Character string.</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s2fed4222fc754407bdcecd755afe4530"><h4 class="sectiontitle">STRING</h4><p id="dli_08_0058__en-us_topic_0093946969_ab1a62456d0ec4ce1a94944f78c004037">String.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s1255dd68d61440f7bb4624c9a0afb3f5"><h4 class="sectiontitle">FLOAT</h4><p id="dli_08_0058__en-us_topic_0093946969_ac797ebfa89d3495983910b36022f3358">Single-precision floating point with a storage space of 4 bytes. If this field is NULL, value 0 is used by default.</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s1255dd68d61440f7bb4624c9a0afb3f5"><h4 class="sectiontitle">FLOAT</h4><p id="dli_08_0058__en-us_topic_0093946969_ac797ebfa89d3495983910b36022f3358">Single-precision floating point with a storage space of 4 bytes. If this field is NULL, value 0 is used by default.</p>
|
||||||
<p id="dli_08_0058__en-us_topic_0093946969_a45c4eb6818604a279f96c1f13d405c53">Due to the limitation of storage methods of floating point data, do not use the formula a==b to check whether two floating point values are the same. You are advised to use the formula: absolute value of (a-b) <= EPSILON. EPSILON indicates the allowed error range which is usually 1.19209290E-07F. If the formula is satisfied, the compared two floating point values are considered the same.</p>
|
<p id="dli_08_0058__en-us_topic_0093946969_a45c4eb6818604a279f96c1f13d405c53">Due to the limitation of storage methods of floating point data, do not use the formula a==b to check whether two floating point values are the same. You are advised to use the formula: absolute value of (a-b) <= EPSILON. EPSILON indicates the allowed error range which is usually 1.19209290E-07F. If the formula is satisfied, the compared two floating point values are considered the same.</p>
|
||||||
@ -214,9 +214,9 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s01990391fac644a19a9e07556a0eeca5"><h4 class="sectiontitle">BIGINT/LONG</h4><p id="dli_08_0058__en-us_topic_0093946969_a0bdbab4085c5404ab65b0fd92e678ff3">Signed integer with a storage space of 8 bytes. Its value ranges from –9223372036854775808 to 9223372036854775807. It does not support scientific notation. If this field is NULL, value 0 is used by default.</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s01990391fac644a19a9e07556a0eeca5"><h4 class="sectiontitle">BIGINT/LONG</h4><p id="dli_08_0058__en-us_topic_0093946969_a0bdbab4085c5404ab65b0fd92e678ff3">Signed integer with a storage space of 8 bytes. Its value ranges from –9223372036854775808 to 9223372036854775807. It does not support scientific notation. If this field is NULL, value 0 is used by default.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_sd448b61418194d3095d5acdb8efb2519"><h4 class="sectiontitle">TIMESTAMP</h4><p id="dli_08_0058__en-us_topic_0093946969_aed42b60bcded4bd2a8ca6cc3762ce059">Legacy UNIX TIMESTAMP is supported, providing the precision up to the microsecond level. <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616279">TIMESTAMP</strong> is defined by the difference between the specified time and UNIX epoch (UNIX epoch time: 1970-01-01 00:00:00) in seconds. Data of the STRING type supports implicit conversion to TIMESTAMP. (The STRING must in the yyyy-MM-dd HH:MM:SS[.ffffff] format. The precision after the decimal point is optional.)</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_sd448b61418194d3095d5acdb8efb2519"><h4 class="sectiontitle">TIMESTAMP</h4><p id="dli_08_0058__en-us_topic_0093946969_aed42b60bcded4bd2a8ca6cc3762ce059">Legacy UNIX TIMESTAMP is supported, providing the precision up to the microsecond level. <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616279">TIMESTAMP</strong> is defined by the difference between the specified time and UNIX epoch (UNIX epoch time: 1970-01-01 00:00:00) in seconds. The data type <strong id="dli_08_0058__b191997451272">STRING</strong> can be implicitly converted to <strong id="dli_08_0058__b1410311479276">TIMESTAMP</strong>, but it must be in the <strong id="dli_08_0058__b938112192814">yyyy-MM-dd HH:mm:SS[.ffffff]</strong> format. The precision after the decimal point is optional.)</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_section5343054214381"><h4 class="sectiontitle">CHAR</h4><p id="dli_08_0058__en-us_topic_0093946969_p3965738814384">Character string with a fixed length. In DLI, the STRING type is used.</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_section5343054214381"><h4 class="sectiontitle">CHAR</h4><p id="dli_08_0058__en-us_topic_0093946969_p3965738814384">String with a fixed length. In DLI, the STRING type is used.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s860ebe75a3f0428980b452084ced6412"><h4 class="sectiontitle">VARCHAR</h4><p id="dli_08_0058__en-us_topic_0093946969_a501f438ac5064d498e0a4816ce6ef1f2"><strong id="dli_08_0058__en-us_topic_0093946969_b842352706162840">VARCHAR</strong> is declared with a length that indicates the maximum number of characters in a string. During conversion from <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616294">STRING</strong> to <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616298">VARCHAR</strong>, if the number of characters in <strong id="dli_08_0058__en-us_topic_0093946969_b842352706162918">STRING</strong> exceeds the specified length, the excess characters of <strong id="dli_08_0058__en-us_topic_0093946969_b842352706162938">STRING</strong> are automatically trimmed. Similar to <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616306">STRING</strong>, the spaces at the end of <strong id="dli_08_0058__en-us_topic_0093946969_b842352706163010">VARCHAR</strong> are meaningful and affect the comparison result. In DLI, the STRING type is used.</p>
|
<div class="section" id="dli_08_0058__en-us_topic_0093946969_s860ebe75a3f0428980b452084ced6412"><h4 class="sectiontitle">VARCHAR</h4><p id="dli_08_0058__en-us_topic_0093946969_a501f438ac5064d498e0a4816ce6ef1f2"><strong id="dli_08_0058__en-us_topic_0093946969_b842352706162840">VARCHAR</strong> is declared with a length that indicates the maximum number of characters in a string. During conversion from <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616294">STRING</strong> to <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616298">VARCHAR</strong>, if the number of characters in <strong id="dli_08_0058__en-us_topic_0093946969_b842352706162918">STRING</strong> exceeds the specified length, the excess characters of <strong id="dli_08_0058__en-us_topic_0093946969_b842352706162938">STRING</strong> are automatically trimmed. Similar to <strong id="dli_08_0058__en-us_topic_0093946969_b84235270616306">STRING</strong>, the spaces at the end of <strong id="dli_08_0058__en-us_topic_0093946969_b842352706163010">VARCHAR</strong> are meaningful and affect the comparison result. In DLI, the STRING type is used.</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -4,15 +4,17 @@
|
|||||||
<div id="body8662426"></div>
|
<div id="body8662426"></div>
|
||||||
<div>
|
<div>
|
||||||
<ul class="ullinks">
|
<ul class="ullinks">
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0065.html">Mathematical Functions</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0471.html">Date Functions</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0066.html">Date Functions</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0472.html">String Functions</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0067.html">String Functions</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0473.html">Mathematical Functions</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0068.html">Aggregate Functions</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0474.html">Aggregate Functions</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0069.html">Window Functions</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0475.html">Window Functions</a></strong><br>
|
||||||
|
</li>
|
||||||
|
<li class="ulchildlink"><strong><a href="dli_08_0476.html">Other Functions</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -12,11 +12,11 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_s15f56ad46e8f476986860b44d58d0545"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_ul19329628111649"><li id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_li34892402111649"><strong id="dli_08_0071__en-us_topic_0093946907_b842352706144821">IF NOT EXISTS</strong>: Prevents system errors if the database to be created exists.</li><li id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_li6687122111652"><strong id="dli_08_0071__en-us_topic_0093946907_b84235270614493">COMMENT</strong>: Describes a database.</li></ul>
|
<div class="section" id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_s15f56ad46e8f476986860b44d58d0545"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_ul19329628111649"><li id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_li34892402111649"><strong id="dli_08_0071__en-us_topic_0093946907_b842352706144821">IF NOT EXISTS</strong>: Prevents system errors if the database to be created exists.</li><li id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_li6687122111652"><strong id="dli_08_0071__en-us_topic_0093946907_b84235270614493">COMMENT</strong>: Describes a database.</li></ul>
|
||||||
<ul id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_ul8864649111656"><li id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_li6257107111656"><strong id="dli_08_0071__en-us_topic_0093946907_b842352706144914">DBPROPERTIES</strong>: Specifies database attributes. The attribute name and attribute value appear in pairs.</li></ul>
|
<ul id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_ul8864649111656"><li id="dli_08_0071__en-us_topic_0114776165_en-us_topic_0093946907_li6257107111656"><strong id="dli_08_0071__en-us_topic_0093946907_b842352706144914">DBPROPERTIES</strong>: Specifies database attributes. The attribute name and attribute value appear in pairs.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0071__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0071__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0071__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0071__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0071__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0071__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0071__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0071__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0071__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0071__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,12 +8,12 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_s1abdf21b005747b3874f626419bd591b"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_p5043518695416"><strong id="dli_08_0072__en-us_topic_0114776166_b1454744510429">IF EXISTS</strong>: Prevents system errors if the database to be deleted does not exist.</p>
|
<div class="section" id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_s1abdf21b005747b3874f626419bd591b"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_p5043518695416"><strong id="dli_08_0072__en-us_topic_0114776166_b1454744510429">IF EXISTS</strong>: Prevents system errors if the database to be deleted does not exist.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_sfc216fe9b4ca4acbae65fd45de064533"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0072__ul102204420463"><li id="dli_08_0072__li142274444614"><strong id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_b842352706144955">DATABASE</strong> and <strong id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_b842352706144958">SCHEMA</strong> can be used interchangeably. You are advised to use <strong id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_b84235270614503">DATABASE</strong>.</li><li id="dli_08_0072__li20221644134619"><strong id="dli_08_0072__b10272132419181">RESTRICT</strong>: If the database is not empty (tables exist), an error is reported and the <strong id="dli_08_0072__b1618409187">DROP</strong> operation fails. <strong id="dli_08_0072__b7173950161811">RESTRICT</strong> is the default logic.</li><li id="dli_08_0072__li12334434611"><strong id="dli_08_0072__b31571213152213">CASCADE</strong>: Even if the database is not empty (tables exist), the <strong id="dli_08_0072__b91929173244">DROP</strong> will delete all the tables in the database. Therefore, exercise caution when using this function.</li></ul>
|
<div class="section" id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_sfc216fe9b4ca4acbae65fd45de064533"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0072__ul102204420463"><li id="dli_08_0072__li142274444614"><strong id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_b842352706144955">DATABASE</strong> and <strong id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_b842352706144958">SCHEMA</strong> can be used interchangeably. You are advised to use <strong id="dli_08_0072__en-us_topic_0114776166_en-us_topic_0093946803_b84235270614503">DATABASE</strong>.</li><li id="dli_08_0072__li20221644134619"><strong id="dli_08_0072__b10272132419181">RESTRICT</strong>: If the database is not empty (tables exist), an error is reported and the <strong id="dli_08_0072__b1618409187">DROP</strong> operation fails. <strong id="dli_08_0072__b7173950161811">RESTRICT</strong> is the default logic.</li><li id="dli_08_0072__li12334434611"><strong id="dli_08_0072__b31571213152213">CASCADE</strong>: Even if the database is not empty (tables exist), the <strong id="dli_08_0072__b91929173244">DROP</strong> will delete all the tables in the database. Therefore, exercise caution when using this function.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0072__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0072__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0072__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0072__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.5.2.2.3.1.1"><p id="dli_08_0072__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0072__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter</caption><thead align="left"><tr id="dli_08_0072__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.5.2.2.3.1.1"><p id="dli_08_0072__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.5.2.2.3.1.2"><p id="dli_08_0072__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.5.2.2.3.1.2"><p id="dli_08_0072__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0073__en-us_topic_0114776167_en-us_topic_0093946974_s5d84117cf4644817826303ec1f0ca9ae"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0073__en-us_topic_0114776167_en-us_topic_0093946974_aeb9d5ecdb8234ea1808816b9571d2030">EXTENDED: Displays the database properties.</p>
|
<div class="section" id="dli_08_0073__en-us_topic_0114776167_en-us_topic_0093946974_s5d84117cf4644817826303ec1f0ca9ae"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0073__en-us_topic_0114776167_en-us_topic_0093946974_aeb9d5ecdb8234ea1808816b9571d2030">EXTENDED: Displays the database properties.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0073__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0073__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0073__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0073__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0073__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0073__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter</caption><thead align="left"><tr id="dli_08_0073__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0073__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0073__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0073__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0074__en-us_topic_0114776168_en-us_topic_0093946767_s048cef1892e14c66b05ea6a6dacd97cc"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0074__en-us_topic_0114776168_en-us_topic_0093946767_a6cc9d32172d44bfb82a9ee94318e6629">None</p>
|
<div class="section" id="dli_08_0074__en-us_topic_0114776168_en-us_topic_0093946767_s048cef1892e14c66b05ea6a6dacd97cc"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0074__en-us_topic_0114776168_en-us_topic_0093946767_a6cc9d32172d44bfb82a9ee94318e6629">None</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0074__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0074__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0074__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0074__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0074__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0074__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter</caption><thead align="left"><tr id="dli_08_0074__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="21.3%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0074__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0074__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="78.7%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0074__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -10,10 +10,10 @@
|
|||||||
<p id="dli_08_0079__p67635835412">Or</p>
|
<p id="dli_08_0079__p67635835412">Or</p>
|
||||||
<pre class="screen" id="dli_08_0079__screen135881227541">ALTER TABLE table_name RECOVER PARTITIONS;</pre>
|
<pre class="screen" id="dli_08_0079__screen135881227541">ALTER TABLE table_name RECOVER PARTITIONS;</pre>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0079__en-us_topic_0114776175_en-us_topic_0093946864_s0c845eb1e41148d79029d4f419b4fc4f"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0079__ul85891167229"><li id="dli_08_0079__li145908169227">PARTITIONS: partition information</li><li id="dli_08_0079__li14590101622219">SERDEPROPERTIES: Serde attribute</li></ul>
|
<div class="section" id="dli_08_0079__en-us_topic_0114776175_en-us_topic_0093946864_s0c845eb1e41148d79029d4f419b4fc4f"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0079__ul85891167229"><li id="dli_08_0079__li145908169227">PARTITIONS: partition information</li><li id="dli_08_0079__li14590101622219">SERDEPROPERTIES: Serde attribute</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.759999999999998%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.759999999999998%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="81.24%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="81.24%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0079__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0083.html">Deleting a Partition</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0083.html">Deleting a Partition</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0343.html">Deleting Partitions by Specifying Filter Criteria (Only OBS Tables Supported)</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0343.html">Deleting Partitions by Specifying Filter Criteria (Only Supported on OBS Tables)</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
<li class="ulchildlink"><strong><a href="dli_08_0084.html">Altering the Partition Location of a Table (Only OBS Tables Supported)</a></strong><br>
|
<li class="ulchildlink"><strong><a href="dli_08_0084.html">Altering the Partition Location of a Table (Only OBS Tables Supported)</a></strong><br>
|
||||||
</li>
|
</li>
|
||||||
|
@ -18,10 +18,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_s0c845eb1e41148d79029d4f419b4fc4f"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0081__ul85891167229"><li id="dli_08_0081__li145901169229">IF NOT EXISTS: prevents errors when partitions are repeatedly added.</li><li id="dli_08_0081__li145908169227">PARTITION: specifies a partition.</li><li id="dli_08_0081__li14590101622219">LOCATION: specifies the partition path.</li></ul>
|
<div class="section" id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_s0c845eb1e41148d79029d4f419b4fc4f"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0081__ul85891167229"><li id="dli_08_0081__li145901169229">IF NOT EXISTS: prevents errors when partitions are repeatedly added.</li><li id="dli_08_0081__li145908169227">PARTITION: specifies a partition.</li><li id="dli_08_0081__li14590101622219">LOCATION: specifies the partition path.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.060000000000002%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.060000000000002%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="81.94%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="81.94%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0081__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
||||||
</th>
|
</th>
|
||||||
@ -47,7 +47,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_sea542e2f5bc44b3597385ca653177f41"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_uf9be9f1548be4478ad1de55046a751cc"><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_l0e620e05220944fb92979894c176ccba">When you add a partition to a table, the table and the partition column (specified by PARTITIONED BY during table creation) must exist, and the partition to be added cannot be added repeatedly. Otherwise, an error is reported. You can use <strong id="dli_08_0081__b69978215479">IF NOT EXISTS</strong> to avoid errors if the partition does not exist.</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_l1d637f2dcd104c81bef048e0c9b11837">If tables are partitioned by multiple fields, you need to specify all partitioning fields in any sequence when adding partitions.</li><li id="dli_08_0081__en-us_topic_0114776175_li8194439172719">By default, parameters in <span class="parmname" id="dli_08_0081__en-us_topic_0114776175_parmname18832142192811"><b>partition_specs</b></span> contain parentheses (). For example: <b><span class="cmdname" id="dli_08_0081__en-us_topic_0114776175_cmdname1398714673114">PARTITION (dt='2009-09-09',city='xxx')</span></b>.</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_l0528cb4c739e4eea95cc64549ed27882">If you need to specify an OBS path when adding a partition, the OBS path must exist. Otherwise, an error occurs.</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_li12721542184816">To add multiple partitions, you need to use spaces to separate each set of <strong id="dli_08_0081__b1526911547106">LOCATION 'obs_path'</strong> in the <strong id="dli_08_0081__b3270145416105">PARTITION partition_specs</strong>. The following is an example:<p id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_p13257154474815"><b><span class="cmdname" id="dli_08_0081__en-us_topic_0114776175_cmdname3590192635213">PARTITION partition_specs LOCATION 'obs_path' PARTITION partition_specs LOCATION 'obs_path'</span></b></p>
|
<div class="section" id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_sea542e2f5bc44b3597385ca653177f41"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_uf9be9f1548be4478ad1de55046a751cc"><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_l0e620e05220944fb92979894c176ccba">When you add a partition to a table, the table and the partition column (specified by PARTITIONED BY during table creation) must exist, and the partition to be added cannot be added repeatedly. Otherwise, an error is reported. You can use <strong id="dli_08_0081__b69978215479">IF NOT EXISTS</strong> to avoid errors if the partition does not exist.</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_l1d637f2dcd104c81bef048e0c9b11837">If tables are partitioned by multiple fields, you need to specify all partitioning fields in any sequence when adding partitions.</li><li id="dli_08_0081__en-us_topic_0114776175_li8194439172719">By default, parameters in <span class="parmname" id="dli_08_0081__en-us_topic_0114776175_parmname18832142192811"><b>partition_specs</b></span> contain parentheses (). For example: <b><span class="cmdname" id="dli_08_0081__en-us_topic_0114776175_cmdname1398714673114">PARTITION (dt='2009-09-09',city='xxx')</span></b>.</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_l0528cb4c739e4eea95cc64549ed27882">If you need to specify an OBS path when adding a partition, the OBS path must exist. Otherwise, an error occurs.</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_li12721542184816">To add multiple partitions, you need to use spaces to separate each set of <strong id="dli_08_0081__b1526911547106">LOCATION 'obs_path'</strong> in the <strong id="dli_08_0081__b3270145416105">PARTITION partition_specs</strong>. The following is an example:<p id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_p13257154474815"><b><span class="cmdname" id="dli_08_0081__en-us_topic_0114776175_cmdname3590192635213">PARTITION partition_specs LOCATION 'obs_path' PARTITION partition_specs LOCATION 'obs_path'</span></b></p>
|
||||||
</li><li id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_li1844013397416">If the path specified in the new partition contains subdirectories (or nested subdirectories), all file types and content in the subdirectories are considered partition records. Ensure that all file types and file content in the partition directory are the same as those in the table. Otherwise, an error is reported.</li></ul>
|
</li><li id="dli_08_0081__li2075591192417">If the path specified in the new partition contains subdirectories (or nested subdirectories), all file types and content in the subdirectories are considered partition records.<p id="dli_08_0081__p786171920249"><a name="dli_08_0081__li2075591192417"></a><a name="li2075591192417"></a>Ensure that all file types and file content in the partition directory are the same as those in the table. Otherwise, an error is reported.</p>
|
||||||
|
<p id="dli_08_0081__p433481317244">You can set <strong id="dli_08_0081__b6233109171217">multiLevelDirEnable</strong> to <strong id="dli_08_0081__b323312981211">true</strong> in the <strong id="dli_08_0081__b6233109101219">OPTIONS</strong> statement to query the content in the subdirectory. The default value is <strong id="dli_08_0081__b13233794129">false</strong> (Note that this configuration item is a table attribute, exercise caution when performing this operation. Hive tables do not support this configuration item.)</p>
|
||||||
|
</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_s3a0cfd3f6ee14bcea0d3dcc7f968457c"><h4 class="sectiontitle">Example</h4><ul id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_u54c3db7d34564a45ae8e7b0b842c79c6"><li id="dli_08_0081__li1755910459015">The following example shows you how to add partition data when the OBS table is partitioned by a single column.<ol id="dli_08_0081__ol197591554103919"><li id="dli_08_0081__li207591754153911">Use the DataSource syntax to create an OBS table, and partition the table by column <strong id="dli_08_0081__b102123231795">external_data</strong>. The partition data is stored in <strong id="dli_08_0081__b12171143799">obs://bucketName/datapath</strong>.<pre class="screen" id="dli_08_0081__screen10910953414">create table testobstable(id varchar(128), external_data varchar(16)) using JSON OPTIONS (path 'obs://bucketName/datapath') PARTITIONED by (external_data);</pre>
|
<div class="section" id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_s3a0cfd3f6ee14bcea0d3dcc7f968457c"><h4 class="sectiontitle">Example</h4><ul id="dli_08_0081__en-us_topic_0114776175_en-us_topic_0093946864_u54c3db7d34564a45ae8e7b0b842c79c6"><li id="dli_08_0081__li1755910459015">The following example shows you how to add partition data when the OBS table is partitioned by a single column.<ol id="dli_08_0081__ol197591554103919"><li id="dli_08_0081__li207591754153911">Use the DataSource syntax to create an OBS table, and partition the table by column <strong id="dli_08_0081__b102123231795">external_data</strong>. The partition data is stored in <strong id="dli_08_0081__b12171143799">obs://bucketName/datapath</strong>.<pre class="screen" id="dli_08_0081__screen10910953414">create table testobstable(id varchar(128), external_data varchar(16)) using JSON OPTIONS (path 'obs://bucketName/datapath') PARTITIONED by (external_data);</pre>
|
||||||
</li><li id="dli_08_0081__li154708582390">Copy the partition directory to <strong id="dli_08_0081__b482955313917">obs://bucketName/datapath</strong>. In this example, copy all files in the partition column <strong id="dli_08_0081__b19718051919">external_data=22</strong> to <strong id="dli_08_0081__b235511951911">obs://bucketName/datapath</strong>.</li><li id="dli_08_0081__li727013184013">Run the following command to add partition data:<pre class="screen" id="dli_08_0081__screen1629605173913">ALTER TABLE testobstable ADD
|
</li><li id="dli_08_0081__li154708582390">Copy the partition directory to <strong id="dli_08_0081__b482955313917">obs://bucketName/datapath</strong>. In this example, copy all files in the partition column <strong id="dli_08_0081__b19718051919">external_data=22</strong> to <strong id="dli_08_0081__b235511951911">obs://bucketName/datapath</strong>.</li><li id="dli_08_0081__li727013184013">Run the following command to add partition data:<pre class="screen" id="dli_08_0081__screen1629605173913">ALTER TABLE testobstable ADD
|
||||||
|
@ -12,10 +12,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0082__en-us_topic_0114776176_en-us_topic_0093946763_s4722556def8545d097cf905b9261c45d"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0082__ul48718578292"><li id="dli_08_0082__li4871155782917">PARTITION: a specified partition</li><li id="dli_08_0082__li1287105772917">RENAME: new name of the partition</li></ul>
|
<div class="section" id="dli_08_0082__en-us_topic_0114776176_en-us_topic_0093946763_s4722556def8545d097cf905b9261c45d"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0082__ul48718578292"><li id="dli_08_0082__li4871155782917">PARTITION: a specified partition</li><li id="dli_08_0082__li1287105772917">RENAME: new name of the partition</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="19.689999999999998%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="19.689999999999998%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="80.31%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="80.31%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0082__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -12,10 +12,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0084__en-us_topic_0114776178_en-us_topic_0093946830_sf6d5fef5144840b9a0505c02fa8b84de"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0084__ul85891167229"><li id="dli_08_0084__li145908169227">PARTITION: a specified partition</li><li id="dli_08_0084__li14590101622219">LOCATION: path of the partition</li></ul>
|
<div class="section" id="dli_08_0084__en-us_topic_0114776178_en-us_topic_0093946830_sf6d5fef5144840b9a0505c02fa8b84de"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0084__ul85891167229"><li id="dli_08_0084__li145908169227">PARTITION: a specified partition</li><li id="dli_08_0084__li14590101622219">LOCATION: path of the partition</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0084__section104123045314"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0084__section104123045314"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.490000000000002%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.490000000000002%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="81.51%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="81.51%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0084__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_s3b078ae0416f431daedad915861f3ff5"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0087__en-us_topic_0114776181_ul811024717599"><li id="dli_08_0087__en-us_topic_0114776181_li161101647175919">If the table is stored in OBS, only the metadata is deleted. The data stored on OBS is not deleted.</li><li id="dli_08_0087__en-us_topic_0114776181_li2050611231306">If the table is stored in DLI, the data and the corresponding metadata are all deleted.</li></ul>
|
<div class="section" id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_s3b078ae0416f431daedad915861f3ff5"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0087__en-us_topic_0114776181_ul811024717599"><li id="dli_08_0087__en-us_topic_0114776181_li161101647175919">If the table is stored in OBS, only the metadata is deleted. The data stored on OBS is not deleted.</li><li id="dli_08_0087__en-us_topic_0114776181_li2050611231306">If the table is stored in DLI, the data and the corresponding metadata are all deleted.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0087__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0087__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0087__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0087__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="14.05%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0087__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0087__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0087__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="14.05%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0087__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="85.95%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0087__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="85.95%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0087__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
@ -31,7 +31,7 @@
|
|||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_sda8e3ca739ac4a888fced725dd8d8ad9"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_p6527534711544">The to-be-deleted table must exist in the current database. Otherwise, an error is reported. To avoid this error, add <strong id="dli_08_0087__en-us_topic_0107972083_en-us_topic_0093946844_en-us_topic_0047959882_b27862547103314">IF EXISTS</strong> in this statement.</p>
|
<div class="section" id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_sda8e3ca739ac4a888fced725dd8d8ad9"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_p6527534711544">The to-be-deleted table must exist in the current database. Otherwise, an error is reported. To avoid this error, add <strong id="dli_08_0087__en-us_topic_0107972083_en-us_topic_0093946844_en-us_topic_0047959882_b27862547103314">IF EXISTS</strong> to this statement.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_sffc94d6bdc8a4a6bb495527f25d5934a"><h4 class="sectiontitle">Example</h4><ol id="dli_08_0087__ol1729182716206"><li id="dli_08_0087__li329102719205">Create a table. For details, see <a href="dli_08_0223.html">Creating an OBS Table</a> or <a href="dli_08_0224.html">Creating a DLI Table</a>.</li><li id="dli_08_0087__li05071772217">Run the following statement to delete table <strong id="dli_08_0087__b19110149486">test</strong> from the current database:<div class="codecoloring" codetype="Sql" id="dli_08_0087__en-us_topic_0114776181_screen6513429112218"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">DROP</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="k">IF</span><span class="w"> </span><span class="k">EXISTS</span><span class="w"> </span><span class="n">test</span><span class="p">;</span>
|
<div class="section" id="dli_08_0087__en-us_topic_0114776181_en-us_topic_0093946844_sffc94d6bdc8a4a6bb495527f25d5934a"><h4 class="sectiontitle">Example</h4><ol id="dli_08_0087__ol1729182716206"><li id="dli_08_0087__li329102719205">Create a table. For details, see <a href="dli_08_0223.html">Creating an OBS Table</a> or <a href="dli_08_0224.html">Creating a DLI Table</a>.</li><li id="dli_08_0087__li05071772217">Run the following statement to delete table <strong id="dli_08_0087__b19110149486">test</strong> from the current database:<div class="codecoloring" codetype="Sql" id="dli_08_0087__en-us_topic_0114776181_screen6513429112218"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">DROP</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="k">IF</span><span class="w"> </span><span class="k">EXISTS</span><span class="w"> </span><span class="n">test</span><span class="p">;</span>
|
||||||
</pre></div></td></tr></table></div>
|
</pre></div></td></tr></table></div>
|
||||||
|
@ -22,8 +22,8 @@
|
|||||||
<div class="note" id="dli_08_0088__note133611739151012"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="dli_08_0088__p8714966200">Models and configuration files must be stored on OBS. The path format is obs://<strong id="dli_08_0088__b145662371087">your_ak</strong>:<strong id="dli_08_0088__b1916120415814">your_sk</strong>@obs.<strong id="dli_08_0088__b145131010998">your_obs_region</strong>.xxx.com:443/<strong id="dli_08_0088__b281415249109">your_model_path</strong>. </p>
|
<div class="note" id="dli_08_0088__note133611739151012"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="dli_08_0088__p8714966200">Models and configuration files must be stored on OBS. The path format is obs://<strong id="dli_08_0088__b145662371087">your_ak</strong>:<strong id="dli_08_0088__b1916120415814">your_sk</strong>@obs.<strong id="dli_08_0088__b145131010998">your_obs_region</strong>.xxx.com:443/<strong id="dli_08_0088__b281415249109">your_model_path</strong>. </p>
|
||||||
</div></div>
|
</div></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0088__section1736923971013"><h4 class="sectiontitle">Parameter Description</h4>
|
<div class="section" id="dli_08_0088__section1736923971013"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0088__table73725392102" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0088__row137815392108"><th align="left" class="cellrowborder" valign="top" width="29.84%" id="mcps1.3.4.2.2.4.1.1"><p id="dli_08_0088__p12379339101019">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0088__table73725392102" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0088__row137815392108"><th align="left" class="cellrowborder" valign="top" width="29.84%" id="mcps1.3.4.2.2.4.1.1"><p id="dli_08_0088__p12379339101019">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="9.55%" id="mcps1.3.4.2.2.4.1.2"><p id="dli_08_0088__p1380203917101">Mandatory</p>
|
<th align="left" class="cellrowborder" valign="top" width="9.55%" id="mcps1.3.4.2.2.4.1.2"><p id="dli_08_0088__p1380203917101">Mandatory</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0090__en-us_topic_0114776184_en-us_topic_0093946872_sdf1ef8747be646598ba872d8a8c29bdb"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0090__en-us_topic_0114776184_en-us_topic_0093946872_ab0c5a0492410453b8a94875cab94396a">FROM/IN: followed by the name of a database whose tables and views will be displayed.</p>
|
<div class="section" id="dli_08_0090__en-us_topic_0114776184_en-us_topic_0093946872_sdf1ef8747be646598ba872d8a8c29bdb"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0090__en-us_topic_0114776184_en-us_topic_0093946872_ab0c5a0492410453b8a94875cab94396a">FROM/IN: followed by the name of a database whose tables and views will be displayed.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0090__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0090__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0090__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0090__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="19.009999999999998%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0090__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0090__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0090__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="19.009999999999998%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0090__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="80.99%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0090__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="80.99%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0090__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_s9c558001e33b4d8b8944912062e55a18"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_a2f6cb1494b1044e8996ab64999b6c99b">CREATE TABLE: statement for creating a table</p>
|
<div class="section" id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_s9c558001e33b4d8b8944912062e55a18"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_a2f6cb1494b1044e8996ab64999b6c99b">CREATE TABLE: statement for creating a table</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0091__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0091__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0091__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0091__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="16.66%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0091__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0091__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter</caption><thead align="left"><tr id="dli_08_0091__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="16.66%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0091__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="83.34%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0091__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="83.34%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0091__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
@ -28,12 +28,23 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_s979257e3ae34418ea153a3955b17df8d"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_a8a26c09bdfe949908dc85505e57fe208">The table specified in this statement must exist. Otherwise, an error will occur.</p>
|
<div class="section" id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_s979257e3ae34418ea153a3955b17df8d"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_a8a26c09bdfe949908dc85505e57fe208">The table specified in this statement must exist. Otherwise, an error will occur.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_s608f2998f23244758fc01a0da343ef6c"><h4 class="sectiontitle">Example</h4><ol id="dli_08_0091__ol197285493568"><li id="dli_08_0091__li329102719205">Create a table. For details, see <a href="dli_08_0223.html">Creating an OBS Table</a> or <a href="dli_08_0224.html">Creating a DLI Table</a>.</li></ol>
|
<div class="section" id="dli_08_0091__en-us_topic_0114776185_en-us_topic_0093946877_s608f2998f23244758fc01a0da343ef6c"><h4 class="sectiontitle">Example</h4><div class="p" id="dli_08_0091__p484813314916"><strong id="dli_08_0091__b155488251915">Example of Spark 2.4.5:</strong><ul id="dli_08_0091__ul1374516301097"><li id="dli_08_0091__li6745330295">Run the following command to return the statement for creating the <strong id="dli_08_0091__b28626412406">testDB01.testTable5</strong> table:<p id="dli_08_0091__p1627013512916"><strong id="dli_08_0091__b0111715810">SHOW CREATE TABLE testDB01.testTable5</strong></p>
|
||||||
<ol id="dli_08_0091__ol1848075010256"><li id="dli_08_0091__li54646910274">Run the following statement to view the statement that is used to create table <strong id="dli_08_0091__b22861017256">test</strong>: <div class="codecoloring" codetype="Sql" id="dli_08_0091__en-us_topic_0114776185_screen390422733116"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">SHOW</span><span class="w"> </span><span class="k">CREATE</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="n">test</span><span class="p">;</span>
|
</li><li id="dli_08_0091__li27455305917">Return the statement for creating the <strong id="dli_08_0091__b4486572416">test</strong> table.<pre class="screen" id="dli_08_0091__screen539717161075">createtab_stmt
|
||||||
</pre></div></td></tr></table></div>
|
CREATE TABLE `testDB01`.`testTable5`(`id` INT, `age` INT, `money` DOUBLE)
|
||||||
|
COMMENT 'test'
|
||||||
|
ROW FORMAT SERDE 'org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe'
|
||||||
|
WITH SERDEPROPERTIES (
|
||||||
|
'serialization.format' = '1'
|
||||||
|
)
|
||||||
|
STORED AS
|
||||||
|
INPUTFORMAT 'org.apache.hadoop.hive.ql.io.parquet.MapredParquetInputFormat'
|
||||||
|
OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.parquet.MapredParquetOutputFormat'
|
||||||
|
TBLPROPERTIES (
|
||||||
|
'hive.serialization.extend.nesting.levels' = 'true',
|
||||||
|
'ddlUpdateTime' = '1707202585460'
|
||||||
|
)</pre>
|
||||||
|
</li></ul>
|
||||||
</div>
|
</div>
|
||||||
</li></ol>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0092__en-us_topic_0114776186_en-us_topic_0093946966_s24b9633a2e04420a98ba6eb4c2233ffd"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0092__en-us_topic_0114776186_en-us_topic_0093946966_a5563d723dd924ec4a9a43b1836c62265">TBLPROPERTIES: This statement allows you to add a <strong id="dli_08_0092__b137032053142710">key/value</strong> property to a table.</p>
|
<div class="section" id="dli_08_0092__en-us_topic_0114776186_en-us_topic_0093946966_s24b9633a2e04420a98ba6eb4c2233ffd"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0092__en-us_topic_0114776186_en-us_topic_0093946966_a5563d723dd924ec4a9a43b1836c62265">TBLPROPERTIES: This statement allows you to add a <strong id="dli_08_0092__b137032053142710">key/value</strong> property to a table.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0092__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0092__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0092__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0092__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="15.85%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0092__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0092__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0092__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="15.85%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0092__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="84.15%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0092__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="84.15%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0092__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0093__en-us_topic_0114776187_en-us_topic_0093946896_s9efebf7e28f54c3b9f13e799dfc94846"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0093__ul321118143916"><li id="dli_08_0093__li1721241415912"> COLUMNS: columns in the current table</li><li id="dli_08_0093__li221231416916">FROM/IN: followed by the name of a database whose tables and views will be displayed. Keyword FROM is equivalent to IN. You can use either of them in a statement. </li></ul>
|
<div class="section" id="dli_08_0093__en-us_topic_0114776187_en-us_topic_0093946896_s9efebf7e28f54c3b9f13e799dfc94846"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0093__ul321118143916"><li id="dli_08_0093__li1721241415912"> COLUMNS: columns in the current table</li><li id="dli_08_0093__li221231416916">FROM/IN: followed by the name of a database whose tables and views will be displayed. Keyword FROM is equivalent to IN. You can use either of them in a statement. </li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0093__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0093__en-us_topic_0114776170_section1130610201331"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0093__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0093__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="15.83%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0093__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0093__en-us_topic_0114776170_table137579239220" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0093__en-us_topic_0114776170_row17564232219"><th align="left" class="cellrowborder" valign="top" width="15.83%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0093__en-us_topic_0114776170_p3756152318220">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="84.17%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0093__en-us_topic_0114776170_p167561023629">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="84.17%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0093__en-us_topic_0114776170_p167561023629">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -10,10 +10,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0094__en-us_topic_0114776187_en-us_topic_0093946896_s9efebf7e28f54c3b9f13e799dfc94846"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0094__ul25611253182612"><li id="dli_08_0094__li20561105322612">PARTITIONS: partitions in a specified table</li><li id="dli_08_0094__li956115392613">PARTITION: a specified partition</li></ul>
|
<div class="section" id="dli_08_0094__en-us_topic_0114776187_en-us_topic_0093946896_s9efebf7e28f54c3b9f13e799dfc94846"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0094__ul25611253182612"><li id="dli_08_0094__li20561105322612">PARTITIONS: partitions in a specified table</li><li id="dli_08_0094__li956115392613">PARTITION: a specified partition</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.990000000000002%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0094__b988552515312">Parameter</strong></p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="18.990000000000002%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0094__b988552515312">Parameter</strong></p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="81.01%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0094__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
<th align="left" class="cellrowborder" valign="top" width="81.01%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0094__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0094__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -33,8 +33,8 @@
|
|||||||
: (val1 [, val2, ...])</pre>
|
: (val1 [, val2, ...])</pre>
|
||||||
</li></ul>
|
</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_sc899843a7d8e47fc8a0afeb9b1287b4a"><h4 class="sectiontitle">Keyword</h4>
|
<div class="section" id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_sc899843a7d8e47fc8a0afeb9b1287b4a"><h4 class="sectiontitle">Keywords</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_td6f691783cf344f2a5d66ba9d71b7fa3" frame="border" border="1" rules="all"><caption><b>Table 1 </b>INSERT parameter description</caption><thead align="left"><tr id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_r2d76bd70763d404a8928220f4b186ea7"><th align="left" class="cellrowborder" valign="top" width="18.509999999999998%" id="mcps1.3.3.2.2.3.1.1"><p id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_a179ef9327ac44f1fa34c44e3924e9b91"><strong id="dli_08_0095__b1547616419194">Parameter</strong></p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_td6f691783cf344f2a5d66ba9d71b7fa3" frame="border" border="1" rules="all"><caption><b>Table 1 </b>INSERT keywords</caption><thead align="left"><tr id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_r2d76bd70763d404a8928220f4b186ea7"><th align="left" class="cellrowborder" valign="top" width="18.509999999999998%" id="mcps1.3.3.2.2.3.1.1"><p id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_a179ef9327ac44f1fa34c44e3924e9b91"><strong id="dli_08_0095__b1547616419194">Parameter</strong></p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="81.49%" id="mcps1.3.3.2.2.3.1.2"><p id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_a9e03f595a7cb429fa8d66f2743475f0d"><strong id="dli_08_0095__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
<th align="left" class="cellrowborder" valign="top" width="81.49%" id="mcps1.3.3.2.2.3.1.2"><p id="dli_08_0095__en-us_topic_0114776189_en-us_topic_0093946901_a9e03f595a7cb429fa8d66f2743475f0d"><strong id="dli_08_0095__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
||||||
</th>
|
</th>
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -3,7 +3,7 @@
|
|||||||
<h1 class="topictitle1">Temporal Functions</h1>
|
<h1 class="topictitle1">Temporal Functions</h1>
|
||||||
<div id="body1574406512517"><p id="dli_08_0097__a0afc1542d28746fc9572e1ad11e28d5d"><a href="#dli_08_0097__ta2a0e6534d354c7195ebf06580c6c081">Table 1</a> lists the time functions supported by Flink SQL.</p>
|
<div id="body1574406512517"><p id="dli_08_0097__a0afc1542d28746fc9572e1ad11e28d5d"><a href="#dli_08_0097__ta2a0e6534d354c7195ebf06580c6c081">Table 1</a> lists the time functions supported by Flink SQL.</p>
|
||||||
<div class="section" id="dli_08_0097__section565310510264"><h4 class="sectiontitle">Function Description</h4>
|
<div class="section" id="dli_08_0097__section565310510264"><h4 class="sectiontitle">Function Description</h4>
|
||||||
<div class="tablenoborder"><a name="dli_08_0097__ta2a0e6534d354c7195ebf06580c6c081"></a><a name="ta2a0e6534d354c7195ebf06580c6c081"></a><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0097__ta2a0e6534d354c7195ebf06580c6c081" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Time Function</caption><thead align="left"><tr id="dli_08_0097__r94e9c30c23dd4af3908643ddb78b35c7"><th align="left" class="cellrowborder" valign="top" width="26.732673267326735%" id="mcps1.3.2.2.2.4.1.1"><p id="dli_08_0097__af3c0a9ba4b4f47dab3c76ec63484ed7f">Function</p>
|
<div class="tablenoborder"><a name="dli_08_0097__ta2a0e6534d354c7195ebf06580c6c081"></a><a name="ta2a0e6534d354c7195ebf06580c6c081"></a><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0097__ta2a0e6534d354c7195ebf06580c6c081" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Time functions</caption><thead align="left"><tr id="dli_08_0097__r94e9c30c23dd4af3908643ddb78b35c7"><th align="left" class="cellrowborder" valign="top" width="26.732673267326735%" id="mcps1.3.2.2.2.4.1.1"><p id="dli_08_0097__af3c0a9ba4b4f47dab3c76ec63484ed7f">Function</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="13.861386138613863%" id="mcps1.3.2.2.2.4.1.2"><p id="dli_08_0097__en-us_topic_0060575890_p062042117432">Return Type</p>
|
<th align="left" class="cellrowborder" valign="top" width="13.861386138613863%" id="mcps1.3.2.2.2.4.1.2"><p id="dli_08_0097__en-us_topic_0060575890_p062042117432">Return Type</p>
|
||||||
</th>
|
</th>
|
||||||
@ -98,7 +98,7 @@
|
|||||||
<td class="cellrowborder" valign="top" width="13.861386138613863%" headers="mcps1.3.2.2.2.4.1.2 "><p id="dli_08_0097__en-us_topic_0060575890_p15111018504">TIME</p>
|
<td class="cellrowborder" valign="top" width="13.861386138613863%" headers="mcps1.3.2.2.2.4.1.2 "><p id="dli_08_0097__en-us_topic_0060575890_p15111018504">TIME</p>
|
||||||
</td>
|
</td>
|
||||||
<td class="cellrowborder" valign="top" width="59.4059405940594%" headers="mcps1.3.2.2.2.4.1.3 "><p id="dli_08_0097__en-us_topic_0060575890_p10356234429">Round a time point up to the given unit.</p>
|
<td class="cellrowborder" valign="top" width="59.4059405940594%" headers="mcps1.3.2.2.2.4.1.3 "><p id="dli_08_0097__en-us_topic_0060575890_p10356234429">Round a time point up to the given unit.</p>
|
||||||
<p id="dli_08_0097__en-us_topic_0060575890_p179131918167">For example, <strong id="dli_08_0097__b654172221">12:45:00</strong> is returned from CEIL(TIME '12:44:31' TO MINUTE).</p>
|
<p id="dli_08_0097__en-us_topic_0060575890_p179131918167">For example, <strong id="dli_08_0097__b1541853222">12:45:00</strong> is returned from CEIL(TIME '12:44:31' TO MINUTE).</p>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr id="dli_08_0097__rb8a538b23a764643bb5931adc3bcc67e"><td class="cellrowborder" valign="top" width="26.732673267326735%" headers="mcps1.3.2.2.2.4.1.1 "><p id="dli_08_0097__a1e770202a4de4926ba0c1f76ba190a28">QUARTER(date)</p>
|
<tr id="dli_08_0097__rb8a538b23a764643bb5931adc3bcc67e"><td class="cellrowborder" valign="top" width="26.732673267326735%" headers="mcps1.3.2.2.2.4.1.1 "><p id="dli_08_0097__a1e770202a4de4926ba0c1f76ba190a28">QUARTER(date)</p>
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -10,10 +10,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0100__en-us_topic_0114776175_en-us_topic_0093946864_s0c845eb1e41148d79029d4f419b4fc4f"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0100__ul85891167229"><li id="dli_08_0100__li145908169227">INPATH: path of data to be imported</li><li id="dli_08_0100__li14590101622219">OPTIONS: list of properties</li></ul>
|
<div class="section" id="dli_08_0100__en-us_topic_0114776175_en-us_topic_0093946864_s0c845eb1e41148d79029d4f419b4fc4f"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0100__ul85891167229"><li id="dli_08_0100__li145908169227">INPATH: path of data to be imported</li><li id="dli_08_0100__li14590101622219">OPTIONS: list of properties</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_se9decc2fedb94b0ea80dc860c79cd3f1"><h4 class="sectiontitle">Parameter</h4>
|
<div class="section" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_se9decc2fedb94b0ea80dc860c79cd3f1"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_td8eb9ff5337945feb0b707d81a4acc90" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_ra973c320b2524745ab259dca3a46809f"><th align="left" class="cellrowborder" valign="top" width="25.2%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_a14c009dd6ca34d2caf68bc9c24fcf82b">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_td8eb9ff5337945feb0b707d81a4acc90" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_ra973c320b2524745ab259dca3a46809f"><th align="left" class="cellrowborder" valign="top" width="25.2%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_a14c009dd6ca34d2caf68bc9c24fcf82b">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="74.8%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_abff9a2e7c9614f08973e2b8afb9d7abe">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="74.8%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_abff9a2e7c9614f08973e2b8afb9d7abe">Description</p>
|
||||||
</th>
|
</th>
|
||||||
@ -45,7 +45,7 @@
|
|||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li1283316012322"><strong id="dli_08_0100__b273320113211">DELIMITER</strong>: You can specify a separator in the import statement. The default value is <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue3976890011539"><b>,</b></span>.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p4571103843518">The configuration item is <strong id="dli_08_0100__en-us_topic_0093946741_b842352706124349">OPTIONS('DELIMITER'=',')</strong>.</p>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li1283316012322"><strong id="dli_08_0100__b273320113211">DELIMITER</strong>: You can specify a separator in the import statement. The default value is <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue3976890011539"><b>,</b></span>.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p4571103843518">The configuration item is <strong id="dli_08_0100__en-us_topic_0093946741_b842352706124349">OPTIONS('DELIMITER'=',')</strong>.</p>
|
||||||
<p id="dli_08_0100__p15161732113516">For CSV data, the following delimiters are supported:</p>
|
<p id="dli_08_0100__p15161732113516">For CSV data, the following delimiters are supported:</p>
|
||||||
<ul id="dli_08_0100__ul55224545357"><li id="dli_08_0100__li226614819353">Tab character, for example, <strong id="dli_08_0100__b6379164615506">'DELIMITER'='\t'</strong>.</li><li id="dli_08_0100__li6833163410550">Any binary character, for example, <strong id="dli_08_0100__b13277205775014">'DELIMITER'='\u0001(^A)'</strong>.</li><li id="dli_08_0100__li15171039125620">Single quotation mark ('). A single quotation mark must be enclosed in double quotation marks (" "). For example, <strong id="dli_08_0100__b196211613195110">'DELIMITER'= "'"</strong>.</li><li id="dli_08_0100__li725165103713"><strong id="dli_08_0100__b1526342895119">\001(^A)</strong> and <strong id="dli_08_0100__b8425173165116">\017(^Q)</strong> are also supported, for example, <strong id="dli_08_0100__b104993817512">'DELIMITER'='\001(^A)'</strong> and <strong id="dli_08_0100__b857517410514">'DELIMITER'='\017(^Q)'</strong>.</li></ul>
|
<ul id="dli_08_0100__ul55224545357"><li id="dli_08_0100__li226614819353">Tab character, for example, <strong id="dli_08_0100__b6379164615506">'DELIMITER'='\t'</strong>.</li><li id="dli_08_0100__li6833163410550">Any binary character, for example, <strong id="dli_08_0100__b13277205775014">'DELIMITER'='\u0001(^A)'</strong>.</li><li id="dli_08_0100__li15171039125620">Single quotation mark ('). A single quotation mark must be enclosed in double quotation marks (" "). For example, <strong id="dli_08_0100__b196211613195110">'DELIMITER'= "'"</strong>.</li><li id="dli_08_0100__li725165103713"><strong id="dli_08_0100__b1526342895119">\001(^A)</strong> and <strong id="dli_08_0100__b8425173165116">\017(^Q)</strong> are also supported, for example, <strong id="dli_08_0100__b104993817512">'DELIMITER'='\001(^A)'</strong> and <strong id="dli_08_0100__b857517410514">'DELIMITER'='\017(^Q)'</strong>.</li></ul>
|
||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li177367331481"><strong id="dli_08_0100__b15364116113214">QUOTECHAR</strong>: You can specify quotation marks in the import statement. The default value is double quotation marks (<strong id="dli_08_0100__en-us_topic_0093946741_b1517187940124617">"</strong>).<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p287017571483">The configuration item is <strong id="dli_08_0100__b1969899891">OPTIONS('QUOTECHAR'='"')</strong>.</p>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li177367331481"><strong id="dli_08_0100__b15364116113214">QUOTECHAR</strong>: You can specify quotation marks in the import statement. The default value is double quotation marks (<strong id="dli_08_0100__en-us_topic_0093946741_b1517187940124617">"</strong>).<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p287017571483">The configuration item is <strong id="dli_08_0100__b1507621517">OPTIONS('QUOTECHAR'='"')</strong>.</p>
|
||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li1185594314751"><strong id="dli_08_0100__b28581029163217">COMMENTCHAR</strong>: You can specify the comment character in the import statement. During the import operation, if a comment character is at the beginning of a row, the row is considered as a comment and will not be imported. The default value is a pound key (#).<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p3271113314753">The configuration item is <i><span class="varname" id="dli_08_0100__en-us_topic_0093946741_varname787033293193637">OPTIONS('COMMENTCHAR'='#')</span></i>.</p>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li1185594314751"><strong id="dli_08_0100__b28581029163217">COMMENTCHAR</strong>: You can specify the comment character in the import statement. During the import operation, if a comment character is at the beginning of a row, the row is considered as a comment and will not be imported. The default value is a pound key (#).<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p3271113314753">The configuration item is <i><span class="varname" id="dli_08_0100__en-us_topic_0093946741_varname787033293193637">OPTIONS('COMMENTCHAR'='#')</span></i>.</p>
|
||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li3720302214743"><strong id="dli_08_0100__en-us_topic_0093946741_b84235270612499">HEADER</strong>: Indicates whether the source file contains a header. Possible values can be <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue6525743214743"><b>true</b></span> and <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue5044598014743"><b>false</b></span>. <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue5136063814743"><b>true</b></span> indicates that the source file contains a header, and <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue5959255914743"><b>false</b></span> indicates that the source file does not contain a header. The default value is <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue1139571418125019"><b>false</b></span>. If no header exists, specify the <strong id="dli_08_0100__en-us_topic_0093946741_b842352706125033">FILEHEADER</strong> parameter in the <strong id="dli_08_0100__en-us_topic_0093946741_b842352706125036">LOAD DATA</strong> statement to add a header.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p391657814745">The configuration item is <i><span class="varname" id="dli_08_0100__en-us_topic_0093946741_varname1980173326125046">OPTIONS('HEADER'='true')</span></i>.</p>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li3720302214743"><strong id="dli_08_0100__en-us_topic_0093946741_b84235270612499">HEADER</strong>: Indicates whether the source file contains a header. Possible values can be <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue6525743214743"><b>true</b></span> and <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue5044598014743"><b>false</b></span>. <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue5136063814743"><b>true</b></span> indicates that the source file contains a header, and <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue5959255914743"><b>false</b></span> indicates that the source file does not contain a header. The default value is <span class="parmvalue" id="dli_08_0100__en-us_topic_0093946741_parmvalue1139571418125019"><b>false</b></span>. If no header exists, specify the <strong id="dli_08_0100__en-us_topic_0093946741_b842352706125033">FILEHEADER</strong> parameter in the <strong id="dli_08_0100__en-us_topic_0093946741_b842352706125036">LOAD DATA</strong> statement to add a header.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p391657814745">The configuration item is <i><span class="varname" id="dli_08_0100__en-us_topic_0093946741_varname1980173326125046">OPTIONS('HEADER'='true')</span></i>.</p>
|
||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li44070917174428"><strong id="dli_08_0100__en-us_topic_0093946741_b84235270612510">FILEHEADER</strong>: If the source file does not contain any header, add a header to the <strong id="dli_08_0100__en-us_topic_0093946741_b84235270612518">LOAD DATA</strong> statement.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p61093938174428"><i><span class="varname" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_varname12974535174428">OPTIONS('FILEHEADER'='column1,column2')</span></i></p>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li44070917174428"><strong id="dli_08_0100__en-us_topic_0093946741_b84235270612510">FILEHEADER</strong>: If the source file does not contain any header, add a header to the <strong id="dli_08_0100__en-us_topic_0093946741_b84235270612518">LOAD DATA</strong> statement.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p61093938174428"><i><span class="varname" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_varname12974535174428">OPTIONS('FILEHEADER'='column1,column2')</span></i></p>
|
||||||
@ -195,7 +195,7 @@
|
|||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li64273922174428"><strong id="dli_08_0100__en-us_topic_0093946741_b84235270618317">TIMESTAMPFORMAT</strong>: Specifies the timestamp format of a column.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p38805218174428"><i><span class="varname" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_varname13702648174428">OPTIONS('TIMESTAMPFORMAT'='timestampFormat')</span></i></p>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li64273922174428"><strong id="dli_08_0100__en-us_topic_0093946741_b84235270618317">TIMESTAMPFORMAT</strong>: Specifies the timestamp format of a column.<p id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_p38805218174428"><i><span class="varname" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_varname13702648174428">OPTIONS('TIMESTAMPFORMAT'='timestampFormat')</span></i></p>
|
||||||
<div class="note" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_note56214971174428"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_ul13258146114112"><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li62584469419">Default value: yyyy-MM-dd HH:mm:ss.</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li1925815464416">The timestamp format is specified by the Java time pattern character string. For details, see <a href="#dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_table489265920252">Table 3 Definition of date and time pattern characters</a>.</li></ul>
|
<div class="note" id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_note56214971174428"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_ul13258146114112"><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li62584469419">Default value: yyyy-MM-dd HH:mm:ss.</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li1925815464416">The timestamp format is specified by the Java time pattern string. For details, see <a href="#dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_table489265920252">Table 3</a>.</li></ul>
|
||||||
</div></div>
|
</div></div>
|
||||||
</li></ul>
|
</li></ul>
|
||||||
</div>
|
</div>
|
||||||
@ -216,7 +216,7 @@
|
|||||||
</pre></div></td></tr></table></div>
|
</pre></div></td></tr></table></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li8270135219163">To import a JSON file to a DLI table named <span class="parmname" id="dli_08_0100__parmname456265865117"><b>jsontb</b></span>, run the following statement:<div class="codecoloring" codetype="Sql" id="dli_08_0100__en-us_topic_0114776194_screen1325214396619"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
</li><li id="dli_08_0100__en-us_topic_0114776194_en-us_topic_0093946741_li8270135219163">To import a JSON file to a DLI table named <span class="parmname" id="dli_08_0100__parmname456265865117"><b>jsontb</b></span>, run the following statement:<div class="codecoloring" codetype="Sql" id="dli_08_0100__screen32607464581"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
||||||
<span class="normal">2</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">LOAD</span><span class="w"> </span><span class="k">DATA</span><span class="w"> </span><span class="n">INPATH</span><span class="w"> </span><span class="s1">'obs://dli/alltype.json'</span><span class="w"> </span><span class="k">into</span><span class="w"> </span><span class="k">table</span><span class="w"> </span><span class="n">jsontb</span>
|
<span class="normal">2</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">LOAD</span><span class="w"> </span><span class="k">DATA</span><span class="w"> </span><span class="n">INPATH</span><span class="w"> </span><span class="s1">'obs://dli/alltype.json'</span><span class="w"> </span><span class="k">into</span><span class="w"> </span><span class="k">table</span><span class="w"> </span><span class="n">jsontb</span>
|
||||||
<span class="w"> </span><span class="k">OPTIONS</span><span class="p">(</span><span class="s1">'DATA_TYPE'</span><span class="o">=</span><span class="s1">'json'</span><span class="p">,</span><span class="s1">'DATEFORMAT'</span><span class="o">=</span><span class="s1">'yyyy/MM/dd'</span><span class="p">,</span><span class="s1">'TIMESTAMPFORMAT'</span><span class="o">=</span><span class="s1">'yyyy/MM/dd HH:mm:ss'</span><span class="p">);</span>
|
<span class="w"> </span><span class="k">OPTIONS</span><span class="p">(</span><span class="s1">'DATA_TYPE'</span><span class="o">=</span><span class="s1">'json'</span><span class="p">,</span><span class="s1">'DATEFORMAT'</span><span class="o">=</span><span class="s1">'yyyy/MM/dd'</span><span class="p">,</span><span class="s1">'TIMESTAMPFORMAT'</span><span class="o">=</span><span class="s1">'yyyy/MM/dd HH:mm:ss'</span><span class="p">);</span>
|
||||||
</pre></div></td></tr></table></div>
|
</pre></div></td></tr></table></div>
|
||||||
|
@ -82,7 +82,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0102__section1552562233413"><h4 class="sectiontitle">Column-Based GROUP BY</h4><p id="dli_08_0102__p369464311342"><strong id="dli_08_0102__b1221347168">Function</strong></p>
|
<div class="section" id="dli_08_0102__section1552562233413"><h4 class="sectiontitle">Column-Based GROUP BY</h4><p id="dli_08_0102__p369464311342"><strong id="dli_08_0102__b1082306238">Function</strong></p>
|
||||||
<p id="dli_08_0102__p91753268819">This statement is used to group a table based on columns.</p>
|
<p id="dli_08_0102__p91753268819">This statement is used to group a table based on columns.</p>
|
||||||
<p id="dli_08_0102__p9672194315344"><strong id="dli_08_0102__b128923562711">Syntax</strong></p>
|
<p id="dli_08_0102__p9672194315344"><strong id="dli_08_0102__b128923562711">Syntax</strong></p>
|
||||||
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen1831832732318"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen1831832732318"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
||||||
@ -109,7 +109,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0102__section089215140352"><h4 class="sectiontitle">Expression-Based GROUP BY</h4><p id="dli_08_0102__p6742184610351"><strong id="dli_08_0102__b291864736">Function</strong></p>
|
<div class="section" id="dli_08_0102__section089215140352"><h4 class="sectiontitle">Expression-Based GROUP BY</h4><p id="dli_08_0102__p6742184610351"><strong id="dli_08_0102__b459145750">Function</strong></p>
|
||||||
<p id="dli_08_0102__en-us_topic_0060751163_p6514875129">This statement is used to group a table according to expressions.</p>
|
<p id="dli_08_0102__en-us_topic_0060751163_p6514875129">This statement is used to group a table according to expressions.</p>
|
||||||
<p id="dli_08_0102__p072815469357"><strong id="dli_08_0102__b779135172716">Syntax</strong></p>
|
<p id="dli_08_0102__p072815469357"><strong id="dli_08_0102__b779135172716">Syntax</strong></p>
|
||||||
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen12422155013254"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen12422155013254"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
||||||
@ -127,7 +127,7 @@
|
|||||||
<p id="dli_08_0102__p86931946123511"><strong id="dli_08_0102__b1798045602719">Precautions</strong></p>
|
<p id="dli_08_0102__p86931946123511"><strong id="dli_08_0102__b1798045602719">Precautions</strong></p>
|
||||||
<p id="dli_08_0102__a91daaa34424f42e4b0726d29fed00f44">None</p>
|
<p id="dli_08_0102__a91daaa34424f42e4b0726d29fed00f44">None</p>
|
||||||
<p id="dli_08_0102__p1867820461354"><strong id="dli_08_0102__b788355814270">Example</strong></p>
|
<p id="dli_08_0102__p1867820461354"><strong id="dli_08_0102__b788355814270">Example</strong></p>
|
||||||
<p id="dli_08_0102__p771710344143">Use the substring function to obtain the character string from the name field, group the <strong id="dli_08_0102__b84235270694149">student</strong> table according to the obtained character string, and return each sub character string and the number of records.</p>
|
<p id="dli_08_0102__p771710344143">Use the substring function to obtain the string from the name field, group the <strong id="dli_08_0102__b84235270694149">student</strong> table according to the obtained string, and return each sub string and the number of records.</p>
|
||||||
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen428513454147"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen428513454147"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
||||||
<span class="normal">2</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">insert</span><span class="w"> </span><span class="k">into</span><span class="w"> </span><span class="n">temp</span><span class="w"> </span><span class="k">SELECT</span><span class="w"> </span><span class="k">substring</span><span class="p">(</span><span class="n">name</span><span class="p">,</span><span class="mi">6</span><span class="p">),</span><span class="k">count</span><span class="p">(</span><span class="n">name</span><span class="p">)</span><span class="w"> </span><span class="k">FROM</span><span class="w"> </span><span class="n">student</span>
|
<span class="normal">2</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">insert</span><span class="w"> </span><span class="k">into</span><span class="w"> </span><span class="n">temp</span><span class="w"> </span><span class="k">SELECT</span><span class="w"> </span><span class="k">substring</span><span class="p">(</span><span class="n">name</span><span class="p">,</span><span class="mi">6</span><span class="p">),</span><span class="k">count</span><span class="p">(</span><span class="n">name</span><span class="p">)</span><span class="w"> </span><span class="k">FROM</span><span class="w"> </span><span class="n">student</span>
|
||||||
<span class="w"> </span><span class="k">GROUP</span><span class="w"> </span><span class="k">BY</span><span class="w"> </span><span class="k">substring</span><span class="p">(</span><span class="n">name</span><span class="p">,</span><span class="mi">6</span><span class="p">);</span>
|
<span class="w"> </span><span class="k">GROUP</span><span class="w"> </span><span class="k">BY</span><span class="w"> </span><span class="k">substring</span><span class="p">(</span><span class="n">name</span><span class="p">,</span><span class="mi">6</span><span class="p">);</span>
|
||||||
@ -135,7 +135,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0102__section95261910301"><h4 class="sectiontitle">GROUP BY Using HAVING</h4><p id="dli_08_0102__p107501752371"><strong id="dli_08_0102__b659966651">Function</strong></p>
|
<div class="section" id="dli_08_0102__section95261910301"><h4 class="sectiontitle">GROUP BY Using HAVING</h4><p id="dli_08_0102__p107501752371"><strong id="dli_08_0102__b1574794912">Function</strong></p>
|
||||||
<p id="dli_08_0102__p158591320161518">This statement filters a table after grouping it using the HAVING clause.</p>
|
<p id="dli_08_0102__p158591320161518">This statement filters a table after grouping it using the HAVING clause.</p>
|
||||||
<p id="dli_08_0102__p173115518376"><strong id="dli_08_0102__b69626552815">Syntax</strong></p>
|
<p id="dli_08_0102__p173115518376"><strong id="dli_08_0102__b69626552815">Syntax</strong></p>
|
||||||
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen836920534261"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
<div class="codecoloring" codetype="Sql" id="dli_08_0102__screen836920534261"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
|86 |</pre>
|
|86 |</pre>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0104__section4555121514374"><h4 class="sectiontitle">Common Aggregate Functions</h4>
|
<div class="section" id="dli_08_0104__section4555121514374"><h4 class="sectiontitle">Common Aggregate Functions</h4>
|
||||||
<div class="tablenoborder"><a name="dli_08_0104__tb90f8c1797b346ca8ac5fcb1eb5d85df"></a><a name="tb90f8c1797b346ca8ac5fcb1eb5d85df"></a><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0104__tb90f8c1797b346ca8ac5fcb1eb5d85df" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Common aggregation functions</caption><thead align="left"><tr id="dli_08_0104__r5790c1fe376b4ab2ace8344bdb73e92d"><th align="left" class="cellrowborder" valign="top" width="24.59%" id="mcps1.3.3.2.2.4.1.1"><p id="dli_08_0104__a0fa16f0341ac40e5ae8eb21eb74d88d1">Function</p>
|
<div class="tablenoborder"><a name="dli_08_0104__tb90f8c1797b346ca8ac5fcb1eb5d85df"></a><a name="tb90f8c1797b346ca8ac5fcb1eb5d85df"></a><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0104__tb90f8c1797b346ca8ac5fcb1eb5d85df" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Common aggregate functions</caption><thead align="left"><tr id="dli_08_0104__r5790c1fe376b4ab2ace8344bdb73e92d"><th align="left" class="cellrowborder" valign="top" width="24.59%" id="mcps1.3.3.2.2.4.1.1"><p id="dli_08_0104__a0fa16f0341ac40e5ae8eb21eb74d88d1">Function</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="21.19%" id="mcps1.3.3.2.2.4.1.2"><p id="dli_08_0104__aadc2da9326bd497b9122194dd10dd3d7">Return Data Type</p>
|
<th align="left" class="cellrowborder" valign="top" width="21.19%" id="mcps1.3.3.2.2.4.1.2"><p id="dli_08_0104__aadc2da9326bd497b9122194dd10dd3d7">Return Data Type</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -8,10 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_s85a6f8f752b14c12908d2303d618d510"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_u6276390c1d994411a3ade99c0da8c0c0"><li id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_lf20ccaa3b133495591e692c43a7287d9">EXTENDED: displays all metadata of the specified table. It is used during debugging in general.</li><li id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_lae91afc5a5e84024951de4cb76ee67c9">FORMATTED: displays all metadata of the specified table in a form.</li></ul>
|
<div class="section" id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_s85a6f8f752b14c12908d2303d618d510"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_u6276390c1d994411a3ade99c0da8c0c0"><li id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_lf20ccaa3b133495591e692c43a7287d9">EXTENDED: displays all metadata of the specified table. It is used during debugging in general.</li><li id="dli_08_0105__en-us_topic_0114776199_en-us_topic_0107972084_en-us_topic_0093946811_lae91afc5a5e84024951de4cb76ee67c9">FORMATTED: displays all metadata of the specified table in a form.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
<div class="section" id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0093946905_s95436b2cebbc4c34b0e6ca8427d4f1d9"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="14.26%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="14.26%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_a9dd69379a3f54904a9c510fb817659ad">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="85.74000000000001%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
<th align="left" class="cellrowborder" valign="top" width="85.74000000000001%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0105__en-us_topic_0114776188_en-us_topic_0103084433_a7ede0d62539542baa7e367cf902bf2b2">Description</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
<ul id="dli_08_0108__ul99601519161917"><li id="dli_08_0108__li11960151971915">Logically partition and order the data that is used in the MATCH_RECOGNIZE clause with its PARTITION BY and ORDER BY clauses.</li><li id="dli_08_0108__li196061921916">Define patterns of rows to seek using the PATTERN clause of the MATCH_RECOGNIZE clause. These patterns use regular expression syntax.</li><li id="dli_08_0108__li9960111915192">Specify the logical conditions required to map a row to a row pattern variable in the DEFINE clause.</li><li id="dli_08_0108__li1396010191194">Define measures, which are expressions usable in other parts of the SQL query, in the MEASURES clause.</li></ul>
|
<ul id="dli_08_0108__ul99601519161917"><li id="dli_08_0108__li11960151971915">Logically partition and order the data that is used in the MATCH_RECOGNIZE clause with its PARTITION BY and ORDER BY clauses.</li><li id="dli_08_0108__li196061921916">Define patterns of rows to seek using the PATTERN clause of the MATCH_RECOGNIZE clause. These patterns use regular expression syntax.</li><li id="dli_08_0108__li9960111915192">Specify the logical conditions required to map a row to a row pattern variable in the DEFINE clause.</li><li id="dli_08_0108__li1396010191194">Define measures, which are expressions usable in other parts of the SQL query, in the MEASURES clause.</li></ul>
|
||||||
</div></div>
|
</div></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0108__section1032282412160"><h4 class="sectiontitle">Syntax description</h4>
|
<div class="section" id="dli_08_0108__section1032282412160"><h4 class="sectiontitle">Syntax Description</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0108__table2060911914818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Syntax description</caption><thead align="left"><tr id="dli_08_0108__row1960910913480"><th align="left" class="cellrowborder" valign="top" width="27.272727272727277%" id="mcps1.3.4.2.2.4.1.1"><p id="dli_08_0108__p176092984816">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0108__table2060911914818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Syntax description</caption><thead align="left"><tr id="dli_08_0108__row1960910913480"><th align="left" class="cellrowborder" valign="top" width="27.272727272727277%" id="mcps1.3.4.2.2.4.1.1"><p id="dli_08_0108__p176092984816">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="12.121212121212121%" id="mcps1.3.4.2.2.4.1.2"><p id="dli_08_0108__p03846300421">Mandatory</p>
|
<th align="left" class="cellrowborder" valign="top" width="12.121212121212121%" id="mcps1.3.4.2.2.4.1.2"><p id="dli_08_0108__p03846300421">Mandatory</p>
|
||||||
|
@ -11,8 +11,8 @@
|
|||||||
<div class="note" id="dli_08_0110__note696020431233"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="dli_08_0110__ul99601519161917"><li id="dli_08_0110__li11960151971915">The anomaly score returned by the function is a DOUBLE value in the range of [0, 1].</li><li id="dli_08_0110__li196061921916">The field names must be of the same type. If the field types are different, you can use the CAST function to escape the field names, for example, [a, CAST(b as DOUBLE)].</li><li id="dli_08_0110__li9960111915192">The syntax of the optional parameter list is as follows: "key1=value,key2=value2,..."</li></ul>
|
<div class="note" id="dli_08_0110__note696020431233"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="dli_08_0110__ul99601519161917"><li id="dli_08_0110__li11960151971915">The anomaly score returned by the function is a DOUBLE value in the range of [0, 1].</li><li id="dli_08_0110__li196061921916">The field names must be of the same type. If the field types are different, you can use the CAST function to escape the field names, for example, [a, CAST(b as DOUBLE)].</li><li id="dli_08_0110__li9960111915192">The syntax of the optional parameter list is as follows: "key1=value,key2=value2,..."</li></ul>
|
||||||
</div></div>
|
</div></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0110__section1032282412160"><h4 class="sectiontitle">Parameter Description</h4>
|
<div class="section" id="dli_08_0110__section1032282412160"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0110__table2060911914818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter Description</caption><thead align="left"><tr id="dli_08_0110__row1960910913480"><th align="left" class="cellrowborder" valign="top" width="25.22%" id="mcps1.3.5.2.2.5.1.1"><p id="dli_08_0110__p176092984816">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0110__table2060911914818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0110__row1960910913480"><th align="left" class="cellrowborder" valign="top" width="25.22%" id="mcps1.3.5.2.2.5.1.1"><p id="dli_08_0110__p176092984816">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="11.21%" id="mcps1.3.5.2.2.5.1.2"><p id="dli_08_0110__p03846300421">Mandatory</p>
|
<th align="left" class="cellrowborder" valign="top" width="11.21%" id="mcps1.3.5.2.2.5.1.2"><p id="dli_08_0110__p03846300421">Mandatory</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0111__table2060911914818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter Description</caption><thead align="left"><tr id="dli_08_0111__row1960910913480"><th align="left" class="cellrowborder" valign="top" width="18.14%" id="mcps1.3.6.2.5.1.1"><p id="dli_08_0111__p176092984816">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0111__table2060911914818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0111__row1960910913480"><th align="left" class="cellrowborder" valign="top" width="18.14%" id="mcps1.3.6.2.5.1.1"><p id="dli_08_0111__p176092984816">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="11.59%" id="mcps1.3.6.2.5.1.2"><p id="dli_08_0111__p03846300421">Mandatory</p>
|
<th align="left" class="cellrowborder" valign="top" width="11.59%" id="mcps1.3.6.2.5.1.2"><p id="dli_08_0111__p03846300421">Mandatory</p>
|
||||||
</th>
|
</th>
|
||||||
@ -82,7 +82,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0111__table1261014401323" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameter Description</caption><thead align="left"><tr id="dli_08_0111__row56141740183213"><th align="left" class="cellrowborder" valign="top" width="19.63%" id="mcps1.3.13.2.4.1.1"><p id="dli_08_0111__p146141940103218">Parameter</p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0111__table1261014401323" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameters</caption><thead align="left"><tr id="dli_08_0111__row56141740183213"><th align="left" class="cellrowborder" valign="top" width="19.63%" id="mcps1.3.13.2.4.1.1"><p id="dli_08_0111__p146141940103218">Parameter</p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="13.94%" id="mcps1.3.13.2.4.1.2"><p id="dli_08_0111__p761710407322">Mandatory</p>
|
<th align="left" class="cellrowborder" valign="top" width="13.94%" id="mcps1.3.13.2.4.1.2"><p id="dli_08_0111__p761710407322">Mandatory</p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0112__section162182672816"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0112__ul9129922125211"><li id="dli_08_0112__li91296223521">If the input is <strong id="dli_08_0112__b11255142516">NULL</strong>, <strong id="dli_08_0112__b61251514750">NULL</strong> is returned.</li><li id="dli_08_0112__li17129132245218">Flink jobs do not support the conversion of <strong id="dli_08_0112__b34510111973">bigint</strong> to <strong id="dli_08_0112__b1150171114717">timestamp</strong> using CAST. You can convert it using <strong id="dli_08_0112__b1951011976">to_timestamp</strong> or <strong id="dli_08_0112__b1511311775">to_localtimestamp</strong>.</li></ul>
|
<div class="section" id="dli_08_0112__section162182672816"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0112__ul9129922125211"><li id="dli_08_0112__li91296223521">If the input is <strong id="dli_08_0112__b11255142516">NULL</strong>, <strong id="dli_08_0112__b61251514750">NULL</strong> is returned.</li><li id="dli_08_0112__li17129132245218">Flink jobs do not support the conversion of <strong id="dli_08_0112__b34510111973">bigint</strong> to <strong id="dli_08_0112__b1150171114717">timestamp</strong> using CAST. You can convert it using <strong id="dli_08_0112__b1951011976">to_timestamp</strong> or <strong id="dli_08_0112__b1511311775">to_localtimestamp</strong>.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0112__section6708122502812"><h4 class="sectiontitle">Example</h4><p id="dli_08_0112__a3e8ecbf3e3934ed1b04601e1689e0518">Convert amount into a character string. The specified length of the string is invalid after the conversion.</p>
|
<div class="section" id="dli_08_0112__section6708122502812"><h4 class="sectiontitle">Example</h4><p id="dli_08_0112__a3e8ecbf3e3934ed1b04601e1689e0518">Convert amount into a string. The specified length of the string is invalid after the conversion.</p>
|
||||||
<pre class="screen" id="dli_08_0112__s41c7e3601df241b281c5c3557d53415c">insert into temp select cast(amount as VARCHAR(10)) from source_stream;</pre>
|
<pre class="screen" id="dli_08_0112__s41c7e3601df241b281c5c3557d53415c">insert into temp select cast(amount as VARCHAR(10)) from source_stream;</pre>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0112__section7391848483"><h4 class="sectiontitle">Common Type Conversion Functions</h4>
|
<div class="section" id="dli_08_0112__section7391848483"><h4 class="sectiontitle">Common Type Conversion Functions</h4>
|
||||||
|
@ -2,6 +2,8 @@
|
|||||||
|
|
||||||
<h1 class="topictitle1">Creating a DLI Table and Associating It with HBase</h1>
|
<h1 class="topictitle1">Creating a DLI Table and Associating It with HBase</h1>
|
||||||
<div id="body1578361312449"><div class="section" id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_section540354616207"><h4 class="sectiontitle">Function</h4><p id="dli_08_0119__p1975691442613">This statement is used to create a DLI table and associate it with an existing HBase table.</p>
|
<div id="body1578361312449"><div class="section" id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_section540354616207"><h4 class="sectiontitle">Function</h4><p id="dli_08_0119__p1975691442613">This statement is used to create a DLI table and associate it with an existing HBase table.</p>
|
||||||
|
<div class="note" id="dli_08_0119__note443995614391"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="dli_08_0119__p964618104214">In Spark cross-source development scenarios, there is a risk of password leakage if datasource authentication information is directly configured. You are advised to use the datasource authentication provided by DLI.</p>
|
||||||
|
</div></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0119__section39181250184618"><h4 class="sectiontitle">Prerequisites</h4><ul id="dli_08_0119__ul69152143393"><li id="dli_08_0119__li11915161413391">Before creating a DLI table and associating it with HBase, you need to create a datasource connection. For details about operations on the management console, see </li><li id="dli_08_0119__li1933716181390">Ensure that the <span class="filepath" id="dli_08_0119__filepath6456182155610"><b>/etc/hosts</b></span> information of the master node in the MRS cluster is added to the host file of the DLI queue.<p id="dli_08_0119__en-us_topic_0154786456_p12685121631310">For details about how to add an IP-domain mapping, see <span class="filepath" id="dli_08_0119__filepath284011482319"><b>Enhanced Datasource Connection</b></span> in the <i><cite id="dli_08_0119__cite128401648183117">Data Lake Insight User Guide</cite></i>.</p>
|
<div class="section" id="dli_08_0119__section39181250184618"><h4 class="sectiontitle">Prerequisites</h4><ul id="dli_08_0119__ul69152143393"><li id="dli_08_0119__li11915161413391">Before creating a DLI table and associating it with HBase, you need to create a datasource connection. For details about operations on the management console, see </li><li id="dli_08_0119__li1933716181390">Ensure that the <span class="filepath" id="dli_08_0119__filepath6456182155610"><b>/etc/hosts</b></span> information of the master node in the MRS cluster is added to the host file of the DLI queue.<p id="dli_08_0119__en-us_topic_0154786456_p12685121631310">For details about how to add an IP-domain mapping, see <span class="filepath" id="dli_08_0119__filepath284011482319"><b>Enhanced Datasource Connection</b></span> in the <i><cite id="dli_08_0119__cite128401648183117">Data Lake Insight User Guide</cite></i>.</p>
|
||||||
</li><li id="dli_08_0119__li1012445583810">The syntax is not supported for security clusters.</li></ul>
|
</li><li id="dli_08_0119__li1012445583810">The syntax is not supported for security clusters.</li></ul>
|
||||||
@ -48,8 +50,8 @@
|
|||||||
</div>
|
</div>
|
||||||
</li></ul>
|
</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_section784510261216"><h4 class="sectiontitle">Keyword</h4>
|
<div class="section" id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_section784510261216"><h4 class="sectiontitle">Keywords</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>CREATE TABLE parameter description</caption><thead align="left"><tr id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="14.2%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0119__b1435411214333">Parameter</strong></p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>CREATE TABLE keywords</caption><thead align="left"><tr id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="14.2%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0119__b1435411214333">Parameter</strong></p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="85.8%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0119__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
<th align="left" class="cellrowborder" valign="top" width="85.8%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0119__en-us_topic_0114776213_en-us_topic_0103157088_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0119__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -29,8 +29,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0120__section424017521158"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0120__p15750175919519">For details about the SELECT keywords, see <a href="dli_08_0150.html">Basic SELECT Statements</a>.</p>
|
<div class="section" id="dli_08_0120__section424017521158"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0120__p15750175919519">For details about the SELECT keywords, see <a href="dli_08_0150.html">Basic SELECT Statements</a>.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_section784510261216"><h4 class="sectiontitle">Parameter description</h4>
|
<div class="section" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_section784510261216"><h4 class="sectiontitle">Parameters</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0120__b69811114103515">Parameter</strong></p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0120__b69811114103515">Parameter</strong></p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="70%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0120__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
<th align="left" class="cellrowborder" valign="top" width="70%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0120__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
||||||
</th>
|
</th>
|
||||||
@ -70,7 +70,7 @@
|
|||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_section1856617202225"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_ul23381406122620"><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li187754494822">The target DLI table must exist.</li><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li5303504921140">In the column family created in <a href="dli_08_0119.html">Creating a Table and Associating It with HBase</a>, if the column family specified by <strong id="dli_08_0120__en-us_topic_0103157089_b842352706185718">Cols</strong> in <strong id="dli_08_0120__en-us_topic_0103157089_b842352706185721">OPTIONS</strong> does not exist, an error is reported when <strong id="dli_08_0120__en-us_topic_0103157089_b84235270618582">INSERT INTO</strong> is executed.</li><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li33929945211448">If the row key, column family, or column you need to insert to the HBase table already exists, the existing data in HBase table will be overwritten.</li><li id="dli_08_0120__en-us_topic_0114776214_li5174816161">You are advised not to concurrently insert data into a table. If you concurrently insert data into a table, there is a possibility that conflicts occur, leading to failed data insertion.</li><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li38633385211535"><strong id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_b842352706185920">INSERT OVERWRITE</strong> is not supported.</li></ul>
|
<div class="section" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_section1856617202225"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_ul23381406122620"><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li187754494822">A DLI table is available.</li><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li5303504921140">In the column family created in <a href="dli_08_0119.html">Creating a Table and Associating It with HBase</a>, if the column family specified by <strong id="dli_08_0120__en-us_topic_0103157089_b842352706185718">Cols</strong> in <strong id="dli_08_0120__en-us_topic_0103157089_b842352706185721">OPTIONS</strong> does not exist, an error is reported when <strong id="dli_08_0120__en-us_topic_0103157089_b84235270618582">INSERT INTO</strong> is executed.</li><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li33929945211448">If the row key, column family, or column you need to insert to the HBase table already exists, the existing data in HBase table will be overwritten.</li><li id="dli_08_0120__en-us_topic_0114776214_li5174816161">You are advised not to concurrently insert data into a table. If you concurrently insert data into a table, there is a possibility that conflicts occur, leading to failed data insertion.</li><li id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_li38633385211535"><strong id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_b842352706185920">INSERT OVERWRITE</strong> is not supported.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_section9892337112213"><h4 class="sectiontitle">Example</h4><ul id="dli_08_0120__ul20442191165319"><li id="dli_08_0120__li124425145316">Query data in the user table and insert the data into the test table.<div class="codecoloring" codetype="Sql" id="dli_08_0120__en-us_topic_0114776214_screen98501428162"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
<div class="section" id="dli_08_0120__en-us_topic_0114776214_en-us_topic_0103157089_section9892337112213"><h4 class="sectiontitle">Example</h4><ul id="dli_08_0120__ul20442191165319"><li id="dli_08_0120__li124425145316">Query data in the user table and insert the data into the test table.<div class="codecoloring" codetype="Sql" id="dli_08_0120__en-us_topic_0114776214_screen98501428162"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
|
||||||
<span class="normal">2</span>
|
<span class="normal">2</span>
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0121__en-us_topic_0114776215_en-us_topic_0114689142_s022cdf3e3b794ef6ab379c57a6312479"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0121__en-us_topic_0114776215_en-us_topic_0114689142_p33843242274">LIMIT is used to limit the query results. Only INT type is supported by the <strong id="dli_08_0121__en-us_topic_0093946751_b842352706163741">number</strong> parameter.</p>
|
<div class="section" id="dli_08_0121__en-us_topic_0114776215_en-us_topic_0114689142_s022cdf3e3b794ef6ab379c57a6312479"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0121__en-us_topic_0114776215_en-us_topic_0114689142_p33843242274">LIMIT is used to limit the query results. Only INT type is supported by the <strong id="dli_08_0121__en-us_topic_0093946751_b842352706163741">number</strong> parameter.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0121__en-us_topic_0114776215_en-us_topic_0114689142_sd02019d1afd4479d811d4fc5cb2be648"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0121__en-us_topic_0114776215_p10675164612358">The table to be queried must exist. Otherwise, an error is reported.</p>
|
<div class="section" id="dli_08_0121__en-us_topic_0114776215_en-us_topic_0114689142_sd02019d1afd4479d811d4fc5cb2be648"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0121__en-us_topic_0114776215_p10675164612358">The table to be queried must exist. Otherwise, an error is reported.</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -18,8 +18,8 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_section784510261216"><h4 class="sectiontitle">Keyword</h4>
|
<div class="section" id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_section784510261216"><h4 class="sectiontitle">Keywords</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>CREATE TABLE parameter description</caption><thead align="left"><tr id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="17.93%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0122__b56012065371">Parameter</strong></p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>CREATE TABLE keywords</caption><thead align="left"><tr id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="17.93%" id="mcps1.3.4.2.2.3.1.1"><p id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0122__b56012065371">Parameter</strong></p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="82.07%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0122__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
<th align="left" class="cellrowborder" valign="top" width="82.07%" id="mcps1.3.4.2.2.3.1.2"><p id="dli_08_0122__en-us_topic_0114776216_en-us_topic_0111165158_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0122__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -14,8 +14,8 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_section784510261216"><h4 class="sectiontitle">Keyword</h4>
|
<div class="section" id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_section784510261216"><h4 class="sectiontitle">Keywords</h4>
|
||||||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>INSERT INTO parameter description</caption><thead align="left"><tr id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.3.2.2.3.1.1"><p id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0123__b18396231164711">Parameter</strong></p>
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_t2fa8597e0dde4884bd6412ac207ebea8" frame="border" border="1" rules="all"><caption><b>Table 1 </b>INSERT INTO keywords</caption><thead align="left"><tr id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_r16c75fd8fdbf41c79f9aee82b032351c"><th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.3.2.2.3.1.1"><p id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_a9dd69379a3f54904a9c510fb817659ad"><strong id="dli_08_0123__b18396231164711">Parameter</strong></p>
|
||||||
</th>
|
</th>
|
||||||
<th align="left" class="cellrowborder" valign="top" width="70%" id="mcps1.3.3.2.2.3.1.2"><p id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0123__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
<th align="left" class="cellrowborder" valign="top" width="70%" id="mcps1.3.3.2.2.3.1.2"><p id="dli_08_0123__en-us_topic_0114776217_en-us_topic_0111165159_a7ede0d62539542baa7e367cf902bf2b2"><strong id="dli_08_0123__en-us_topic_0093946771_en-us_topic_0053447306_en-us_topic_0039551470_b6335010717346">Description</strong></p>
|
||||||
</th>
|
</th>
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_s022cdf3e3b794ef6ab379c57a6312479"><h4 class="sectiontitle">Keyword</h4><p id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_p33843242274">LIMIT is used to limit the query results. Only INT type is supported by the <strong id="dli_08_0124__en-us_topic_0093946751_b842352706163741">number</strong> parameter.</p>
|
<div class="section" id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_s022cdf3e3b794ef6ab379c57a6312479"><h4 class="sectiontitle">Keywords</h4><p id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_p33843242274">LIMIT is used to limit the query results. Only INT type is supported by the <strong id="dli_08_0124__en-us_topic_0093946751_b842352706163741">number</strong> parameter.</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_sd02019d1afd4479d811d4fc5cb2be648"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_p142454394292">The table to be queried must exist. Otherwise, an error is reported.</p>
|
<div class="section" id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_sd02019d1afd4479d811d4fc5cb2be648"><h4 class="sectiontitle">Precautions</h4><p id="dli_08_0124__en-us_topic_0114776218_en-us_topic_0114689143_p142454394292">The table to be queried must exist. Otherwise, an error is reported.</p>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<a name="dli_08_0125"></a><a name="dli_08_0125"></a>
|
<a name="dli_08_0125"></a><a name="dli_08_0125"></a>
|
||||||
|
|
||||||
<h1 class="topictitle1">Reserved Keywords</h1>
|
<h1 class="topictitle1">Reserved Keywords</h1>
|
||||||
<div id="body1574406512653"><p id="dli_08_0125__a5818c61e42994ae4aba892e352e6fbcc">Flink SQL reserves some strings as keywords. If you want to use the following character strings as field names, ensure that they are enclosed by back quotes, for example, `value` and `count`.</p>
|
<div id="body1574406512653"><p id="dli_08_0125__a5818c61e42994ae4aba892e352e6fbcc">Flink SQL reserves some strings as keywords. If you want to use the following strings as field names, ensure that they are enclosed by back quotes, for example, `value` and `count`.</p>
|
||||||
<div class="section" id="dli_08_0125__section3284744114218"><h4 class="sectiontitle">A</h4><ul id="dli_08_0125__ul1371144195016"><li id="dli_08_0125__li189101429185212">A</li><li id="dli_08_0125__li16933193515210">ABS</li><li id="dli_08_0125__li1530717424520">ABSOLUTE</li><li id="dli_08_0125__li131701519121310">ACTION</li><li id="dli_08_0125__li143595569522">ADA</li><li id="dli_08_0125__li589112095311">ADD</li><li id="dli_08_0125__li2708144125318">ADMIN</li><li id="dli_08_0125__li10902226154911">AFTER</li><li id="dli_08_0125__li10371944165016">AK</li><li id="dli_08_0125__li14433102517537">ALL</li><li id="dli_08_0125__li15513162914538">ALLOCATE</li><li id="dli_08_0125__li13955115185316">ALLOW</li><li id="dli_08_0125__li16914546537">ALTER</li><li id="dli_08_0125__li355415785411">ALWAYS</li><li id="dli_08_0125__li1578771975418">AND</li><li id="dli_08_0125__li79981032195416">ANY</li><li id="dli_08_0125__li72993530567">APPEND</li><li id="dli_08_0125__li1734415469326">APP_ID</li><li id="dli_08_0125__li155618499549">ARE</li><li id="dli_08_0125__li16548531183816">ARRAY</li><li id="dli_08_0125__li9117817412">ARRAY_BRACKET</li><li id="dli_08_0125__li831835114507">AS</li><li id="dli_08_0125__li5467191319558">ASC</li><li id="dli_08_0125__li183411258551">ASENSITIVE</li><li id="dli_08_0125__li5270134011558">ASSERTION</li><li id="dli_08_0125__li18281195565519">ASSIGNMENT</li><li id="dli_08_0125__li1728815918567">ASYMMETRIC</li><li id="dli_08_0125__li7744192120564">AT</li><li id="dli_08_0125__li1780160175115">AT_LEAST_ONCE</li><li id="dli_08_0125__li10964143518568">ATOMIC</li><li id="dli_08_0125__li1435675919565">ATTRIBUTE</li><li id="dli_08_0125__li23881420145712">ATTRIBUTES</li><li id="dli_08_0125__li1186153714579">AUTHORIZATION</li><li id="dli_08_0125__li1081825765712">AVG</li><li id="dli_08_0125__li1435141511579">AVRO_CONFIG</li><li id="dli_08_0125__li10566627195716">AVRO_DATA</li><li id="dli_08_0125__li11130174915554">AVRO_SCHEMA</li></ul>
|
<div class="section" id="dli_08_0125__section3284744114218"><h4 class="sectiontitle">A</h4><ul id="dli_08_0125__ul1371144195016"><li id="dli_08_0125__li189101429185212">A</li><li id="dli_08_0125__li16933193515210">ABS</li><li id="dli_08_0125__li1530717424520">ABSOLUTE</li><li id="dli_08_0125__li131701519121310">ACTION</li><li id="dli_08_0125__li143595569522">ADA</li><li id="dli_08_0125__li589112095311">ADD</li><li id="dli_08_0125__li2708144125318">ADMIN</li><li id="dli_08_0125__li10902226154911">AFTER</li><li id="dli_08_0125__li10371944165016">AK</li><li id="dli_08_0125__li14433102517537">ALL</li><li id="dli_08_0125__li15513162914538">ALLOCATE</li><li id="dli_08_0125__li13955115185316">ALLOW</li><li id="dli_08_0125__li16914546537">ALTER</li><li id="dli_08_0125__li355415785411">ALWAYS</li><li id="dli_08_0125__li1578771975418">AND</li><li id="dli_08_0125__li79981032195416">ANY</li><li id="dli_08_0125__li72993530567">APPEND</li><li id="dli_08_0125__li1734415469326">APP_ID</li><li id="dli_08_0125__li155618499549">ARE</li><li id="dli_08_0125__li16548531183816">ARRAY</li><li id="dli_08_0125__li9117817412">ARRAY_BRACKET</li><li id="dli_08_0125__li831835114507">AS</li><li id="dli_08_0125__li5467191319558">ASC</li><li id="dli_08_0125__li183411258551">ASENSITIVE</li><li id="dli_08_0125__li5270134011558">ASSERTION</li><li id="dli_08_0125__li18281195565519">ASSIGNMENT</li><li id="dli_08_0125__li1728815918567">ASYMMETRIC</li><li id="dli_08_0125__li7744192120564">AT</li><li id="dli_08_0125__li1780160175115">AT_LEAST_ONCE</li><li id="dli_08_0125__li10964143518568">ATOMIC</li><li id="dli_08_0125__li1435675919565">ATTRIBUTE</li><li id="dli_08_0125__li23881420145712">ATTRIBUTES</li><li id="dli_08_0125__li1186153714579">AUTHORIZATION</li><li id="dli_08_0125__li1081825765712">AVG</li><li id="dli_08_0125__li1435141511579">AVRO_CONFIG</li><li id="dli_08_0125__li10566627195716">AVRO_DATA</li><li id="dli_08_0125__li11130174915554">AVRO_SCHEMA</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0125__section2580821185211"><h4 class="sectiontitle">B</h4><ul id="dli_08_0125__ul1553333311014"><li id="dli_08_0125__li17999447128">BATCH_INSERT_DATA_NUM</li><li id="dli_08_0125__li1431613194917">BEFORE</li><li id="dli_08_0125__li9959119169">BEGIN</li><li id="dli_08_0125__li655121961620">BERNOULLI</li><li id="dli_08_0125__li662012781620">BETWEEN</li><li id="dli_08_0125__li587414213411">BIGINT</li><li id="dli_08_0125__li14419115171717">BINARY</li><li id="dli_08_0125__li155182341718">BIT</li><li id="dli_08_0125__li18214153115176">BLOB</li><li id="dli_08_0125__li4439043173513">BOOL</li><li id="dli_08_0125__li119512884315">BOOLEAN</li><li id="dli_08_0125__li16223959141718">BOTH</li><li id="dli_08_0125__li076315142185">BREADTH</li><li id="dli_08_0125__li1553310332012">BUCKET</li><li id="dli_08_0125__li2928232063">BY</li></ul>
|
<div class="section" id="dli_08_0125__section2580821185211"><h4 class="sectiontitle">B</h4><ul id="dli_08_0125__ul1553333311014"><li id="dli_08_0125__li17999447128">BATCH_INSERT_DATA_NUM</li><li id="dli_08_0125__li1431613194917">BEFORE</li><li id="dli_08_0125__li9959119169">BEGIN</li><li id="dli_08_0125__li655121961620">BERNOULLI</li><li id="dli_08_0125__li662012781620">BETWEEN</li><li id="dli_08_0125__li587414213411">BIGINT</li><li id="dli_08_0125__li14419115171717">BINARY</li><li id="dli_08_0125__li155182341718">BIT</li><li id="dli_08_0125__li18214153115176">BLOB</li><li id="dli_08_0125__li4439043173513">BOOL</li><li id="dli_08_0125__li119512884315">BOOLEAN</li><li id="dli_08_0125__li16223959141718">BOTH</li><li id="dli_08_0125__li076315142185">BREADTH</li><li id="dli_08_0125__li1553310332012">BUCKET</li><li id="dli_08_0125__li2928232063">BY</li></ul>
|
||||||
|
@ -8,9 +8,10 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_se62db8684fc443979516b91a6b018a5c"><h4 class="sectiontitle">Keyword</h4><ul id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_u2a2e725d6133427f951344664b111e7c"><li id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_l89104ba744fa47ffba694fc735438ab2">CREATE VIEW: creates views based on the given select statement. The result of the select statement will not be written into the disk.</li><li id="dli_08_0130__en-us_topic_0114776224_li19351029703">OR REPLACE: updates views using the select statement. No error is reported and the view definition is updated using the SELECT statement if a view exists.</li></ul>
|
<div class="section" id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_se62db8684fc443979516b91a6b018a5c"><h4 class="sectiontitle">Keywords</h4><ul id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_u2a2e725d6133427f951344664b111e7c"><li id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_l89104ba744fa47ffba694fc735438ab2">CREATE VIEW: creates views based on the given select statement. The result of the select statement will not be written into the disk.</li><li id="dli_08_0130__en-us_topic_0114776224_li19351029703">OR REPLACE: updates views using the select statement. No error is reported and the view definition is updated using the SELECT statement if a view exists.</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_s519e38143dbb44a6bff30c2a3297a58a"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0130__en-us_topic_0114776224_ul89342096539"><li id="dli_08_0130__en-us_topic_0114776224_li09341394533">The view to be created must not exist in the current database. Otherwise, an error will be reported. When the view exists, you can add keyword <strong id="dli_08_0130__b429211072413">OR REPLACE</strong> to avoid the error message.</li><li id="dli_08_0130__en-us_topic_0114776224_li1252841517534">The table or view information contained in the view cannot be modified. If the table or view information is modified, the query may fail.</li></ul>
|
<div class="section" id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_s519e38143dbb44a6bff30c2a3297a58a"><h4 class="sectiontitle">Precautions</h4><ul id="dli_08_0130__en-us_topic_0114776224_ul89342096539"><li id="dli_08_0130__en-us_topic_0114776224_li09341394533">The view to be created must not exist in the current database. Otherwise, an error will be reported. When the view exists, you can add keyword <strong id="dli_08_0130__b429211072413">OR REPLACE</strong> to avoid the error message.</li><li id="dli_08_0130__en-us_topic_0114776224_li1252841517534">The table or view information contained in the view cannot be modified. If the table or view information is modified, the query may fail.</li><li id="dli_08_0130__li17421025181715">If the compute engines used for creating tables and views are different, the view query may fail due to incompatible varchar types.<p id="dli_08_0130__p128439404192"><a name="dli_08_0130__li17421025181715"></a><a name="li17421025181715"></a>For example, if a table is created using Spark 3.<em id="dli_08_0130__i1564885319351">x</em>, you are advised to use Spark 2.<em id="dli_08_0130__i217816591358">x</em> to create a view.</p>
|
||||||
|
</li></ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="section" id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_s9f2f3142c926488a947e1a5d9628defc"><h4 class="sectiontitle">Example</h4><p id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_aea0a7b5112b64333b1b924c5eb4eea81">To create a view named <strong id="dli_08_0130__en-us_topic_0093946773_en-us_topic_0047959946_en-us_topic_0039551609_b32304223105838">student_view</strong> for the queried ID and name of the <strong id="dli_08_0130__en-us_topic_0093946773_en-us_topic_0047959946_en-us_topic_0039551609_b22302554105838">student</strong> table, run the following statement:</p>
|
<div class="section" id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_s9f2f3142c926488a947e1a5d9628defc"><h4 class="sectiontitle">Example</h4><p id="dli_08_0130__en-us_topic_0114776224_en-us_topic_0093946773_aea0a7b5112b64333b1b924c5eb4eea81">To create a view named <strong id="dli_08_0130__en-us_topic_0093946773_en-us_topic_0047959946_en-us_topic_0039551609_b32304223105838">student_view</strong> for the queried ID and name of the <strong id="dli_08_0130__en-us_topic_0093946773_en-us_topic_0047959946_en-us_topic_0039551609_b22302554105838">student</strong> table, run the following statement:</p>
|
||||||
<div class="codecoloring" codetype="Sql" id="dli_08_0130__en-us_topic_0114776224_screen722834115917"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">CREATE</span><span class="w"> </span><span class="k">VIEW</span><span class="w"> </span><span class="n">student_view</span><span class="w"> </span><span class="k">AS</span><span class="w"> </span><span class="k">SELECT</span><span class="w"> </span><span class="n">id</span><span class="p">,</span><span class="w"> </span><span class="n">name</span><span class="w"> </span><span class="k">FROM</span><span class="w"> </span><span class="n">student</span><span class="p">;</span>
|
<div class="codecoloring" codetype="Sql" id="dli_08_0130__en-us_topic_0114776224_screen722834115917"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">CREATE</span><span class="w"> </span><span class="k">VIEW</span><span class="w"> </span><span class="n">student_view</span><span class="w"> </span><span class="k">AS</span><span class="w"> </span><span class="k">SELECT</span><span class="w"> </span><span class="n">id</span><span class="p">,</span><span class="w"> </span><span class="n">name</span><span class="w"> </span><span class="k">FROM</span><span class="w"> </span><span class="n">student</span><span class="p">;</span>
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user