Hello.
You might be interesting a bit about this:
http://dev.mysql.com/tech-resources/articles/migrating-from-microsoft.html
Ed wrote:
> Hi all,
> I am doing a tutorial to make a shopping cart. I need to make a mysql db or
> convert an sql db to mysql.
> Can anyone give me any pointers as to how to make the following tables?
> The Microsoft SQL Server 2000 creation script is below the tables. Thanks a
> lot for any pointers to get me started off- I will use php admin to make the
> table
>
> Categories:
> int_CategoryID int IDENTITY
> txt_Category nvarchar(100)
> bit_Active bit
>
> Clients:
> int_ClientID int IDENTITY
> txt_ClientName nvarchar(100)
> txt_ClientEmail ntext(16)
> txt_Username nvarchar(30)
> txt_Password nvarchar(30)
> bit_Active bit
> int_CFID int
> txt_CFTOKEN nvarchar(100)
>
> Products:
> int_ProductID int IDENTITY
> txt_ProductTitle nvarchar(100)
> txt_ProductDescription ntext(16)
> flt_ProductPrice float
> bit_Active bit
> int_CategoryID int
>
> PurchasedProducts:
> int_saleCart int IDENTITY
> int_ClientID int
> int_ProductID int
> int_Quantity int
>
> WebCart:
> int_CartID int IDENTITY
> int_ProductID int
> int_Quantity int
> int_ClientID int
>
> Microsoft SQL Server 2000 creation scripts:
>
> <!----- SQL Create Script Begins ------>
> if exists (select * from sysobjects where id =
> object_id(N'[dbo].[Categories]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
> drop table [dbo].[Categories]
> GO
>
> if exists (select * from sysobjects where id = object_id(N'[dbo].[Clients]')
> and OBJECTPROPERTY(id, N'IsUserTable') = 1)
> drop table [dbo].[Clients]
> GO
>
> if exists (select * from sysobjects where id =
> object_id(N'[dbo].[Products]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
> drop table [dbo].[Products]
> GO
>
> if exists (select * from sysobjects where id =
> object_id(N'[dbo].[PurchasedProducts]') and OBJECTPROPERTY(id,
> N'IsUserTable') = 1)
> drop table [dbo].[PurchasedProducts]
> GO
>
> if exists (select * from sysobjects where id = object_id(N'[dbo].[WebCart]')
> and OBJECTPROPERTY(id, N'IsUserTable') = 1)
> drop table [dbo].[WebCart]
> GO
>
> CREATE TABLE [dbo].[Categories] (
> [int_CategoryID] [int] IDENTITY (1, 1) NOT NULL ,
> [txt_Category] [nvarchar] (100) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
> [bit_Active] [bit] NULL
> ) ON [PRIMARY]
> GO
>
> CREATE TABLE [dbo].[Clients] (
> [int_ClientID] [int] IDENTITY (1, 1) NOT NULL ,
> [txt_ClientName] [nvarchar] (100) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
> ,
> [txt_ClientEmail] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
> [txt_Username] [nvarchar] (30) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
> [txt_Password] [nvarchar] (30) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
> [bit_Active] [bit] NULL ,
> [int_CFID] [int] NULL ,
> [txt_CFTOKEN] [nvarchar] (100) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
> ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
> GO
>
> CREATE TABLE [dbo].[Products] (
> [int_ProductID] [int] IDENTITY (1, 1) NOT NULL ,
> [txt_ProductTitle] [nvarchar] (100) COLLATE SQL_Latin1_General_CP1_CI_AS
> NULL ,
> [txt_ProductDescription] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
> [flt_ProductPrice] [float] NULL ,
> [bit_Active] [bit] NULL ,
> [int_CategoryID] [int] NULL
> ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
> GO
>
> CREATE TABLE [dbo].[PurchasedProducts] (
> [int_saleCart] [int] IDENTITY (1, 1) NOT NULL ,
> [int_ClientID] [int] NULL ,
> [int_ProductID] [int] NULL ,
> [int_Quantity] [int] NULL
> ) ON [PRIMARY]
> GO
>
> CREATE TABLE [dbo].[WebCart] (
> [int_CartID] [int] IDENTITY (1, 1) NOT NULL ,
> [int_ProductID] [int] NULL ,
> [int_Quantity] [int] NULL ,
> [int_ClientID] [int] NULL
> ) ON [PRIMARY]
> GO
> <!------- SQL Create Script Ends -------->
>
>
>
--
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.NET http://www.ensita.net/
__ ___ ___ ____ __
/ |/ /_ __/ __/ __ \/ / Gleb Paharenko
/ /|_/ / // /\ \/ /_/ / /__ Gleb.Paharenko@stripped
/_/ /_/\_, /___/\___\_\___/ MySQL AB / Ensita.NET
<___/ www.mysql.com