Page 1 of 1
[Solved] Cannot save a carriage return in a Query
Posted: Thu Sep 20, 2018 9:33 pm
by det
I enter the Query:
SELECT A, B, C
FROM Table
AS Name
Then I save it and close it. When I re-open the Query, I get:
SELECT A, B, C FROM Table AS Name
This is very annoying with long Queries. Is there a setting somewhere to fix it?
Thanks for any help
Det
Re: Cannot save a carriage return in a Query
Posted: Thu Sep 20, 2018 9:56 pm
by Sliderule
det wrote:This is very annoying with long Queries. Is there a setting somewhere to fix it?
Yes.
After you open and write your Query, before you save it,
either:
- From the Menu: Edit -> Run SQL command directly
Make sure above has a check mark next to it
- From the Toolbar:
Click on the icon: Run SQL command directly ( SQL command with a GREEN check mark )
Explanation:- The above means, the Base Parser will NOT check the Query before running it, NOR before executing your Query. Therefore, you canNOT use the Query as a Parameter Query ( to prompt user for input before executing it ).
- Additionally, when a Query is saved to Run Directly, you CAN, if you want, add comments to the Query, by using two dashes. For example:
Code: Select all
-- This Query is to be saved and run directly withOUT the Base Parser being involved
SELECT
A, -- This column will display the information from A
B,
C
FROM Table AS Name -- This is an example of the tables I want to use
I hope this helps, please be sure to let me / us know.
Sliderule
Thanks to add
[Solved] in your
1st post Subject (edit button top right) if this issue has been resolved.
Re: Cannot save a carriage return in a Query
Posted: Thu Sep 20, 2018 10:30 pm
by det
Solved
Thanks so much for detailed explanation. Works perfectly.