I have installed Toad For MYSQL 7.0.0.2038 and I am experiencing a problem with SQL formatting Toad puts all my SQL into one line. When I open a VIEW and go to the Script tab my SQL appears as in the sample below. CREATE VIEW `database`.`table_v` AS select `field`.`id` AS `id`,`field`.`user_id` AS `user_id`,`ua`.`display_name` AS `display_name`,`field`.`user_type_id` AS `user_type_id`,`uta`.`name` AS `user_type`,`field`.`source_id` AS `source_id`,`tst`.`name` AS `source`,`field`.`author_id` AS `author_id`,(case when (`field`.`user_type_id` = 1) then `ua`.`display_name` when (`field`.`user_type_id` = 2) then `taa`.`name` else `ua`.`display_name` end) AS 'author' When I use Notepad or NaviCat my SQL appears as CREATE VIEW table_v AS SELECT field.id, field.user_id, ua.display_name, field.user_type_id, uta.name AS user_type, field.source_id, tst.name AS source, field.author_id, CASE WHEN field.user_type_id = 1 THEN ua.display_name WHEN field.user_type_id = 2 THEN taa.name ELSE ua.display_name END AS author, Toad has managed to convert SELECT, CASE, WHEN, THEN, ELSE and END to lower case. It has also added '' around object names and added AS I would like Toad to display the SQL as it appears in Navicat and notepad. I have altered Editor settings to no avail. Can anybody shed any light on How to do this? Many thanks, Bill
↧