Rather than Code Templates, perhaps creating your own code fragments in the Snippets view, then dragging & dropping them into the editor may be preferable. Snippets are copied into the editor without reformatting.
If you wish to stay with the templates, then review settings in Tools > Preferences > Database > SQL Formatter. Edit a profile (to be safe, Save As something else), then check the Line Breaks settings, especially Max Line Width, and Threshold for small SQL. Smaller values for these will force line breaks. However getting the formatter to do everything you want may not be possible.
SQL Developer Team
1 person found this helpful
Bugged as 19509117
@Gary - thanks for the suggestions, but I like the code template mechanism more than DnD - it's a bit quicker and doesn't require taking my hands off the keyboard...
@Vadim - I can't get access to Metalink since it's a corporate account - is this a previously known defect, or did you create a new one for me (in which case Thanks )?
BTW - I forgot to mention that I'm 96.2% certain this reformatting didn't happen in version 3.x...
We agreed with you and logged the bug. Should be fixed in our next major release.
Ok - thanks...
Any comment on the request for cursor positioning?