Viewing SQL history

SQL history lists the SQL statements that users ran in a project, with their status, user, and time. Use it to find a statement again and to reuse it in the SQL editor.

  1. In the Streaming SQL Console, click Projects in the left navigation pane, and click the name of your project.
    The project opens, with the Explorer panel on the left. To open the Streaming SQL Console, see Accessing Cloudera SQL Stream Builder.
  2. In the Explorer, click a job.
    The job opens in the SQL editor.
  3. Expand the Details panel of the workspace.
  4. Click the SQL History icon.
    The SQL History list opens. Each entry displays the statement, an icon that indicates whether it succeeded or failed, the user who ran it, and when it ran. If the project has no history yet, the list displays No history items.
  5. Optional: Optional: Enter text in the Search in History box to display only the statements that contain the text.
  6. Optional: Optional: Click the Refresh icon to load the latest statements.
  7. Optional: Optional: Click an entry to put its statement into the SQL editor of the job that is open.
    The statement replaces the content of the SQL editor. If no job tab is open, clicking an entry does nothing. Save your changes first.