Queries the status of a specified instance. If the instance is created by a different user, an error is returned when you query the status of this instance.


status <instance_id>;


instance_id: required. The ID of an instance whose status you want to query. Each instance ID is unique.

Return result

An instance can be in one of the following states:
  • Running: The instance is running.
  • Success: The instance operation succeeds.
  • Waiting: The instance is waiting to run.
  • Failed: The job fails, but the data in the destination table is not modified.
  • Cancelled: The instance is stopped.
  • Terminated: The job is completed.


-- Query the status of the instance whose ID is 20131225123xxxxxxxxxxxxxxx. 
status 20131225123xxxxxxxxxxxxxxx;
The following result is returned:

Related statements

  • SHOW: Views the information about an instance. The information includes StartTime (accurate to the second), RunTime (in seconds), Status, InstanceID, Owner, and Query statements.
  • TOP INSTANCE: Views the information about instances that are running in a project.
  • KILL: Stops a specific instance.
  • DESC INSTANCE: Obtains job information based on a specified instance ID. The information includes SQL, Owner, StartTime, EndTime, and Status.
  • WAIT: Obtains the run log of jobs based on a specified instance ID. The log includes the Logview URLs of the jobs.