forked from docs/doc-exports
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>
326 lines
105 KiB
HTML
326 lines
105 KiB
HTML
<a name="EN-US_TOPIC_0000001233430207"></a><a name="EN-US_TOPIC_0000001233430207"></a>
|
||
|
||
<h1 class="topictitle1">CREATE FOREIGN TABLE (for OBS Import and Export)</h1>
|
||
<div id="body8662426"><div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s12db42a7819f41648468320f27b7bec4"><h4 class="sectiontitle">Function</h4><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p83326211476"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b67071035152119">CREATE FOREIGN TABLE</strong> creates a foreign table in the current database for parallel data import and export of OBS data. The server used is <strong id="EN-US_TOPIC_0000001233430207__b27391030047">gsmpp_server</strong>, which is created by the database by default.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__note122379223317"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__p7237822631">The hybrid data warehouse (standalone) does not support OBS foreign table import and export.</p>
|
||
</div></div>
|
||
</div>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s2b9a41e45ec24cb7a231824b765f4641"><h4 class="sectiontitle">Precautions</h4><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u52bc7999abd045f5a2fcf1dd3967fde1"><li id="EN-US_TOPIC_0000001233430207__li1213161263115">Only the data in TEXT and CSV formats is supported, and the OBS connection should be configured. ORC and CarbonData data on OBS is not applicable. For details, see <a href="dws_06_0161.html">CREATE FOREIGN TABLE (SQL on OBS or Hadoop)</a>.</li><li id="EN-US_TOPIC_0000001233430207__li1107359183318">Foreign tables are classified into read-only foreign tables (READ ONLY) and write-only foreign tables (WRITE ONLY). By default, foreign tables are read-only. To import data to the cluster, use <strong id="EN-US_TOPIC_0000001233430207__b2025818197166">READ ONLY</strong> for the foreign table. To export data, use <strong id="EN-US_TOPIC_0000001233430207__b11265171961616">WRITE ONLY</strong>.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l6b3ea7f1420441eca23d0a46fa53c7e4">The foreign table is owned by the user who runs the command.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_la58616dc8825477ba4aba4409cf16711">The distribution mode of an OBS foreign table does not need to be explicitly specified. The default mode is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b12732654152214">ROUNDROBIN</strong>.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_la9218fbb7f824ab793f8483b74a8fb19">Only constraints in <a href="dws_06_0161.html#EN-US_TOPIC_0000001233628569__s0b7a85d0acff48e79ada2f91d1e79a0f">Informational Constraint</a> take effect for the created foreign table.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li134351442149">Ensure no Chinese characters are contained in paths used for importing data to or exporting data from OBS.</li></ul>
|
||
</div>
|
||
|
||
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001233430207__table1168152155011" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Read and write formats supported by OBS foreign tables</caption><thead align="left"><tr id="EN-US_TOPIC_0000001233430207__row1116919216505"><th align="left" class="cellrowborder" valign="top" id="mcps1.3.3.2.6.1.1"><p id="EN-US_TOPIC_0000001233430207__p181694218505">Data Type</p>
|
||
</th>
|
||
<th align="left" class="cellrowborder" colspan="2" valign="top" id="mcps1.3.3.2.6.1.2"><p id="EN-US_TOPIC_0000001233430207__p116512023135310">User-built Server</p>
|
||
</th>
|
||
<th align="left" class="cellrowborder" colspan="2" valign="top" id="mcps1.3.3.2.6.1.3"><p id="EN-US_TOPIC_0000001233430207__p198251542115116">gsmpp_server</p>
|
||
</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody><tr id="EN-US_TOPIC_0000001233430207__row6170102175019"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p6170172114502">-</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001145830873_p13910016314">READ ONLY</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001145830873_p184090193118">WRITE ONLY</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p117052115017">READ ONLY</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p567072615610">WRITE ONLY</p>
|
||
</td>
|
||
</tr>
|
||
<tr id="EN-US_TOPIC_0000001233430207__row13170122175018"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p1517092135017">ORC</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p1117092115503">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p517052111501">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p2170152113503">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p11170112175018">×</p>
|
||
</td>
|
||
</tr>
|
||
<tr id="EN-US_TOPIC_0000001233430207__row21701121135011"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p141705214503">PARQUET</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p117022165015">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p181701821205012">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p817012213501">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p5170182115505">×</p>
|
||
</td>
|
||
</tr>
|
||
<tr id="EN-US_TOPIC_0000001233430207__row1170102113505"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p3170102165011">CARBONDATA</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p81711219503">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p14171122125018">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p191714210500">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p171711921145017">×</p>
|
||
</td>
|
||
</tr>
|
||
<tr id="EN-US_TOPIC_0000001233430207__row617112215505"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p13171192165010">TEXT</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p13171121155017">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p3472543184611">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p1917112112501">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p1517113217506">√</p>
|
||
</td>
|
||
</tr>
|
||
<tr id="EN-US_TOPIC_0000001233430207__row317162165015"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p517111211500">CSV</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p1617192110509">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p8472843104613">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p10171162195016">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p1417110211506">√</p>
|
||
</td>
|
||
</tr>
|
||
<tr id="EN-US_TOPIC_0000001233430207__row1117182115501"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.1 "><p id="EN-US_TOPIC_0000001233430207__p417116211507">JSON</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p8172152135013">√</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.2 "><p id="EN-US_TOPIC_0000001233430207__p151721217509">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p13172821125014">×</p>
|
||
</td>
|
||
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.6.1.3 "><p id="EN-US_TOPIC_0000001233430207__p8172172113509">×</p>
|
||
</td>
|
||
</tr>
|
||
</tbody>
|
||
</table>
|
||
</div>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s20457043dc34451cb10216599d38c284"><h4 class="sectiontitle">Syntax</h4><div class="codecoloring" codetype="Sql" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_sf753293a3d614e76a6545278be2f7697"><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">3</span>
|
||
<span class="normal">4</span>
|
||
<span class="normal">5</span>
|
||
<span class="normal">6</span>
|
||
<span class="normal">7</span>
|
||
<span class="normal">8</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">CREATE</span><span class="w"> </span><span class="k">FOREIGN</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="p">[</span><span class="w"> </span><span class="k">IF</span><span class="w"> </span><span class="k">NOT</span><span class="w"> </span><span class="k">EXISTS</span><span class="w"> </span><span class="p">]</span><span class="w"> </span><span class="k">table_name</span><span class="w"> </span>
|
||
<span class="p">(</span><span class="w"> </span><span class="err">{</span><span class="w"> </span><span class="k">column_name</span><span class="w"> </span><span class="n">type_name</span><span class="w"> </span><span class="p">[</span><span class="n">column_constraint</span><span class="w"> </span><span class="p">]</span>
|
||
<span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="k">LIKE</span><span class="w"> </span><span class="n">source_table</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="n">table_constraint</span><span class="w"> </span><span class="p">[,</span><span class="w"> </span><span class="p">...]</span><span class="err">}</span><span class="w"> </span><span class="p">[,</span><span class="w"> </span><span class="p">...]</span><span class="w"> </span><span class="p">)</span><span class="w"> </span>
|
||
<span class="n">SERVER</span><span class="w"> </span><span class="n">gsmpp_server</span><span class="w"> </span>
|
||
<span class="k">OPTIONS</span><span class="w"> </span><span class="p">(</span><span class="w"> </span><span class="err">{</span><span class="w"> </span><span class="n">option_name</span><span class="w"> </span><span class="s1">' value '</span><span class="w"> </span><span class="err">}</span><span class="w"> </span><span class="p">[,</span><span class="w"> </span><span class="p">...]</span><span class="w"> </span><span class="p">)</span><span class="w"> </span>
|
||
<span class="p">[</span><span class="w"> </span><span class="err">{</span><span class="w"> </span><span class="k">WRITE</span><span class="w"> </span><span class="k">ONLY</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="k">READ</span><span class="w"> </span><span class="k">ONLY</span><span class="w"> </span><span class="err">}</span><span class="p">]</span><span class="w"> </span>
|
||
<span class="p">[</span><span class="w"> </span><span class="k">WITH</span><span class="w"> </span><span class="n">error_table_name</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="n">LOG</span><span class="w"> </span><span class="k">INTO</span><span class="w"> </span><span class="n">error_table_name</span><span class="p">]</span><span class="w"> </span>
|
||
<span class="p">[</span><span class="n">PER</span><span class="w"> </span><span class="n">NODE</span><span class="w"> </span><span class="n">REJECT</span><span class="w"> </span><span class="k">LIMIT</span><span class="w"> </span><span class="s1">'value'</span><span class="p">]</span><span class="w"> </span><span class="p">;</span>
|
||
</pre></div></td></tr></table></div>
|
||
|
||
</div>
|
||
</div>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u12f25adbbfc1476eac54513a06df5d42"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l0853db3ecc624fadb9517073e0b0cc3d"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b8423527069598">column_constraint</strong> is as follows:<div class="codecoloring" codetype="Sql" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_sf6663d2f6f0a484cb3bc2610af37199e"><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">3</span></pre></div></td><td class="code"><div><pre><span></span><span class="p">[</span><span class="k">CONSTRAINT</span><span class="w"> </span><span class="k">constraint_name</span><span class="p">]</span>
|
||
<span class="err">{</span><span class="k">PRIMARY</span><span class="w"> </span><span class="k">KEY</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="k">UNIQUE</span><span class="err">}</span>
|
||
<span class="p">[</span><span class="k">NOT</span><span class="w"> </span><span class="n">ENFORCED</span><span class="w"> </span><span class="p">[</span><span class="n">ENABLE</span><span class="w"> </span><span class="n">QUERY</span><span class="w"> </span><span class="n">OPTIMIZATION</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="n">DISABLE</span><span class="w"> </span><span class="n">QUERY</span><span class="w"> </span><span class="n">OPTIMIZATION</span><span class="p">]</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="n">ENFORCED</span><span class="p">]</span>
|
||
</pre></div></td></tr></table></div>
|
||
|
||
</div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc6dae7b51e484e0b8ff213eefdf8a56e"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b84235270695921">table_constraint</strong> is as follows:<div class="codecoloring" codetype="Sql" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s01dd63d784ff4040b95a08853f3d656c"><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">3</span></pre></div></td><td class="code"><div><pre><span></span><span class="p">[</span><span class="k">CONSTRAINT</span><span class="w"> </span><span class="k">constraint_name</span><span class="p">]</span>
|
||
<span class="err">{</span><span class="k">PRIMARY</span><span class="w"> </span><span class="k">KEY</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="k">UNIQUE</span><span class="err">}</span><span class="w"> </span><span class="p">(</span><span class="k">column_name</span><span class="p">)</span>
|
||
<span class="p">[</span><span class="k">NOT</span><span class="w"> </span><span class="n">ENFORCED</span><span class="w"> </span><span class="p">[</span><span class="n">ENABLE</span><span class="w"> </span><span class="n">QUERY</span><span class="w"> </span><span class="n">OPTIMIZATION</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="n">DISABLE</span><span class="w"> </span><span class="n">QUERY</span><span class="w"> </span><span class="n">OPTIMIZATION</span><span class="p">]</span><span class="w"> </span><span class="o">|</span><span class="w"> </span><span class="n">ENFORCED</span><span class="p">]</span>
|
||
</pre></div></td></tr></table></div>
|
||
|
||
</div>
|
||
</li></ul>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_section29925922112759"><h4 class="sectiontitle">Parameter Overview</h4><div class="p" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_p71601111286"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1294123914239">CREATE FOREIGN TABLE</strong> provides multiple parameters, which are classified as follows:<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ul25683940113016"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_li51057566113016">Mandatory parameters<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ul2727588311311"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_li1203002113059"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l1e116805692646b8a2ca3d93aef5b958">table_name</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_li31635979113225"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2518be16d19e4cafbe13a99ccaf99af0">column_name</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_li49307949113237"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l176fa84ebc0a4aa9a13d121a21f08851">type_name</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_li19069486113251"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l476b88f42a094b16bd42e78b93c6c5d3">SERVER gsmpp_server</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li20435204217422"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l91fc6d1438d74165809df29852adb50d">access_key</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li698392154314"><a href="dws_06_0160.html">secret_access_key</a></li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li113952514193"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l9e47719322234105b24a0882253c15fe">OPTIONS parameters</a><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul6394124581819"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li14438046161812">Data source location parameter in foreign tables: <a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2721bcdfcf8a4391ae5148dd06067e3b">location</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1852010124194">Data format parameters<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul164321036144516"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li743133613457"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l02cd20d09e064a269bf43102e1ca1437">format</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li9431153614518"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2e762d0f0291481b978b0acbd1521e3d">header</a> (Only the CSV format is supported.)</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li643133616453"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lcc2eb777e6164c60a35d88181ac54d20">delimiter</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li543113363451"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l50b8f261d3c449e989662626550b7068">quote</a> (Only the CSV format is supported.)</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li2431436164513"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89f3a864abe54befb9b98234f2bd34dc">escape</a> (Only the CSV format is supported.)</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li11431336154513"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2fd004690cb34662b0b07ed5493be39c">null</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1243283617459"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc2550e9054ba426996765e851a0f555b">noescaping</a> (Only the TEXT format is supported.)</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li18432173674510"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5b46e2d544f84265a5116ad03d6cdcff">encoding</a></li><li id="EN-US_TOPIC_0000001233430207__li1374683292017"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l20b2364ce9924b6db7db9086de4da1c4">eol</a></li><li id="EN-US_TOPIC_0000001233430207__li197606312"><a href="#EN-US_TOPIC_0000001233430207__li16738105863515">bom (Only the CSV format is supported.)</a></li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li16959102817195">Error-tolerance parameters<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul1543283634517"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li34321736194510"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lef2faac1a54446c59d3ff99a28cc7192">fill_missing_fields</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li6432536144516"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf62d1cf82f1a4ee6bf1c497f19e0caef">ignore_extra_data</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li14432173611454"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89bb7bce1f364bbdba8116aabe0a818d">compatible_illegal_chars</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li64328363457"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lb3d7bb6ade724417b2a19bd41c30bc90">PER NODE REJECT LIMIT 'val...</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li154322364459"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ld7597049cd774e1b95cf9133139f6051">LOG INTO error_table_name</a></li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1843243618453"><a href="#EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc83138913ec84fab81c7e1a0fe62218e">WITH error_table_name</a></li></ul>
|
||
</li></ul>
|
||
</li></ul>
|
||
</div>
|
||
</div>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s3ae5c1ae32f441fc8bfc024f46236ad7"><h4 class="sectiontitle">Parameter Description</h4><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_uc6b7d12a147349eda9721dcec9833db4"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l1687d7080fa4453a909903a90f05f6f3"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a8e8d435ff51c47eba5af13d067844901">IF NOT EXISTS</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a94263e88b11b40c58d8dd44d67c600ed">Does not throw an error if a table with the same name exists. A notice is issued in this case.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l1e116805692646b8a2ca3d93aef5b958"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l1e116805692646b8a2ca3d93aef5b958"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l1e116805692646b8a2ca3d93aef5b958"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a3b9b241872f3420bbea47ca73fd21e15">table_name</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a76d68e98381b4690b1befaa8ade90e97">Specifies the name of the foreign table to be created.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a9a880a6e87604c3eae89cbfb622040e5">Value range: a string. It must comply with the naming convention.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2518be16d19e4cafbe13a99ccaf99af0"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2518be16d19e4cafbe13a99ccaf99af0"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2518be16d19e4cafbe13a99ccaf99af0"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a369cd2eb176b4c6e90f466383d976035">column_name</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ab3fe9f4306c343b8896f18400502ba31">Specifies the name of a column in the foreign table.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ad6107c5fc7fc43ae967bbbfc5323feaf">Value range: a string. It must comply with the naming convention.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l176fa84ebc0a4aa9a13d121a21f08851"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l176fa84ebc0a4aa9a13d121a21f08851"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l176fa84ebc0a4aa9a13d121a21f08851"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a7c8061065a4e43db9cb4ba405c672178">type_name</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5e50355de781487ebf6f5d476e3e50ac">Specifies the data type of the column.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l476b88f42a094b16bd42e78b93c6c5d3"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l476b88f42a094b16bd42e78b93c6c5d3"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l476b88f42a094b16bd42e78b93c6c5d3"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a0b4468aadf134cde83b591839be196f1">SERVER gsmpp_server</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a9f7d08cca67f4ca28f6e1540fa112c99">Specifies the server name of the foreign table. In the OBS foreign table, its server <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b984993212814">gsmpp_server</strong> is created by the initial database.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l9e47719322234105b24a0882253c15fe"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l9e47719322234105b24a0882253c15fe"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l9e47719322234105b24a0882253c15fe"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a86414c1dac6c44349f98293ab3e88717">OPTIONS ( { option_name ' value ' } [, ...] )</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a68f034ad24b74cb4860ed15b0fc905e6">Specifies parameters of foreign table data.</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u42d254ef3d814163b5243a34b62d82c9"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l6654c017343a41d3921a8d5f9544dcad">encrypt<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_add7852ddabb74b7e8614337fd4ee1051"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l6654c017343a41d3921a8d5f9544dcad"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l6654c017343a41d3921a8d5f9544dcad"></a>Specifies whether HTTPS is enabled for data transfer. <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1155974519119">on</strong> enables HTTPS and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b15804727171018">off</strong> disables it (in this case, HTTP is used). The default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b149510377100">off</strong>.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l91fc6d1438d74165809df29852adb50d"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l91fc6d1438d74165809df29852adb50d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l91fc6d1438d74165809df29852adb50d"></a>access_key<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_adcf8ac4265e943fdb3df0d153bbe8168"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l91fc6d1438d74165809df29852adb50d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l91fc6d1438d74165809df29852adb50d"></a>Indicates the access key (AK, obtained from the user information on the console) used for the OBS access protocol. When you create a foreign table, its AK value is encrypted and saved to the metadata table of the database.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc6787d2f7a684eb58877a823cd45427d">secret_access_key:<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a72d4c5e69e614e70bc44e8bc0a29d88d"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc6787d2f7a684eb58877a823cd45427d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lc6787d2f7a684eb58877a823cd45427d"></a>Indicates the secret access key (SK, obtained from the user information on the console) used for the OBS access protocol. When you create a foreign table, its SK value is encrypted and saved to the metadata table of the database.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l0a0547533d2f412a9dcbad0564752c54">chunksize<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_abe8d54242bf8404d8125cd13fa77fd64"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l0a0547533d2f412a9dcbad0564752c54"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l0a0547533d2f412a9dcbad0564752c54"></a>Specifies the cache read by each OBS thread on a DN. Its value range is 8 to 512 in the unit of MB. Its default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b186372113717">64</strong>.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2721bcdfcf8a4391ae5148dd06067e3b"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2721bcdfcf8a4391ae5148dd06067e3b"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2721bcdfcf8a4391ae5148dd06067e3b"></a>location<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a49503c37e2f8408881b07cfa611f9ba0"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2721bcdfcf8a4391ae5148dd06067e3b"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2721bcdfcf8a4391ae5148dd06067e3b"></a>Specifies the data source location of a foreign table. Currently, only URLs are allowed. Multiple URLs are separated using vertical bars (|).</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_note1691517427213"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul29176429216"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li129181429212">The URL of a read-only foreign table (the default permission is read-only) can end with the path prefix or the full path of the target object in the format of <strong id="EN-US_TOPIC_0000001233430207__b10240124517432">obs://</strong><em id="EN-US_TOPIC_0000001233430207__i7247345144310">Bucket</em><strong id="EN-US_TOPIC_0000001233430207__b624824564310">/</strong><em id="EN-US_TOPIC_0000001233430207__i924814518437">Prefix</em>. <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i11601144183911">Prefix</em> indicates the prefix of an object path, for example, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b2333104213420">obs://mybucket/tpch/nation/</strong>.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li197498241418">If the <strong id="EN-US_TOPIC_0000001233430207__b6715650112414">region</strong> parameter is explicitly specified in <strong id="EN-US_TOPIC_0000001233430207__b20715135082414">obs://</strong><em id="EN-US_TOPIC_0000001233430207__i8716125016242">Bucket</em><strong id="EN-US_TOPIC_0000001233430207__b971665072417">/</strong><em id="EN-US_TOPIC_0000001233430207__i107161950102416">Prefix</em>, the value of <strong id="EN-US_TOPIC_0000001233430207__b47164507248">region</strong> will be read. If the <strong id="EN-US_TOPIC_0000001233430207__b77175507242">region</strong> parameter is not specified, the value of <strong id="EN-US_TOPIC_0000001233430207__b107176505243">defaultRegion</strong> will be read.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li139242420215">The URL of a writable foreign table does not need to contain a file name. You can specify only one data source location for a foreign table. The directory corresponding to the location must be created before you specify the location.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li17932154211212">URLs specified for a read-only foreign table must be different.</li><li id="EN-US_TOPIC_0000001233430207__li526233810554">Specify <strong id="EN-US_TOPIC_0000001233430207__b101388495583">location</strong> when inserting data to a foreign table.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li24711655165315">Parameter <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b557373011425">LOCATION</strong> supports prefixes <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b757433024211">gsobs</strong> and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b18574153015426">obs</strong>, which are identified as OBS information. <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b957418307427">LOCATION</strong> should be followed by <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b25751530174219">gsobs</strong>, <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i85751330124220">OBS URL</em>, and <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i8575163012424">Bucket</em>, or by <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1957593017421">obs</strong> and <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i05766303429">Bucket</em>.</li></ul>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p1568615471063">When importing and exporting data, you are advised to use the <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b19535154516108">location</strong> parameter as follows:</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul147371925918"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li682553917720">You are advised to specify a file name for <span class="parmname" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p8d4cde64e6504e449c2afb158066d8e6"><b>location</b></span> during data import. If you only specify an OBS bucket or directory, all text files in it will be imported. An error message will be reported if the data format is incorrect. If you set fault tolerance, a large amount of data may be imported to the fault-tolerant table.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1423511813814">Multiple files in an OBS bucket can be imported at the same time. The matched files are imported based on the file name prefix.<div class="p" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p71467910818"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1423511813814"></a><a name="en-us_topic_0000001098811114_li1423511813814"></a>For example, you can identify and import the following two files after specifying the prefix <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b84235270615720">mybucket/input_data/product_info</strong> in <span class="parmname" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_parmname39091339415656"><b>location</b></span>:<pre class="screen" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_sa51e57890d904104b17208f9b319d387">mybucket/input_data/product_info.0
|
||
mybucket/input_data/product_info.1</pre>
|
||
</div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li186681639388">If you specify a file name, for example, <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath420031885172124"><b>1.csv</b></span>, then other files (like <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath2093757098175439"><b>1.csv1</b></span> or <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath1618437233175439"><b>1.csv22</b></span>) starting with <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath1786059585175314"><b>1.csv</b></span> in the bucket or directory where <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath552207826175410"><b>1.csv</b></span> resides will be automatically imported. That is, files, such as <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath178662365410313"><b>1.csv1</b></span> and <span class="filepath" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_filepath111652321710313"><b>1.csv22</b></span>, are automatically imported.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li152691643486">To specify multiple URLs in OBS mode, separate URLs by using vertical bars (|). In gsobs mode, only one URL can be specified.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li178851252293">During data export, a directory is generated for <span class="parmname" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0103068322_parmname14636181732018"><b>location</b></span> by default. If you specify only a file name, the system automatically creates a directory whose name starts with the file name and then generates the file that stores the exported data. The file name is automatically generated by GaussDB(DWS).</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li118146170916">You can specify one path for <span class="parmname" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_parmname168943122103"><b>location</b></span> only during data export.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li63348327371">region<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p332713407313"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li63348327371"></a><a name="en-us_topic_0000001098811114_li63348327371"></a>(Optional) specifies the value of <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b759271122419">regionCode</strong>, region information on the cloud.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p149561863108">If the <strong id="EN-US_TOPIC_0000001233430207__b1919527193514">region</strong> parameter is explicitly specified, the value of <strong id="EN-US_TOPIC_0000001233430207__b1619657143514">region</strong> will be read. If the <strong id="EN-US_TOPIC_0000001233430207__b15196675351">region</strong> parameter is not specified, the value of <strong id="EN-US_TOPIC_0000001233430207__b15197979356">defaultRegion</strong> will be read.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_note474917291820"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_p1318314311929">Note the following when setting parameters for importing or exporting OBS foreign tables in TEXT or CSV format:</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul1818420317213"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li4186103110216">The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b87092196546">location</strong> parameter is mandatory. The prefixes <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b127093192541">gsobs</strong> and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1571111985414">obs</strong> indicate file locations on OBS. The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b8712121995413">gsobs</strong> prefix should be followed by <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i1871316192542">obs url</em>, <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i15714121935417">bucket</em>, and <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i1771661915411">prefix</em>. The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1471771945413">obs</strong> prefix should be followed by <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i1971961935415">bucket</em> or <em id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_i672071915549">prefix</em>.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li21991131326">The data sources of multiple buckets are separated by vertical bars (|), for example, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b122413785415">LOCATION 'obs://bucket1/folder/ | obs://bucket2/'</strong>. The database scans all objects in the specified folders.</li></ul>
|
||
</div></div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l02cd20d09e064a269bf43102e1ca1437"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l02cd20d09e064a269bf43102e1ca1437"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l02cd20d09e064a269bf43102e1ca1437"></a>format<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_aa750bda80fb641d380cd8aed9f78b5b2"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l02cd20d09e064a269bf43102e1ca1437"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l02cd20d09e064a269bf43102e1ca1437"></a>Specifies the format of the source data file in a foreign table.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5218d7dedba0469e9f72b57e1f171bfa">Valid value: <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b168171843104617">CSV</strong> and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1981734354610">TEXT</strong>. The default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b8818243104616">TEXT</strong>. GaussDB(DWS) only supports CSV and TEXT formats.</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u570c000c912540bcadff2d09b4356f3c"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l37c2bee4e75140d8bdb7fd6188faa132">CSV (comma-separated format):<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u36c34db0078d43aca9bc8f49e588afd9"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l7d477d8b579447e38699e50e04928093">The CSV file can process linefeeds efficiently, but cannot process certain special characters very well.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l18c6b00007d9472d8d12fcd8a50d3225">A CSV file is composed of records that are separated as columns by delimiters. Each record shares the same column sequence.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lfcda9adffb7c4f789b3a3bbc3be2eab6">TEXT (text format):<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_uf68df508831d44fd879137874b033a5d"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lfd70c07195534f5cbee19a69c946effc">Records are separated as columns by linefeed. The TEXT file can process special characters efficiently, but cannot process linefeeds well.</li></ul>
|
||
</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2e762d0f0291481b978b0acbd1521e3d"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2e762d0f0291481b978b0acbd1521e3d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2e762d0f0291481b978b0acbd1521e3d"></a>header<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ac3da8efa49914dd8b188d3c8b5116544"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2e762d0f0291481b978b0acbd1521e3d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2e762d0f0291481b978b0acbd1521e3d"></a>Specifies whether a file contains a header with the names of each column in the file.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0103068322_en-us_topic_0101295172_p1722954817188">When OBS exports data, this parameter cannot be set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b2673649201817">true</strong>. Use the default value <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b667454910183">false</strong>, indicating that the first row of the exported data file is not the header.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ae9deab21030643c886371d1724c31d1e">When data is imported, if <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1484515125418">header</strong> is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b16847105175413">on</strong>, the first row of the data file will be identified as the header and ignored. If <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b95684514271">header</strong> is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b35712457274">off</strong>, the first row will be identified as a data row.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a03b37914583b4147b5a1f8eceb0598d4">Valid value: <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706174916">true</strong>, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b84235270616240">on</strong>, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b8423527061633">false</strong>, and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706174924">off</strong>. The default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706164830">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b84235270616558">off</strong>.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lcc2eb777e6164c60a35d88181ac54d20"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lcc2eb777e6164c60a35d88181ac54d20"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lcc2eb777e6164c60a35d88181ac54d20"></a>delimiter<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a3f50f7cb25954ae09671288907b1c797"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lcc2eb777e6164c60a35d88181ac54d20"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lcc2eb777e6164c60a35d88181ac54d20"></a>Specifies the column delimiter of data. Use the default delimiter if it is not set. The default delimiter of TEXT is a tab and that of CSV is a comma (,).</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n3d9f9b5aa7324a5e8d421fd26874fc01"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u10b19e271d994a629d42280b3e93e804"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_le2a8a876c8244ae392fc5fbbdef9d4f0">The delimiter of TEXT cannot be <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b154487154566">\r</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b18450131515565">\n</strong>.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc8f7905c5b5647f5a81e1b2efefd9c2a">A delimiter cannot be the same as the <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b592173495113">null</strong> value. The delimiter for the CSV format cannot be same as the <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b139229346511">quote</strong> value.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l555ab7e8ba1a4f14b5341b8a2af974bc">The separator of TEXT data cannot contain letters, digits, backslashes (\), and periods (.).</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lfdb90a8b87ce43f6b05d59970fbd595b">The data length of a single row should be less than 1 GB. A row that has many columns using long delimiters cannot contain much valid data.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf59ce1120dc44f3e8b1680cb53ff38e8">You are advised to use a multi-character string, such as the combination of the dollar sign ($), caret (^), and ampersand (&), or invisible characters, such as 0x07, 0x08, and 0x1b as the delimiter.</li></ul>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a7a9d59eba6674ff49d0791343cfa3e6a">Value range:</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a2277e4cb1eaf432e97265f6d92c88385">The value of <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b67231750205614">delimiter</strong> can be a multi-character delimiter whose length is less than or equal to 10 bytes.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l50b8f261d3c449e989662626550b7068"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l50b8f261d3c449e989662626550b7068"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l50b8f261d3c449e989662626550b7068"></a>quote<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ae31ce5b23702461088a1abaec12a900a"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l50b8f261d3c449e989662626550b7068"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l50b8f261d3c449e989662626550b7068"></a>Specifies the quotation mark for the CSV format. The default value is a double quotation mark (").</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_nb1b12d8141e144b5931df23650ac3995"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u8f7e0dd21aad497e8ef96793c5369fff"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l11bbfd3171b14abf9d7ab9894c61a6ff">The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b13266819125717">quote</strong> value cannot be the same as the delimiter or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b132673193575">null</strong> value.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l229370a8c8cc4786b939c16a729ca2ab">The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1575411271578">quote</strong> value must be a single-byte character.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_le8c80cdf0fd84122b8e896f86f9968ca">Invisible characters are recommended as <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b193398281611139">quote</strong> values, such as 0x07, 0x08, and 0x1b.</li></ul>
|
||
</div></div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89f3a864abe54befb9b98234f2bd34dc"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89f3a864abe54befb9b98234f2bd34dc"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l89f3a864abe54befb9b98234f2bd34dc"></a>escape<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_acf34d1c9ba5244648b58d6ee80c09f25"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89f3a864abe54befb9b98234f2bd34dc"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l89f3a864abe54befb9b98234f2bd34dc"></a>Specifies an escape character for a CSV file. The value must be a single-byte character.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a6a5a77ca88e740559174873e2de32af0">The default value is a double quotation mark ("). If the value is the same as the <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b6535204693816">quote</strong> value, it will be replaced with <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1953644623817">\0</strong>.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2fd004690cb34662b0b07ed5493be39c"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2fd004690cb34662b0b07ed5493be39c"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2fd004690cb34662b0b07ed5493be39c"></a>null<div class="p" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5c745d5b609f469da9274319ca178542"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l2fd004690cb34662b0b07ed5493be39c"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l2fd004690cb34662b0b07ed5493be39c"></a>Specifies the string that represents a null value.<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n940e5b59f5b445cbb2ea93066105d5d1"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u1e22b27d810d4caf8d3900a4d37e0ff4"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ld447339225e542128408cec60c35f988">The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b850181435819">null</strong> value cannot be <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1352171418586">\r</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b85218144580">\n</strong>. The maximum length is 100 characters.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lab2e61e25aa3458381de198439810621">The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b84235270618146">null</strong> value cannot be the same as the delimiter or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706181413">quote</strong> value.</li></ul>
|
||
</div></div>
|
||
</div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ad68659097db24af6b3aa6024daad5684">Value range:</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ub7b5eec5f67542b79d8bd66fad5fcf15"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l915dc60d08c94879b3adcee024bc21f9">The default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706154323">\N</strong> for the TEXT format.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lda16629df3df44d9ba243042afec5fac">The default value for the CSV format is an empty string without quotation marks.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc2550e9054ba426996765e851a0f555b"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc2550e9054ba426996765e851a0f555b"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lc2550e9054ba426996765e851a0f555b"></a>noescaping<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ab02024e634984b7986db028ed5019e89"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc2550e9054ba426996765e851a0f555b"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lc2550e9054ba426996765e851a0f555b"></a>Specifies whether to escape the backslash (\) and its following characters in the TEXT format.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_na2000afaf5284610a07a153933e20a9e"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_af659661ced5b4d8aadf00ecaf1ff8816"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b176721053121718">noescaping</strong> is available only for the TEXT format.</p>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a97dff72491cf4af89bfdc5e22960763c">Valid value: <strong id="EN-US_TOPIC_0000001233430207__b1987885997">true</strong>, <strong id="EN-US_TOPIC_0000001233430207__b1133043194">on</strong>, <strong id="EN-US_TOPIC_0000001233430207__b1849469805">false</strong>, and <strong id="EN-US_TOPIC_0000001233430207__b1082023922">off</strong>. The default value is <strong id="EN-US_TOPIC_0000001233430207__b1244615545">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__b1830879193">off</strong>.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5b46e2d544f84265a5116ad03d6cdcff"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5b46e2d544f84265a5116ad03d6cdcff"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l5b46e2d544f84265a5116ad03d6cdcff"></a>encoding<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a30e11e48f331478d9865957e79ad2dba"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5b46e2d544f84265a5116ad03d6cdcff"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l5b46e2d544f84265a5116ad03d6cdcff"></a>Specifies the encoding of a data file, that is, the encoding used to parse, check, and generate a data file. Its default value is the default <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b542261751819">client_encoding</strong> value of the current database.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a54ff764cddb34b218287dc1e2889b906">Before you import foreign tables, it is recommended that you set <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b18846654114816">client_encoding</strong> to the file encoding format, or a format matching the character set of the file. Otherwise, unnecessary parsing and check errors may occur, leading to import errors, rollback, or even invalid data import. Before exporting foreign tables, you are also advised to specify this parameter, because the export result using the default character set may not be what you expect.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_afdd8f68be54f44ac965eeba59c95efeb">If this parameter is not specified when you create a foreign table, a warning message will be displayed on the client.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n569e1097afd344529637a494706d0829"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__ul18431030105218"><li id="EN-US_TOPIC_0000001233430207__li1743117305525">Currently, OBS cannot parse a file using multiple character sets during foreign table import.</li><li id="EN-US_TOPIC_0000001233430207__li343110302525">Currently, OBS cannot write a file using multiple character sets during foreign table export.</li></ul>
|
||
</div></div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lef2faac1a54446c59d3ff99a28cc7192"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lef2faac1a54446c59d3ff99a28cc7192"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lef2faac1a54446c59d3ff99a28cc7192"></a>fill_missing_fields<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a618dae0b7e6b424aa33bf07fc27a8931"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lef2faac1a54446c59d3ff99a28cc7192"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lef2faac1a54446c59d3ff99a28cc7192"></a>Specifies how to handle the problem that the last column of a row in the source file is lost during data import.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_aa7e5661804a44ebaa70af51cb187b517">Valid value: <strong id="EN-US_TOPIC_0000001233430207__b985036488">true</strong>, <strong id="EN-US_TOPIC_0000001233430207__b1755083140">on</strong>, <strong id="EN-US_TOPIC_0000001233430207__b2053142539">false</strong>, and <strong id="EN-US_TOPIC_0000001233430207__b1722248283">off</strong>. The default value is <strong id="EN-US_TOPIC_0000001233430207__b1048592406">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__b1950267586">off</strong>.</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u4fbff24736744e2981e7b1a0517027a3"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l199ba1411c3b4bd5b7b576a0616b8a8a">If this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b7764815154914">true</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b15766181564913">on</strong> and the last column of a data row in a source data file is lost, the column will be replaced with <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b37667157496">NULL</strong> and no error message will be generated.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l97741effb6264a86a9e44c4f41a8001f">If this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b39408301492">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1394373004914">off</strong> and the last column of a data row in a source data file is lost, the following error information will be displayed:<pre class="screen" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_se7345db5a66f4213bc2ac532a981b25d">missing data for column "tt"</pre>
|
||
</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf62d1cf82f1a4ee6bf1c497f19e0caef"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf62d1cf82f1a4ee6bf1c497f19e0caef"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lf62d1cf82f1a4ee6bf1c497f19e0caef"></a>ignore_extra_data<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a94d848bbf4dc45d1b6dc389dadda91b1"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf62d1cf82f1a4ee6bf1c497f19e0caef"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lf62d1cf82f1a4ee6bf1c497f19e0caef"></a>Specifies whether to ignore excessive columns when the number of columns in a source data file exceeds that defined in the foreign table. This parameter is available only for data import.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a10392571e59f4fbaafe01d7804b4b9bd">Valid value: <strong id="EN-US_TOPIC_0000001233430207__b825284323">true</strong>, <strong id="EN-US_TOPIC_0000001233430207__b1468819837">on</strong>, <strong id="EN-US_TOPIC_0000001233430207__b334200711">false</strong>, and <strong id="EN-US_TOPIC_0000001233430207__b487398049">off</strong>. The default value is <strong id="EN-US_TOPIC_0000001233430207__b369264939">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__b936414061">off</strong>.</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_uf2be125a231a4b7f8737bb2fe31cf78e"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lbfd357bb5a0a45a986701310398ca5a7">If this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b8477258154917">true</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1477155864920">on</strong> and the number of source data files exceeds the number of foreign table columns, excessive columns will be ignored.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lb3d2cb2ce17c409c8d1d09ba5b761211">If this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1781717125016">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b11781617165011">off</strong> and the number of source data files exceeds the number of foreign table columns, the following error information will be displayed:<pre class="screen" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s5a6ea8f5af894742a161f21dc20f4b1a">extra data after last expected column</pre>
|
||
</li></ul>
|
||
<div class="notice" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_nab7bbfc8da29475880b6783c428d59bb"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ac7c3753cd69948e583947e72ddb80001">If the linefeed at the end of a row is lost and this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b712353118422">true</strong>, data in the next row will be ignored.</p>
|
||
</div></div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l7e1528806bfe498b91593f2873ddb5bc">reject_limit<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a7ca4ed515f854c528b43604cd2902c03"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l7e1528806bfe498b91593f2873ddb5bc"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l7e1528806bfe498b91593f2873ddb5bc"></a>Specifies the maximum number of data format errors allowed during a data import task. If the number of errors does not reach the maximum number, the data import task can still be executed.</p>
|
||
<div class="notice" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n7be3b3adf73246db9fdf6dca3357cf1b"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a509f3ce53cd84d60b7df46aae49addbc">You are advised to replace this syntax with <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b984143015311">PER NODE REJECT LIMIT 'value'</strong>.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_af702f96458414ba6979866282f2a02b6">Examples of data format errors include the following: a column is lost, an extra column exists, a data type is incorrect, and encoding is incorrect. Once a non-data format error occurs, the whole data import process is stopped.</p>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_aa1286d4b63ea4e239ba7f162bcdceb51">Value range: an integer and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b5265412542">unlimited</strong>.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5151e6fd68de4b7180dd69189ab7f735">If this parameter is not specified, an error message is returned immediately.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l20b2364ce9924b6db7db9086de4da1c4"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l20b2364ce9924b6db7db9086de4da1c4"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l20b2364ce9924b6db7db9086de4da1c4"></a>eol<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a3bb43dedc75c42d99e174ef56ee208bb"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l20b2364ce9924b6db7db9086de4da1c4"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l20b2364ce9924b6db7db9086de4da1c4"></a>Specifies the newline character style of the imported or exported data file.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0059778310_p19076673152942">Value range: multi-character newline characters within 10 bytes. Common newline characters include <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b12660205518211">\r</strong> (0x0D), <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b3660155152112">\n</strong> (0x0A), and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b666017555211">\r\n</strong> (0x0D0A). Special newline characters include <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b5662135532117">$</strong> and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1666275592117">#</strong>.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_note4822103112229"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul13825143117221"><li id="EN-US_TOPIC_0000001233430207__li18430291653">The <strong id="EN-US_TOPIC_0000001233430207__b466935073012">eol</strong> parameter supports only the TEXT format for data import.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li8771574226">The value of the <strong id="EN-US_TOPIC_0000001233430207__b772115520305">eol</strong> parameter cannot be the same as that of <strong id="EN-US_TOPIC_0000001233430207__b14721135218305">DELIMITER</strong> or <strong id="EN-US_TOPIC_0000001233430207__b197211152113015">NULL</strong>.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1777105742214">The value of the <strong id="EN-US_TOPIC_0000001233430207__b1173130143111">eol</strong> parameter cannot contain digits, letters, or periods (.).</li></ul>
|
||
</div></div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lecd11554a6b24f0b80f135bc8e2ad17d">date_format<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a4f67f7ecf122456f91a3eafdbaf80125"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lecd11554a6b24f0b80f135bc8e2ad17d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lecd11554a6b24f0b80f135bc8e2ad17d"></a>Specifies the DATE format for data import. This syntax is available only for READ ONLY foreign tables.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a2e5907a293e346fd9ce6535571154475">Value range: a valid DATE value. For details, see <a href="dws_06_0035.html">Date and Time Processing Functions and Operators</a>.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n69515acb17334390910e808cdd1d36fb"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a46a8624a514d41a6ad6004b6f7a608a7">If Oracle is specified as the compatible database, the DATE format is TIMESTAMP. For details, see <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b2773113017561">timestamp_format</strong> below.</p>
|
||
</div></div>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l99a6b20f1bb9475ba1ad53ebb47e0b90">time_format<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a0cd54aca2c2a47a4bf94400b80e5198d"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l99a6b20f1bb9475ba1ad53ebb47e0b90"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l99a6b20f1bb9475ba1ad53ebb47e0b90"></a>Specifies the TIME format for data import. This syntax is available only for READ ONLY foreign tables.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5809efc766ae4b58a08b9feb4518dadf">Value range: a valid TIME value. Time zones cannot be used.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5dfcd48a48a941a89a5f2f3a4b28156b">timestamp_format<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_aec314d301a47416690bbc6944134dd48"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5dfcd48a48a941a89a5f2f3a4b28156b"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l5dfcd48a48a941a89a5f2f3a4b28156b"></a>Specifies the TIMESTAMP format for data import. This syntax is available only for READ ONLY foreign tables.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a0e0a0919e0e44a828ffe9c9ee381a4ff">Value range: any valid TIMESTAMP value. Time zones cannot be used.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lab718716e3c3457db106338f31c40f58">smalldatetime_format<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a51db0ed11ae74b88bb5be818117041a2"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lab718716e3c3457db106338f31c40f58"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lab718716e3c3457db106338f31c40f58"></a>Specifies the SMALLDATETIME format for data import. This syntax is available only for READ ONLY foreign tables.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_accd8274f2d4b4849809e77029fe33a23">Value range: a valid SMALLDATETIME value.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89bb7bce1f364bbdba8116aabe0a818d"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89bb7bce1f364bbdba8116aabe0a818d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l89bb7bce1f364bbdba8116aabe0a818d"></a>compatible_illegal_chars<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a4dc6e03bb5ee4d6ca500793333fed724"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l89bb7bce1f364bbdba8116aabe0a818d"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_l89bb7bce1f364bbdba8116aabe0a818d"></a>Specifies whether to enable fault tolerance on invalid characters during data import. This syntax is available only for READ ONLY foreign tables.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5c713175fae047e3b7957ae9f9c00e1d">Valid value: <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b2656739105713">true</strong>, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b19657183985714">on</strong>, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b17657639125715">false</strong>, and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1657439125718">off</strong>. The default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b5597164220578">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1059864235710">off</strong>.</p>
|
||
<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u8f6f1572284e4909b0727d5052b16aef"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ld69cc08a64ca47b7aa3a9c9aff0c6445">If this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1832634610578">true</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b5327184625712">on</strong>, invalid characters are tolerated and imported to the database after conversion.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf5c28d5290d140499554888842af0d8a">If this parameter is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1821910621010">false</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b122205651017">off</strong> and an error occurs when there are invalid characters, the import will be interrupted.</li></ul>
|
||
<div class="notice" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n7e087f39ab2d4ec5b0911f2dd027ba9d"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5a3b7c9844cb4449a7655567fcd95436">On a Windows platform, if OBS reads data files using the TEXT format, 0x1A will be treated as an EOF symbol and a parsing error will occur. It is the implementation constraint of the Windows platform. Since OBS on a Windows platform does not support BINARY read, the data can be read by OBS on a Linux platform.</p>
|
||
</div></div>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n23cfb794add54a2d80de376f1fdd96ff"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a2cad143cb6a94c5e976427c5e25fd4aa">The rule of error tolerance for invalid characters imported is as follows:</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a470965ca7cb74cb49bdc79e971181522">(1) <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1953048185917">\0</strong> is converted to a space.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a7846a1cea2a4470ca3bcb9c3865ffe9a">(2) Other invalid characters are converted to question marks.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a38c91d1878ed4c2ea2f13c4c7dd981c9">(3) If <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b15449101525911">compatible_illegal_chars</strong> is set to <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1644920159593">true</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b114491215125912">on</strong>, invalid characters are tolerated. If <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1345110154594">NULL</strong>, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1845171555915">DELIMITER</strong>, <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b34511715145911">QUOTE</strong>, and <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b10452181518591">ESCAPE</strong> are set to a spaces or question marks, errors like "illegal chars conversion may confuse COPY escape 0x20" will be displayed to prompt users to change parameter values that cause confusion, preventing import errors.</p>
|
||
</div></div>
|
||
</li></ul>
|
||
<ul id="EN-US_TOPIC_0000001233430207__ul1460544616346"><li id="EN-US_TOPIC_0000001233430207__li16738105863515"><a name="EN-US_TOPIC_0000001233430207__li16738105863515"></a><a name="li16738105863515"></a>bom<p id="EN-US_TOPIC_0000001233430207__p19511175512367"><a name="EN-US_TOPIC_0000001233430207__li16738105863515"></a><a name="li16738105863515"></a>Indicates whether a CSV file contains the utf8 BOM.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__p751115533615">Value range: <strong id="EN-US_TOPIC_0000001233430207__b886115813117">true</strong>, <strong id="EN-US_TOPIC_0000001233430207__b286116816311">on</strong>, <strong id="EN-US_TOPIC_0000001233430207__b2086219814310">false</strong>, and <strong id="EN-US_TOPIC_0000001233430207__b786238133112">off</strong></p>
|
||
<p id="EN-US_TOPIC_0000001233430207__p1451110559367">Default value: <strong id="EN-US_TOPIC_0000001233430207__b2744191019318">false</strong></p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__note57381587355"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__p1418101017377">This parameter is valid only when the foreign table is read-only and uses UTF8 code.</p>
|
||
</div></div>
|
||
</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lf2c6b65868b84e799be63abbdbe57823"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_af55abb9833b04926b0ddc9ab01b54ddb">READ ONLY</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a521f3086b3bf4e7aa0b76bebd6315a92">Specifies whether a foreign table is read-only. This parameter is available only for data import.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l87000d8a09244164980aab5c6ad6a3e1"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_aa76d6f0df7aa45c5b4215d1bf9d1673e">WRITE ONLY</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ab635a760ec2143f8aa6e52d8a23e17f4">Specifies whether a foreign table is write-only. This parameter is available only for data export.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc83138913ec84fab81c7e1a0fe62218e"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lc83138913ec84fab81c7e1a0fe62218e"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lc83138913ec84fab81c7e1a0fe62218e"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a39c63a21a3a14d98b05837794d73e4ca">WITH error_table_name</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ad9f9b7d00d5946e68ad960c942163344">Specifies the table where data format errors generated during parallel data import are recorded. You can query the error information table after data is imported to obtain error details. This parameter is available only after <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b49591835141013">reject_limit</strong> is set.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n808223c4729d435f9142a7b60d6cb0f9"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a95b0df60476a41438f738a184eab7e05">To be compatible with PostgreSQL open source interfaces, you are advised to replace this syntax with <strong id="EN-US_TOPIC_0000001233430207__b29580902994135">LOG INTO</strong>. When this parameter is specified, an error table is automatically created.</p>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a9bef4bc705284e5f8bc4dd733a350202">Value range: a string. It must comply with the naming convention.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ld7597049cd774e1b95cf9133139f6051"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ld7597049cd774e1b95cf9133139f6051"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_ld7597049cd774e1b95cf9133139f6051"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a903ece849837465185dd0e1071481045">LOG INTO error_table_name</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_abd2bd2747a43461dbf61e3c0abeb536a">Specifies the table where data format errors generated during parallel data import are recorded. You can query the error information table after data is imported to obtain error details.</p>
|
||
<div class="note" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ne3b1b599b7264c0a9c0a9b9b1cb174c4"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_ul16433113901313"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1943333911137">This parameter is available only after <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b6816153161111">PER NODE REJECT LIMIT</strong> is set.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_li1037710411134">When this parameter is specified, an error table is automatically created.</li></ul>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ae25aeb634e4d4b96b59e79895898bea2">Value range: a string. It must comply with the naming convention.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lb3d7bb6ade724417b2a19bd41c30bc90"><a name="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lb3d7bb6ade724417b2a19bd41c30bc90"></a><a name="en-us_topic_0000001098811114_en-us_topic_0117407717_lb3d7bb6ade724417b2a19bd41c30bc90"></a><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ace85b5d473af4504bb735345e1323909">PER NODE REJECT LIMIT 'value'</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a7b89904a74c94732a7f8eec249a1a352">Specifies the maximum number of data format errors on each DN during data import. If the number of errors exceeds the specified value on any DN, data import fails, an error is reported, and the system exits data import.</p>
|
||
<div class="notice" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_n00fb9fc4daf2455fb2b917f0aa2a136c"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a3875502345a04fa0ac8d66612487cd8f">This syntax specifies the error tolerance of a single node.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_aed4ad94cd3094eecbd206f2866c569e8">Examples of data format errors include the following: a column is lost, an extra column exists, a data type is incorrect, and encoding is incorrect. When a non-data format error occurs, the whole data import process stops.</p>
|
||
</div></div>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a0cb84298c06c4bf09bd767ecd16691b0">Value range: integer, unlimited. If this parameter is not specified, an error information is returned immediately.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l77f3709f3dba4ac391004061141e1420"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_abd10786444174ef8ada8a7991c7c6e41">NOT ENFORCED</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a087786ef11c04cf8a88ffe2c90a0a28f">Specifies the constraint to be an informational constraint. This constraint is guaranteed by the user instead of the database.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lcc9e76584cbf4024ba004bdaaa57f2ea"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5873764584264cc9a60171b4a9becab5">ENFORCED</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ac30d459b0baa4ffd87529b803ddf3f67">The default value is <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0058966095_b84235270610317">ENFORCED</strong>. <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b1086465600202141">ENFORCED</strong> is a reserved parameter and is currently not supported.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l42512b0b4f3b4b80b4105fcafff5df49"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a532505eaa58b4af4b14ba1c33e50a82c">PRIMARY KEY (column_name)</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_acd245a72d984492fa04ec8c13620a30d">Specifies the informational constraint on <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706163930">column_name</strong>.</p>
|
||
<p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a4a232eb32ed84b73b739add407e298ac">Value range: a string. It must comply with the naming convention, and the value of <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0058966095_b842352706102528">column_name</strong> must exist.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l5edb5d8718504007bf5249f3c13b38e5"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a34ff9b9010f24ab8864eaf2e25721c9a">ENABLE QUERY OPTIMIZATION</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a6677a8c82bb649f49066a2d7e4428506">Optimizes the query plan using an informational constraint.</p>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l74ae7322a320480c928b507e46b93089"><strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_af142a460b18e408cbbd1ec5a576eea0c">DISABLE QUERY OPTIMIZATION</strong><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ad3dc8bfc2f2a4eeb965580a503a8a75d">Disables the optimization of the query plan using an informational constraint.</p>
|
||
</li></ul>
|
||
</div>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s3fde6b20698e41f68c609bed8acd9bcd"><h4 class="sectiontitle">Examples</h4><div class="p" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a5eba59ebef0d40b690b1ba75797cb822">Create a foreign table named <strong id="EN-US_TOPIC_0000001233430207__b1135792025011">OBS_ft</strong> to import data in the .txt format from OBS to the <strong id="EN-US_TOPIC_0000001233430207__b148312917490">row_tbl</strong> table.<div class="notice" id="EN-US_TOPIC_0000001233430207__note1299481971819"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="EN-US_TOPIC_0000001233430207__p982411264181">// Hard-coded or plaintext AK and SK are risky. For security purposes, encrypt your AK and SK and store them in the configuration file or environment variables.</p>
|
||
</div></div>
|
||
<div class="codecoloring" codetype="Sql" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_sd66611f06f914110915e6fb06f2cc030"><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"> 3</span>
|
||
<span class="normal"> 4</span>
|
||
<span class="normal"> 5</span>
|
||
<span class="normal"> 6</span>
|
||
<span class="normal"> 7</span>
|
||
<span class="normal"> 8</span>
|
||
<span class="normal"> 9</span>
|
||
<span class="normal">10</span>
|
||
<span class="normal">11</span>
|
||
<span class="normal">12</span>
|
||
<span class="normal">13</span>
|
||
<span class="normal">14</span>
|
||
<span class="normal">15</span>
|
||
<span class="normal">16</span>
|
||
<span class="normal">17</span></pre></div></td><td class="code"><div><pre><span></span><span class="k">DROP</span><span class="w"> </span><span class="k">FOREIGN</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">OBS_ft</span><span class="p">;</span>
|
||
<span class="n">NOTICE</span><span class="p">:</span><span class="w"> </span><span class="k">foreign</span><span class="w"> </span><span class="k">table</span><span class="w"> </span><span class="ss">"obs_ft"</span><span class="w"> </span><span class="n">does</span><span class="w"> </span><span class="k">not</span><span class="w"> </span><span class="n">exist</span><span class="p">,</span><span class="w"> </span><span class="n">skipping</span>
|
||
<span class="k">DROP</span><span class="w"> </span><span class="k">FOREIGN</span><span class="w"> </span><span class="k">TABLE</span>
|
||
|
||
<span class="k">CREATE</span><span class="w"> </span><span class="k">FOREIGN</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="n">OBS_ft</span><span class="p">(</span><span class="w"> </span><span class="n">a</span><span class="w"> </span><span class="nb">int</span><span class="p">,</span><span class="w"> </span><span class="n">b</span><span class="w"> </span><span class="nb">int</span><span class="p">)</span><span class="n">SERVER</span><span class="w"> </span><span class="n">gsmpp_server</span><span class="w"> </span><span class="k">OPTIONS</span><span class="w"> </span><span class="p">(</span><span class="k">location</span><span class="w"> </span><span class="s1">'obs://gaussdbcheck/obs_ddl/test_case_data/txt_obs_informatonal_test001'</span><span class="p">,</span><span class="n">format</span><span class="w"> </span><span class="s1">'text'</span><span class="p">,</span><span class="k">encoding</span><span class="w"> </span><span class="s1">'utf8'</span><span class="p">,</span><span class="n">chunksize</span><span class="w"> </span><span class="s1">'32'</span><span class="p">,</span><span class="w"> </span><span class="n">encrypt</span><span class="w"> </span><span class="s1">'on'</span><span class="p">,</span><span class="n">ACCESS_KEY</span><span class="w"> </span><span class="s1">'access_key_value_to_be_replaced'</span><span class="p">,</span><span class="n">SECRET_ACCESS_KEY</span><span class="w"> </span><span class="s1">'secret_access_key_value_to_be_replaced'</span><span class="p">,</span><span class="k">delimiter</span><span class="w"> </span><span class="n">E</span><span class="s1">'\x08'</span><span class="p">)</span><span class="w"> </span><span class="k">read</span><span class="w"> </span><span class="k">only</span><span class="p">;</span>
|
||
<span class="k">CREATE</span><span class="w"> </span><span class="k">FOREIGN</span><span class="w"> </span><span class="k">TABLE</span>
|
||
|
||
<span class="k">DROP</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="n">row_tbl</span><span class="p">;</span>
|
||
<span class="k">DROP</span><span class="w"> </span><span class="k">TABLE</span>
|
||
|
||
<span class="k">CREATE</span><span class="w"> </span><span class="k">TABLE</span><span class="w"> </span><span class="n">row_tbl</span><span class="p">(</span><span class="w"> </span><span class="n">a</span><span class="w"> </span><span class="nb">int</span><span class="p">,</span><span class="w"> </span><span class="n">b</span><span class="w"> </span><span class="nb">int</span><span class="p">);</span>
|
||
<span class="n">NOTICE</span><span class="p">:</span><span class="w"> </span><span class="n">The</span><span class="w"> </span><span class="s1">'DISTRIBUTE BY'</span><span class="w"> </span><span class="n">clause</span><span class="w"> </span><span class="k">is</span><span class="w"> </span><span class="k">not</span><span class="w"> </span><span class="n">specified</span><span class="p">.</span><span class="w"> </span><span class="k">Using</span><span class="w"> </span><span class="s1">'a'</span><span class="w"> </span><span class="k">as</span><span class="w"> </span><span class="n">the</span><span class="w"> </span><span class="n">distribution</span><span class="w"> </span><span class="k">column</span><span class="w"> </span><span class="k">by</span><span class="w"> </span><span class="k">default</span><span class="p">.</span>
|
||
<span class="n">HINT</span><span class="p">:</span><span class="w"> </span><span class="n">Please</span><span class="w"> </span><span class="n">use</span><span class="w"> </span><span class="s1">'DISTRIBUTE BY'</span><span class="w"> </span><span class="n">clause</span><span class="w"> </span><span class="k">to</span><span class="w"> </span><span class="n">specify</span><span class="w"> </span><span class="n">suitable</span><span class="w"> </span><span class="k">data</span><span class="w"> </span><span class="n">distribution</span><span class="w"> </span><span class="k">column</span><span class="p">.</span>
|
||
<span class="k">CREATE</span><span class="w"> </span><span class="k">TABLE</span>
|
||
|
||
<span class="k">INSERT</span><span class="w"> </span><span class="k">INTO</span><span class="w"> </span><span class="n">row_tbl</span><span class="w"> </span><span class="k">SELECT</span><span class="w"> </span><span class="o">*</span><span class="w"> </span><span class="k">FROM</span><span class="w"> </span><span class="n">OBS_ft</span><span class="p">;</span>
|
||
<span class="k">INSERT</span><span class="w"> </span><span class="mi">0</span><span class="w"> </span><span class="mi">3</span>
|
||
</pre></div></td></tr></table></div>
|
||
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_sff255b9a5749451d8b2a980e0dfded6b"><h4 class="sectiontitle">Helpful Links</h4><p id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_a207b4c6b6fbb42588e2656ff8670f95c"><a href="dws_06_0124.html">ALTER FOREIGN TABLE (for HDFS or OBS)</a>, <a href="dws_06_0192.html">DROP FOREIGN TABLE</a></p>
|
||
</div>
|
||
<div class="section" id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_s8ca29ec343f74fc782019d60a0e0607c"><h4 class="sectiontitle">Optimization</h4><ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_udb6fc741e83945fa97f7a06776c5d9ed"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l97b9a65cc1954a5abc41d1c78caa725a">delimiter<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_ue369f9cf55f54d56a7772c5c609d92a2"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l1be23a90fd4c4402be63b8faa2e3ac70">A delimiter cannot be <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b190719013294">\r</strong> or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b10285412298">\n</strong>, or the same as the <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706191023">null</strong> value. The delimiter of CSV cannot be same as the <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b842352706191016">quote</strong> value.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l6579ffa58b6549b891a95e2663ad406b">The data length of a single row should be less than 1 GB. A row that has many columns using long delimiters cannot contain much valid data.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l3780df62eb24464d882a21a087f0c0c9">You are advised to use a multi-character string, such as the combination of the dollar sign ($), caret (^), and ampersand (&), or invisible characters, such as 0x07, 0x08, and 0x1b as the delimiter.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l6cba753a63c445f6b8b3723bda0e6471">quote<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u5fb02202312244889463f331bdc8fa68"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l4921307e7e374723914f542994c0d1ce">The value must be a single-byte character. The <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b161781961473">quote</strong> value cannot be the same as the delimiter or <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b11801367719">null</strong> value.</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_le0711c4dd24b460698a033ac41a66172">Invisible characters are recommended as <strong id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_b8461211575">quote</strong> values, such as 0x07, 0x08, and 0x1b.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l620b8f05a59c45818682a9d725d709a3">mode Normal<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u945dcbc4ebcf4085afc55693a34ca531"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l90cbfde46d1840b1b731cbb4e37d9f44">Supports all file types (including CSV, TEXT, and FIXED). To import data, you need to enable GDS on the data server.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_lbd442989a8114ff78d00b875d1da0eb4">mode Shared<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_u9751999e13254ff3aef5775041968444"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l42fc8207cf494b17959d641bc5757ddf">Supports the TEXT format. It does not require GDS, but all the user data has to be mounted to the same path of all the nodes through NFS.</li></ul>
|
||
</li><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_l3217fa95af6a45dabf6e97ce909dc0ef">mode Private<ul id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_uab2dc1ab8d6c4c23920b039c9a08210c"><li id="EN-US_TOPIC_0000001233430207__en-us_topic_0000001098811114_en-us_topic_0117407717_la880ea1d264a46358361157292e245b3">Used in scenarios where user data has been stored under the same path as the local directory of DNs.</li></ul>
|
||
</li></ul>
|
||
</div>
|
||
</div>
|
||
<div>
|
||
<div class="familylinks">
|
||
<div class="parentlink"><strong>Parent topic:</strong> <a href="dws_06_0118.html">DDL Syntax</a></div>
|
||
</div>
|
||
</div>
|
||
|