On Sun, Sep 25, 2005 at 03:56:46PM -0500, Peter Brawley wrote:
> Jim,
>
> If you really want to return the result in a variable, declare a user
> var in the client, declare an OUT var in the SP, have the SP SELECT INTO
> it, and pass the user var to the SP in the call:
>
> SET @x=0;
> SET GLOBA
Jim,
>I have tried numerous variations of the following:
>CREATE PROCEDURE CountPhoneNumbers () BEGIN DECLARE @count INT SELECT
>@count = COUNT(*) FROM CUSTOMER WHERE HomePhone IS NOT NULL; END//
>// was set to be the delimiter for the creation and have tried putting
>various parts of the query
Taking on online class for SQL and am down to the last two classes and
cannot make the following work. This is a MS SQL Server query that I
have not been able to solve through the MySQL Documentation:
CREATE PROCEDURE CountPhoneNumbers AS DECLARE @count INTEGER
SELECT @count = COUNT (*) FROM Custo