Install the console
|Make sure you have JRE 1.7 or a later version installed to properly use the MaxCompute console.|
- Download the MaxCompute console.
- Decompress it into a folder. After decompression, you can see four following folders:
bin/ conf/ lib/ plugins/
Configure the Console
A file called odps_config.ini is in the conf folder. Edit it by filling in corresponding information to configure the console:
access_id=******************* access_key=********************* #Your AccessKeyId and AccessKeySecret. You can apply for an AccessKey through the official Alibaba Cloud console. project_name=my_project # Specify the project you want to use. end_point=https://service.odps.aliyun.com/api # Access URL of the MaxCompute service. tunnel_endpoint=https://dt.odps.aliyun.com # Access URL of the MaxCompute Tunnel service. log_view_host=http://logview.odps.aliyun.com # After a user executes a task, the console returns the LogView address of this task. You can view the detailed execution information of this task at this address. https_check=true # Determine whether to enable HTTPS access.
Run the console
After the configuration file has been modified, run MaxCompute in bin directory(For Linux, run ./bin/odpscmd, for Windows, run ./bin/odpscmd.bat). For example:
create table tbl1(id bigint); insert overwrite table tbl1 select count(*) from tbl1; select 'welcome to MaxCompute!' from tbl1;
For more information about SQL statements, see SQL Summary.