SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
Refactoring - Extract...

 
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant View previous topic
View next topic
Refactoring - Extract...
Author Message
gemisigo



Joined: 11 Mar 2010
Posts: 2109

Post Refactoring - Extract... Reply with quote
Refactoring - Extract View/Procedure pops up a window containing the generated code. The caption of Cancel button is btnCancel which is a fit funny :)

By the way, why is there no Extract Function?
Sun Jun 20, 2010 5:15 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7849

Post Reply with quote
Thanks for pointing to incorrect button caption.

I'm not sure why there is no separate "extract function" method. But I think it should be possible to modify the code of the "extract procedure" and "procedure call" templates and make them conditionally generate "CREATE PROCEDURE" or "CREATE FUNCTION" based on the name. For example, if the name begins with sp prefix generate new procedure, otherwise generate new function. $$..$$ macros can be used to add such logic to the template code.
Sun Jun 20, 2010 11:30 am View user's profile Send private message
gemisigo



Joined: 11 Mar 2010
Posts: 2109

Post Reply with quote
Thanks for the idea, I already began to alter the template to customize it to my prefixes. The tooltip says that the name of the refactoring rule controls where the template will be used. That means there's not much sense to create new ones, right?
Sun Jun 20, 2010 11:54 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7849

Post Reply with quote
As far as I understand it is looking for a specific template name for every specific operation type. Tat's why refactoring template names appear in brackets to indicate their special meaning. Adding new templates makes sense only if you deactivate or rename old templates and keep them in the config and name new templates as old ones.

PS. More types of code refactoring methods should be introduced in future versions.
Sun Jun 20, 2010 4:17 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
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
Design by Freestyle XL / Flowers Online.