| Author |
changing from MSSQL to MySQL
|
john mattucci
Ranch Hand
Joined: Nov 03, 2000
Posts: 331
|
|
Im switching from MSSQL to MySQL. This is my first time using MySQL. I have to create tables.. stored procedures. However everything I try to copy from MSSQl come up with errors. Can someone point out what is wrong with this stored procedure? What are some of the differences between the two databases that I should keep in mind CREATE PROCEDURE dbo.ObtainPhotoInfo @photoID varchar(255) AS SELECT [ID] , itemDescription, unitprice FROM itemlist WHERE [ID] LIKE @photoID GO
|
 |
David Ulicny
Ranch Hand
Joined: Aug 04, 2004
Posts: 724
|
|
|
What I see is the dbo user, he is MSSQL specific and will not work on MySQL.
|
SCJP<br />SCWCD <br />ICSD(286)<br />MCP 70-216
|
 |
john mattucci
Ranch Hand
Joined: Nov 03, 2000
Posts: 331
|
|
I tried removing that but i still received errors. I attempted the following CREATE PROCEDURE ObtainPhotoInfo (@photoID varchar(255)) AS SELECT [ID] , itemDescription, unitprice FROM itemlist WHERE [ID] LIKE @photoID GO
|
 |
David Ulicny
Ranch Hand
Joined: Aug 04, 2004
Posts: 724
|
|
|
Try to remove GO
|
 |
David Ulicny
Ranch Hand
Joined: Aug 04, 2004
Posts: 724
|
|
|
Could you post the error message?
|
 |
Paul Sturrock
Bartender
Joined: Apr 14, 2004
Posts: 10336
|
|
|
Procedures are defined differently in MySQL - for example you'll have to define an IN and OUT parameter for this procedure. Check the docs - theres a definition of the syntax plus an example in there.
|
JavaRanch FAQ HowToAskQuestionsOnJavaRanch
|
 |
 |
|
|
subject: changing from MSSQL to MySQL
|
|
|