Red Gate forums :: View topic - Encapsulte as SP - not converting variable to parameters
Return to www.red-gate.com RSS Feed Available

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

Encapsulte as SP - not converting variable to parameters

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



Joined: 21 Jan 2009
Posts: 4

PostPosted: Wed Jul 01, 2009 6:49 pm    Post subject: Encapsulte as SP - not converting variable to parameters Reply with quote

Here is the sproc code that is generated in the preview window:

Code:
CREATE PROCEDURE dbo.EncapsulatedProcedure AS
BEGIN
DECLARE @actno VARCHAR(19)
SET @actno = '1234'
SELECT  *
FROM    dbo.tblAccountOHD
WHERE   AccountNo = @actno
END


As you can see, a variable is declared, set and used, but stays a local variable. I've tried this on a number of different queries and the locals NEVER become params. What gives?

BTW, I've re-started SSMS 2005 and the results are the same.
Back to top
View user's profile Send private message
Giggles220



Joined: 07 Dec 2006
Posts: 114
Location: Albany, NY

PostPosted: Thu Jul 02, 2009 1:52 pm    Post subject: Reply with quote

I've had the same problem and since I haven't tried to use it that often I always assumed I was doing something wrong. It would be nice to know why it doesn't put the parameter in or what we have to do so that it will
Back to top
View user's profile Send private message
Anu Deshpande



Joined: 20 Apr 2009
Posts: 685
Location: Cambridge

PostPosted: Thu Jul 02, 2009 2:50 pm    Post subject: Reply with quote

Thnaks for your post and apologise that you have encountered this issue with SQL Refactor.

I was able to replicate this issue at our end.

I have raised this bug in our internal tracking system so that development team can look into it and incorporate in future release. Bug tracking number for that issue is SR-849.

Kindly let me know if you have any other issues regarding SQL refactor, I'll like to help.
_________________
Anuradha Deshpande
Product Support
Redgate Software Ltd.
E-mail: support@red-gate.com
Back to top
View user's profile Send private message Send e-mail
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