How Do I Specify an OBS Path When Creating an OBS Table?
Scenario
When creating an OBS table, you must specify a table path in the database. The path format is as follows: obs://xxx/database name/table name.
For details about the syntax for creating OBS tables, see Creating an OBS Table Using the DataSource Syntax.
Correct Example
CREATE TABLE `di_seller_task_activity_30d` (`user_id` STRING COMMENT' user ID...) SORTED as parquet LOCATION 'obs://akc-bigdata/akdc.db/di_seller_task_activity_30d'
Incorrect Example
CREATE TABLE `di_seller_task_activity_30d` (`user_id` STRING COMMENT' user ID...) SORTED as parquet LOCATION 'obs://akc-bigdata/akdc.db'
![](https://support.huaweicloud.com/intl/en-us/dli_faq/public_sys-resources/note_3.0-en-us.png)
If the specified path is akdc.db, data in this path will be cleared when the insert overwrite statement is executed.
Job Development FAQs
- How Do I Merge Small Files?
- How Do I Use DLI to Access Data in an OBS Bucket?
- How Do I Specify an OBS Path When Creating an OBS Table?
- How Do I Create a Table Using JSON Data in an OBS Bucket?
- How Can I Use the count Function to Perform Aggregation?
- How Do I Synchronize DLI Table Data from One Region to Another?
- How Do I Insert Table Data into Specific Fields of a Table Using a SQL Job?
- How Do I Delete Table Data?
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbotmore