This topic describes how to create a Tablestore data source discovery task by using the wizard. In a discovery task, Data Lake Analytics (DLA) automatically discovers all Tablestore instances and tables (including new instances and tables) in your region and creates mappings between DLA databases and Tablestore instances as well as Tablestore tables.
- Log on to the DLA console.
- In the left-side navigation pane, choose .
- In the Tablestore data source section of the Meta information discovery page, click Go to The Wizard.
- On the Tablestore data source tab, configure the parameters as prompted. The following table describes the parameters.
Parameter Description Scheduling frequency The frequency at which the Tablestore data source discovery task is scheduled. Specific time The time at which the Tablestore data source discovery task is executed. schema prefix The prefix of the schema, which is the prefix of the name of the database that is mapped to DLA. The schema is named in the format of Custom prefix_Tablestore instance name. The name of the table generated in DLA is the same as the name of the object that is associated with the table of the Tablestore instance. Configuration options (optional) Advanced custom settings, including Sampling source and Number of samples.
- After you configure the preceding parameters, click Create to create a Tablestore data source discovery task.
- After the task is created, click Immediately discovered to run the task.
You can view the information of a created task on the Task List tab. The Tablestore data source discovery task is manually executed or automatically executed at a scheduled time based on Scheduling frequency.After the task succeeds, click the database name in the schema name/prefix column on the Task List tab to go to the page. In this example, the database name is tablestore20201231. You can view the created databases, tables, and columns that are automatically discovered by DLA.
- On the Execute page, edit SQL statements in the code editor and click Sync Execute(F8) or Async Execute(F9) to execute the SQL statements.
For example, run
select * from `tablestore20201231_benchmark01`.`test000` where `key` = '' limit 20;under tablestore20201231_benchmark01.