<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                **1. 外部表的特點:** <mark>1. 在hive中刪除了外部表,只刪除該表在mysql中對應的元數據,HDFS上的數據不會被刪除。</mark> <mark>2. 在hive中的任何操作,不會對存儲在hdfs上的數據產生任何影響,它只是影響了存儲在mysql中的元數據,所以不用擔心數據被損壞。</mark> <br/> **2. 創建 dept 外部表,并導入linux中的 dept.txt 的數據到 dept 表中** *`dept.txt`* ```txt 10 ACCOUNTING 1700 20 RESEARCH 1800 30 SALES 1900 40 OPERATIONS 1700 ``` (1)創建 dept 外部表 ```sql create external table if not exists dept( dept_no int, dept_name string, loc int ) -- dept中行的分割符為 \t row format delimited fields terminated by '\t'; ``` (2)導入 dept.txt 到 dept 表中: ```shell #### 到入到 dept 表中 #### 0: jdbc:hive2://hadoop101:10000> load data local inpath "/opt/install/hive/mydata/dept.txt" into table dept; 0: jdbc:hive2://hadoop101:10000> select * from dept; +---------------+-----------------+-----------+--+ | dept.dept_no | dept.dept_name | dept.loc | +---------------+-----------------+-----------+--+ | 10 | ACCOUNTING | 1700 | | 20 | RESEARCH | 1800 | | 30 | SALES | 1900 | | 40 | OPERATIONS | 1700 | +---------------+-----------------+-----------+--+ ``` 在hdfs中存儲為 dept.txt 文件 ![](https://img.kancloud.cn/c5/cb/c5cbc4de722c162d469485f30d3473e9_1500x194.png)
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看