Show Line Number In Sap Hana Studio Online

How to show line numbers in SAP HANA Studio

Showing line numbers helps when editing SQL, script files, or XS artifacts in SAP HANA Studio (the Eclipse-based IDE). Below are step-by-step instructions, tips for different editors inside the studio, and troubleshooting.

4) Alternate approach: Editor-specific ruler/gutter

SAP Business Application Studio (BAS)

How to enable line numbers

  1. Open SAP HANA Studio.
  2. Go to WindowPreferences.
  3. Navigate to GeneralEditorsText Editors.
  4. Check the box “Show line numbers”.
  5. Click Apply and Close.

Line numbers will now appear in the left gutter of SQL editors, console views, and other text editors. show line number in sap hana studio


Scenario B: Code Performance Tuning

The PlanViz (Visualize Plan) tool in HANA Studio shows operations. When you hover over a costly operator, it often references the line number in your SQLScript that generated the heavy operation. Line numbers connect performance metrics directly to your source code. How to show line numbers in SAP HANA

Method 1: The Quick Toggle (Easiest Way)

This method works universally across most Eclipse-based IDEs, including SAP HANA Studio. Some Eclipse-based editors have a small vertical ruler

  1. Open your SQL Console or SQLScript Editor (double-click a .hdb or .sql file).
  2. Look at the vertical ruler (the gray bar on the far left edge of the editor).
  3. Right-click directly on the vertical ruler.
  4. From the context menu, select "Show Line Numbers."

Result: Numbers will appear immediately next to every line of code.

1. Executive Summary

SAP HANA Studio is the primary development environment for managing SAP HANA databases. When writing SQLScript, creating stored procedures, or debugging calculation views, identifying specific lines of code is essential. By default, the SQL Editor may not display line numbers. This report outlines the procedure to enable this feature to improve code navigation and error resolution.