doc-exports/docs/dws/dev/dws_06_0331.html
Lu, Huayi e6fa411af0 DWS DEV 830.201 version
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: Lu, Huayi <luhuayi@huawei.com>
Co-committed-by: Lu, Huayi <luhuayi@huawei.com>
2024-05-16 07:24:04 +00:00

117 lines
9.0 KiB
HTML

<a name="EN-US_TOPIC_0000001445346276"></a><a name="EN-US_TOPIC_0000001445346276"></a>
<h1 class="topictitle1">Built-in Functions</h1>
<div id="body0000001445346276"><p id="EN-US_TOPIC_0000001445346276__p163082041204910">HyperLogLog (HLL) has a series of built-in functions for internal data processing. Generally, you are not advised to use these functions.</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001445346276__table47911935194712" frame="border" border="1" rules="all"><caption><b>Table 1 </b>HLL built-in functions</caption><thead align="left"><tr id="EN-US_TOPIC_0000001445346276__row77911435104713"><th align="left" class="cellrowborder" valign="top" width="24.48%" id="mcps1.3.2.2.3.1.1"><p id="EN-US_TOPIC_0000001445346276__p2791143544719">Function</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="75.52%" id="mcps1.3.2.2.3.1.2"><p id="EN-US_TOPIC_0000001445346276__p9791835174713">Function</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001445346276__row1879183513479"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p1179193510478">hll_in</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p1979119357477">Receives hll data in string format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row1479111356473"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p279183512474">hll_out</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p3791143534720">Sends hll data in string format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row17791143519475"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p179143534719">hll_recv</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p19791133504717">Receives hll data in bytea format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row37911735174717"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p579113584717">hll_send</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p27911635154716">Sends hll data in bytea format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row1079119355476"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p879173514479">hll_trans_in</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p1479112358470">Receives hll_trans_type data in string format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row1679111357471"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p19791103544713">hll_trans_out</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p379103574716">Sends hll_trans_type data in string format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row279110357470"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p379193517476">hll_trans_recv</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p187911359479">Receives hll_trans_type data in bytea format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row1679123516479"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p1579193513473">hll_trans_send</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p4791235144715">Sends hll_trans_type data in bytea format.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row10791193515474"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p13791103513474">hll_typmod_in</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p7791835124712">Receives typmod data.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row167911235114720"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p1791123516471">hll_typmod_out</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p17918354472">Sends typmod data.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row20791193513473"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p117911835204715">hll_hashval_in</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p1779111354473">Receives hll_hashval data.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row13791173594711"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p167911235154711">hll_hashval_out</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p4791163594716">Sends hll_hashval data.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row9791435194716"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p18791335114717">hll_add_trans0</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p117915355473">Works similar to hll_add, and is used on the first phase of DNs in distributed aggregation operations.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row12791103520475"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p2791143513476">hll_union_trans</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p7791103544717">Works similar to hll_union, and is used on the first phase of DNs in distributed aggregation operations.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row15791133515478"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p1879133524717">hll_union_collect</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p179110357477">Works similar to hll_union, and is used on the second phase of CNs in distributed aggregation operations to summarize the results of each DN.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row47911535164716"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p1479111359471">hll_pack</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p579114359471">Is used on the third phase of CNs in distributed aggregation operations to convert a user-defined type hll_trans_type to the hll type.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row1179173574716"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p17791635184719">hll</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p879183564713">Converts a hll type to another hll type. Input parameters can be specified.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row107913352479"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p879153518477">hll_hashval</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p67911135194720">Converts the bigint type to the hll_hashval type.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001445346276__row14791143519470"><td class="cellrowborder" valign="top" width="24.48%" headers="mcps1.3.2.2.3.1.1 "><p id="EN-US_TOPIC_0000001445346276__p1079123544713">hll_hashval_int4</p>
</td>
<td class="cellrowborder" valign="top" width="75.52%" headers="mcps1.3.2.2.3.1.2 "><p id="EN-US_TOPIC_0000001445346276__p279110352479">Converts the int4 type to the hll_hashval type.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="dws_06_0042.html">HLL Functions and Operators</a></div>
</div>
</div>