Help converting SQL Server Stored Procedure
Hello,
I am trying to convert MS SQL Server stored procedure to MySQL.
Most of the stored procedure done, but i am stuck with this:
DECLARE dtStartDate atetime; #"datetime" not working? (mysql v.5.1.37)
DECLARE dtEndDate datetime;
DECLARE dtStartDateString varchar(32);
DECLARE dtEndDateString varchar(32);
SET dtStartDate = now();
SET dtEndDate = DATEADD(dd, iCastleSiegeTerm, now());
SET dtStartDateString = CAST(DATEPART(YY, dtStartDate) AS char(4)) + '-' + CAST(DATEPART(MM, dtStartDate) AS char(2)) + '-' + CAST(DATEPART(DD, dtStartDate) AS char(2)) + ' 00:00:00'
SET dtEndDateString = CAST(DATEPART(YY, dtEndDate) AS char(4)) + '-' + CAST(DATEPART(MM, dtEndDate) AS char(2)) + '-' + CAST(DATEPART(DD, dtEndDate) AS char(2)) + ' 00:00:00'
Subject
Written By
Posted
Help converting SQL Server Stored Procedure
October 25, 2009 06:37AM
December 15, 2009 06:33AM
December 18, 2009 05:41PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.