﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum / StrataFrame Database Deployment Toolkit / Issues  / Stored Proc Issue / Latest Posts</title><generator>InstantForum.NET v4.1.4</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>forum@strataframe.net</webMaster><lastBuildDate>Mon, 13 Oct 2008 16:11:03 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Stored Proc Issue</title><link>http://forum.strataframe.net/Topic12876-13-1.aspx</link><description>Hrm... that is strange.  I can't remember the code explicitly, but we might be trying to Regex off the AS on the front, and if we don't find one, we add it.  Maybe your sproc doesn't pass our Regex, so we can't find out that the AS is missing.  I can't remember. &lt;/P&gt;&lt;P&gt;However, if you posted an example sproc of one that deploys fine without the AS and one that requires the AS to deploy, then I might be able to figure something out.</description><pubDate>Thu, 06 Dec 2007 09:32:14 GMT</pubDate><dc:creator>Ben Chase</dc:creator></item><item><title>RE: Stored Proc Issue</title><link>http://forum.strataframe.net/Topic12876-13-1.aspx</link><description>Chaps,&lt;/P&gt;&lt;P&gt;Thanks for this. Indeed in this case adding the 'AS' does resolve the issue. &lt;/P&gt;&lt;P&gt;What I do have though are other procedures in the DDT, that do not have the AS in the proc, but return only a small number of columns and they have deployed fine.&lt;/P&gt;&lt;P&gt;If you can replicate this I would be interested to know.&lt;/P&gt;&lt;P&gt;thanks Geoff</description><pubDate>Wed, 05 Dec 2007 04:54:18 GMT</pubDate><dc:creator>Geoff Hirst</dc:creator></item><item><title>RE: Stored Proc Issue</title><link>http://forum.strataframe.net/Topic12876-13-1.aspx</link><description>Yep, Peter is right, the AS is not optional, even without parameters.</description><pubDate>Mon, 03 Dec 2007 09:02:11 GMT</pubDate><dc:creator>Ben Chase</dc:creator></item><item><title>RE: Stored Proc Issue</title><link>http://forum.strataframe.net/Topic12876-13-1.aspx</link><description>Are you deploying through the DDT?  &lt;/P&gt;&lt;P&gt;If you are, then pay close attention to the labels of the Stored Procedure form... they list the code that will be executed when deploying the procedure...&lt;/P&gt;&lt;P&gt;After the "CreateProcedure" you would still need to place the AS keyword, event if you don't use any parameters.  So, the textbox would contain:&lt;/P&gt;&lt;P&gt;AS&lt;BR&gt;Select ID,JobNo,ProjectName,WorkDescription,ClientID,ClientContact,ContactDetails,JobManager,JobArchitect, JobType,ClientType,EnduserCLientType,SourceofWork,Timebased,FixedFee,PercentageValueOfProject, ExpensesID,ProjectFee,EstimatedProjectValue,ProjectPercentage,ProjectFee2 from Job</description><pubDate>Mon, 03 Dec 2007 09:01:34 GMT</pubDate><dc:creator>Ben Chase</dc:creator></item><item><title>RE: Stored Proc Issue</title><link>http://forum.strataframe.net/Topic12876-13-1.aspx</link><description>Hi Geoff,&lt;/P&gt;&lt;P&gt;If don't think the AS is optional in a proc, e.g.&lt;/P&gt;&lt;P&gt;CREATE PROCEDURE dbo.myProc &lt;/P&gt;&lt;P&gt;AS&lt;/P&gt;&lt;P&gt;    SELECT * FROM MyTable&lt;/P&gt;&lt;P&gt;GO&lt;BR&gt;&lt;/P&gt;&lt;P&gt;Maybe omitting the AS is causing the problem?&lt;/P&gt;&lt;P&gt;Cheers, Peter</description><pubDate>Sun, 02 Dec 2007 20:06:25 GMT</pubDate><dc:creator>Peter Jones</dc:creator></item><item><title>Stored Proc Issue</title><link>http://forum.strataframe.net/Topic12876-13-1.aspx</link><description>Chaps,&lt;/P&gt;&lt;P&gt;I have a stored proc, that returns the full contents of a table, some 21 columns. Now, I have no parameters on this proc, as I intend to use it for list population etc.&lt;/P&gt;&lt;P&gt;Thing is, it won't deploy. I get an error that says a problem occurred with a stored proc. A problem near the word 'SELECT'.&lt;/P&gt;&lt;P&gt;Now if I add&lt;/P&gt;&lt;P&gt;@ID int&lt;/P&gt;&lt;P&gt;AS &lt;/P&gt;&lt;P&gt;at the top of the proc, it deploys fine.&lt;/P&gt;&lt;P&gt;Proc is&lt;/P&gt;&lt;FONT color=#0000ff size=1&gt;&lt;P&gt;Select&lt;/FONT&gt;&lt;FONT size=1&gt;&lt;FONT color=#000000&gt; ID,&lt;/FONT&gt;JobNo,ProjectName,WorkDescription,ClientID,ClientContact,ContactDetails,JobManager,JobArchitect,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size=1&gt;JobType,ClientType,EnduserCLientType,SourceofWork,Timebased,FixedFee,PercentageValueOfProject,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size=1&gt;ExpensesID,ProjectFee,EstimatedProjectValue,ProjectPercentage,ProjectFee2 &lt;/FONT&gt;&lt;FONT color=#0000ff size=1&gt;from&lt;/FONT&gt;&lt;FONT size=1&gt; Job &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size=1&gt;If I replace the text with SELECT * from Job it also works fine.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size=1&gt;Any Ideas chaps?&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size=1&gt;thanks&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size=1&gt;Geoff&lt;/P&gt;&lt;/FONT&gt;</description><pubDate>Sun, 02 Dec 2007 09:37:40 GMT</pubDate><dc:creator>Geoff Hirst</dc:creator></item></channel></rss>