Two feature requests

Discussion of open issues, suggestions and bugs regarding database management and development tools for SQL Server
Post Reply
Chris123
Posts: 8
Joined: Wed 04 Apr 2012 09:21

Two feature requests

Post by Chris123 » Wed 04 Apr 2012 09:33

Hello,

I am just starting to use SQL Complete (Express due to budget). I would like to make a couple of suggestions for your excellent product:

1) Is it possible to have an option to generate square brackets [ ] around columns names and possibly other objects such as tables?

2) I understand that Express does not auto-generate aliases, but if I enter an upper case alias is it possible to get SQL Complete to honour this and generate column names with an upper case alias prefix?

Cheers,

Chris

alexa

Post by alexa » Wed 04 Apr 2012 11:12

Hello,
1) Is it possible to have an option to generate square brackets [ ] around columns names and possibly other objects such as tables?
We already have such a suggestion on our dbForge SQL Complete forum at UserVoice. We've just voted for it on your behalf: http://devart.uservoice.com/forums/8789 ... mn-name-en
2) I understand that Express does not auto-generate aliases, but if I enter an upper case alias is it possible to get SQL Complete to honour this and generate column names with an upper case alias prefix?
Yes, SQL Complete generates an alias prefix for column names in the case it was defined.

Chris123
Posts: 8
Joined: Wed 04 Apr 2012 09:21

Post by Chris123 » Wed 04 Apr 2012 14:06

Thanks for replying so quickly Alexa.

1) Thanks

2) This is not what I am seeing. If I type

Code: Select all

SELECT * FROM CTL_A
and then hit TAB then CTL_A is correctly expanded to CTL_Actions (without an alias) so I add one. I then have

Code: Select all

SELECT * FROM CTL_Actions A
If I go back and delete the * and type CTRL+Space I get intellisense showing me an aliased object A with three possible columns. If I choose one and hit enter I get

Code: Select all

SELECT LastOccurredDate FROM CTL_Actions A
where I would expect to get

Code: Select all

SELECT A.LastOccurredDate FROM CTL_Actions A
I have the latest version of SQL Complete Express installed and am using SSMS 2005.

alexa

Post by alexa » Thu 05 Apr 2012 09:03

Hello Chris,

In the example you provided, the alias is not generated in the SELECT clause since there is the only table mentioned in the FROM clause, so it is assumed that the 'LastOccurredDate' field relates to this only table.

If there are more than one table used in a query, aliases are inserted in the case you define them in the FROM clause. Please note that aliases are also not generated if there are no duplicate field names among the tables mentioned in the query.

Chris123
Posts: 8
Joined: Wed 04 Apr 2012 09:21

Post by Chris123 » Thu 05 Apr 2012 10:20

Okay, thanks. I understand the reasoning for a single table select. However if there is a join across two aliased tables then I think it is a mistake not to add the alias to all the columns for the sake of clarity. Only doing it when columns share the same name across the tables does not seem right. Could I ask to add this as a feature request? A configuration option could be used to disable it for users who prefer the existing functionality.

On a more positive note I have found that if I type ALIAS.[ and select a column from the intellisense then I get ALIAS.[ColumnName] which is perfect :lol:

Thanks for taking the time to reply,

Chris

alexa

Post by alexa » Thu 05 Apr 2012 11:15

if there is a join across two aliased tables then I think it is a mistake not to add the alias to all the columns for the sake of clarity. Only doing it when columns share the same name across the tables does not seem right. Could I ask to add this as a feature request? A configuration option could be used to disable it for users who prefer the existing functionality.
We've just found a similar suggestion on our UserVoice forum and voted for it on your behalf: http://devart.uservoice.com/forums/8789 ... on-columns

Chris123
Posts: 8
Joined: Wed 04 Apr 2012 09:21

Post by Chris123 » Thu 05 Apr 2012 12:59

Thank you

Post Reply