Documentation Home
MySQL Shell for VS Code


MySQL Shell for VS Code  /  JavaScript  /  Global Functions for JavaScript

8.1 Global Functions for JavaScript

The available global functions for JavaScript in DB Notebooks are:

  • print(value: any): void

    Send a value to the output area.

  • runSql(code: string, callback?: (res:IResultSetRow[]) => void), params?: unknown): void

    Run the given query.

  • runSqlIterative(code: string, callback?: (res: IResultSetData) => void, params?: unknown): void

    Run the given query and process the rows iteratively.