Red Gate forums :: View topic - New Feature Request
Return to RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Refactor 1
SQL Refactor 1 forum

New Feature Request

Search in SQL Refactor 1 forum
Post new topic   Reply to topic
Jump to:  
Author Message

Joined: 27 Aug 2008
Posts: 2
Location: Oklahoma

PostPosted: Thu Dec 02, 2010 8:34 pm    Post subject: New Feature Request Reply with quote

I have used SQL Refactor for a while now and really appreciate the features that make it easier to understand existing code, which is what I use it for the most. However, I would like to propose a new feature. I would really like to see a tool in SQL Refactor to remove all unnecessary table aliases. By unnecessary I mean any alias in a query where the table that is aliased only appears once. If the table is joined in twice, like for a self-join, then just leave those alias(s) alone, but remove any other aliases that may appear in the query and replace the alias names with qualified names.

The reason that I’m interested in this feature is two-fold. One, when learning a new schema, I think that it is enough to have to learn one name for each table. To have to learn two names for a table ought to be unnecessary. Secondly, I have run into something I never thought I would see: a stored procedure where the same table in different queries in the procedure are aliased to different values. For example, in one query in the stored procedure the table ‘KpiValue’ is aliased to ‘v’ and in the next query in the same procedure it is aliased to ‘kv’. Yuck.

It seems to me that SQL Refactor probably already has a lot of the stuff in it that this feature would need, so I hope that it wouldn’t be too difficult of a feature to add. Thank you for your time.
Back to top
View user's profile Send private message
Linda Hawksworth

Joined: 25 Jun 2007
Posts: 192

PostPosted: Mon Dec 06, 2010 1:24 pm    Post subject: Reply with quote

Many thanks for your suggestion. I have logged it in our tracking system with reference SP-3639 (logged against SQL Prompt 5 as SQL Prompt and SQL Refactor are being merged into SQL Prompt v5.).
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Powered by phpBB © 2001, 2005 phpBB Group