cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

enabling the cell in Databricks.

KVNARK
Honored Contributor II

Suppose if the query is long one and its commented due to some issues later I wanted to run that cell, is there any shortcut to enable the entire cell. The cell is with 800 lines of code and each line is commented with # symbol and I want to enable it. Please let me know if any shortcut or its just replacing the entire cell without # symbol.

1 ACCEPTED SOLUTION

Accepted Solutions

pvignesh92
Honored Contributor

@KVNARK .​ Hi,

If I understand correctly, you want to either comment or disable comment on your entire cell using a Shortcut.

If that's the case,

  1. To do for the whole cell -> Do a Ctrl + A, then you can use Ctrl + / in Windows. It will add # to all your lines if not commented and remove the # if commented.
  2. To do for selected lines in the cell -> Select those lines, then you can use Ctrl + / in Windows. It will add # to all your lines if not commented and remove the # if commented.

Please let me know if this helps.

View solution in original post

2 REPLIES 2

pvignesh92
Honored Contributor

@KVNARK .​ Hi,

If I understand correctly, you want to either comment or disable comment on your entire cell using a Shortcut.

If that's the case,

  1. To do for the whole cell -> Do a Ctrl + A, then you can use Ctrl + / in Windows. It will add # to all your lines if not commented and remove the # if commented.
  2. To do for selected lines in the cell -> Select those lines, then you can use Ctrl + / in Windows. It will add # to all your lines if not commented and remove the # if commented.

Please let me know if this helps.

KVNARK
Honored Contributor II

@Vigneshraja Palaniraj​ Thank you so much for the reply Vignesh. Finally I got it while doing some R&D. its the same. Thanks!

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group