Bug #66941 The indentation of queries is not carried forward to next line
Submitted: 24 Sep 2012 7:30 Modified: 28 Aug 2014 21:55
Reporter: Pankaj Agarwal Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:5.2.42, 5.2.43 OS:Microsoft Windows
Assigned to: CPU Architecture:Any
Tags: indentation

[24 Sep 2012 7:30] Pankaj Agarwal
Description:
In the previous versions when a query was written using indentation (basically using tab) then after pressing enter the cursor move back to the very first column of the line instead of the tabbed position as in the previous line

How to repeat:
write a query in the following format (the instructions in brackets indicate the keys on keyboard)
1. select * from 
2. (press enter, press-tab) 
3. table1
4. (press enter)
5. join table2 on table1.col1 = table2.col2;
 in previous versions the query used to appear as

select * from 
    table1
    join table2 on table1.col1 = table2.col2;

but now it appears as

select * from 
    table1
join table2 on table1.col1 = table2.col2;
[24 Sep 2012 11:55] MySQL Verification Team
Thank you for the bug report.
[28 Aug 2014 21:55] Philip Olson
Fixed as of the upcoming MySQL Workbench 6.2.2 release, and here's the changelog entry:

Indentation is now respected in the SQL and code editors, when before the
current indention level would be forgotten. New lines now start at the
previous indention level.

See also MySQL Bug #70138

Thank you for the bug report.