20
votes

I would like to highlight some text in a SQL Developer worksheet and convert it to uppercase with some keyboard shortcut.

Is there any such shortcut in Oracle SQL Developer?

I am using version 4.1.2.

10

10 Answers

24
votes

Under Tools->Preferences->Shortcut Keys you can find and/or define the shortcut key combination for the Convert Selection to Uppercase and Convert Selection to Lowercase commands. I have mine mapped to CTRL+U and CTRL+L respectively. There unfortunately does not appear to be a specific command for converting text to Initcap, so the To Upper/Lower/Initcap command is the way to go for that. However, be aware that the To Upper/Lower/Initcap command actually cycles between five format modes:

  • UPPERCASE
  • lowercase
  • Initcap
  • Lower Keywords, Upper Identifiers
  • Upper Keywords, Lower Identifiers

Some of these modes will change the behavior of the code formatter (default key sequence CTRL+F7), and the Tools->Preferences->Code Editor->Completion Insight->Change case as you type setting if you have it enabled.

13
votes

in 4.2.0.17 highlight the word(s) then Alt + '

4
votes

This is perhaps and old question, but I noticed that while on Mac, the keyboard shortcut for cycle is unbound.

I followed the above suggestions in

tools->preferences->shortcuts

and bound it myself to ctrl + ' but note that in 4.2 on Mac by default this is unbound.

3
votes

This cycles through Upper/Lower/Initcap in my SQL Developer version 18.2.0.183 Build 183.1748.

ALT + '

2
votes

Ctrl + ' changes case by default. You can find all shortcuts in:

tools->preferences->shortcuts
2
votes

Found it! You can select text in your worksheet, then use Ctrl+Shift+" to switch between cases (in version 4.1.2).

It will cycle between the following cases:

Upper Case:

SELECT * FROM MYSCHEMA.EXAMPLE;

Lower Case:

select * from myschema.example;

Upper Keywords:

SELECT * FROM myschema.example;

Lower Keywords, Upper Identifiers:

select * from MYSCHEMA.EXAMPLE;

Upper Keywords, Lower Identifiers:

SELECT * FROM myschema.example;

Initial Cap:

Select * From Myschema.Example;

As mentioned by @PiotrSiekierski, you can change the keyboard shortcuts in Tools -> Preferences -> Shortcut Keys. In version 4.1.2, the Ctrl+' shortcut is mapped to 'Navigate Down' by default.


As mentioned by @Sentinel, if you are not interested in cycling through the different case options, you can assign a shortcut to 'Convert Selection to Uppercase' or 'Convert Selection to Lowercase' by going to Tools -> Preferences -> Shorcut Keys and searching for the desired functionality. You can then assign a shortcut to those commands, such as Ctrl+U or Ctrl+L. In version 4.1.2, the 'Convert Selection to Uppercase' and 'Convert Selection to Lowercase' commands have no shortcut mapping by default.

1
votes

This cycles through Upper/Lower/Initcap.

CTRL + '

0
votes

Use

Control + '

Everytime you press it, it toggles between camel case, lower case, and upper case. I hope this helped you.

My SQL dev is 18.4. It worked for me

0
votes

In newest versions you can highlight the text and then go to: Tools >> PL/SQL Beautifier and this will format your query and uppercase the text!

Hope it helps.

0
votes

In sql server selected text Convert in to upper case and lower case use this shortcut key

  1. Upper Case : ctr + shift + U
  2. Lower Case : ctr + shift + L