Bug #73818 Beautify Query breaks valid SQL containing NOW()
Submitted: 5 Sep 2014 15:50 Modified: 5 Sep 2014 16:49
Reporter: Mike Reid Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:6.2.1 OS:MacOS (10.9.4)
Assigned to: CPU Architecture:Any
Tags: beautify, NOW, SQL

[5 Sep 2014 15:50] Mike Reid
Description:
Attempting to Beautify a SQL query containing NOW() invalidates the SQL, converting it to "NOW ()"

How to repeat:
1. Attempt to beautify the following query in SQL Editor:

SELECT NOW();

2. See resulting invalid SQL:

SELECT NOW ();

Following error is received when you attempt to run the invalid SQL:

Error Code: 1630. FUNCTION [database].NOW does not exist.

Suggested fix:
Properly handle NOW() in SQL Beautify statements
[5 Sep 2014 16:49] MySQL Verification Team
Thank you for the bug report. Duplicate of http://bugs.mysql.com/bug.php?id=73661 .