مهندسی نرم افزار uml سیستم توریسم بخش سی و پنجم
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[FK_Forush_Belit_Ghtar_Operator]') and OBJECTPROPERTY(id, N'IsForeignKey') = 1)
ALTER TABLE [dbo].[Forush_Belit_Ghtar] DROP CONSTRAINT FK_Forush_Belit_Ghtar_Operator
GO
/****** Object: Table [dbo].[Forush_Belit_Ghtar] Script Date: 2009/01/26 04:01:58 ب.ظ ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Forush_Belit_Ghtar]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[Forush_Belit_Ghtar]
GO
/****** Object: Table [dbo].[Costumers2] Script Date: 2009/01/26 04:01:58 ب.ظ ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Costumers2]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[Costumers2]
GO
/****** Object: Table [dbo].[Look_Harkat_Num] Script Date: 2009/01/26 04:01:58 ب.ظ ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Look_Harkat_Num]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[Look_Harkat_Num]
GO
/****** Object: Table [dbo].[Operator] Script Date: 2009/01/26 04:01:58 ب.ظ ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Operator]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[Operator]
GO
/****** Object: User dbo Script Date: 2009/01/26 04:01:56 ب.ظ ******/
/****** Object: User guest Script Date: 2009/01/26 04:01:56 ب.ظ ******/
if not exists (select * from dbo.sysusers where name = N'guest' and hasdbaccess = 1)
EXEC sp_grantdbaccess N'guest'
GO
/****** Object: Table [dbo].[Costumers2] Script Date: 2009/01/26 04:01:58 ب.ظ ******/
CREATE TABLE [dbo].[Costumers2] (
[CostumID] [int] IDENTITY (1, 1) NOT NULL ,
[CostmNameSname] [nvarchar] (50) NULL ,
[MelliCode] [nvarchar] (10) NULL ,
[Phone] [nvarchar] (50) NULL ,
[Fax] [nvarchar] (50) NULL ,
[Mobile] [nvarchar] (50) NULL ,
[Notes] [nvarchar] (250) NULL
) ON [PRIMARY]
GO
/****** Object: Table [dbo].[Look_Harkat_Num] Script Date: 2009/01/26 04:01:59 ب.ظ ******/
CREATE TABLE [dbo].[Look_Harkat_Num] (
[HarkatID] [int] IDENTITY (1, 1) NOT NULL ,
[HarkatMagsad] [nvarchar] (50) NULL ,
[Date] [float] NULL ,
[Time] [smalldatetime] NULL ,
[SandaliTedad] [int] NULL ,
[Notes] [nvarchar] (250) NULL
) ON [PRIMARY]
GO
/****** Object: Table [dbo].[Operator] Script Date: 2009/01/26 04:01:59 ب.ظ ******/
CREATE TABLE [dbo].[Operator] (
[OperatorID] [int] IDENTITY (1, 1) NOT NULL ,
[OperatorNameSname] [nvarchar] (50) NULL ,
[MelliCode] [nvarchar] (50) NULL ,
[Address] [nvarchar] (199) NULL ,
[Phone] [nvarchar] (50) NULL ,
[Fax] [nvarchar] (50) NULL ,
[Mobile] [nvarchar] (50) NULL ,
[Notes] [nvarchar] (250) NULL
) ON [PRIMARY]
GO
/****** Object: Table [dbo].[Forush_Belit_Ghtar] Script Date: 2009/01/26 04:01:59 ب.ظ ******/
CREATE TABLE [dbo].[Forush_Belit_Ghtar] (
[TicketID] [int] IDENTITY (1, 1) NOT NULL ,
[ForooshanDeh] [int] NULL ,
[CustomerID] [int] NOT NULL ,
[GatarHarkatNumber] [int] NOT NULL ,
[TedadeNafarat] [int] NULL ,
[MablaghKolleBelit] [money] NULL ,
[ServiceNoow] [nvarchar] (50) NULL ,
[Notes] [nvarchar] (250) NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[Costumers2] WITH NOCHECK ADD
CONSTRAINT [PK_Costumers2] PRIMARY KEY CLUSTERED
(
[CostumID]
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[Look_Harkat_Num] WITH NOCHECK ADD
CONSTRAINT [PK_Look_Harkat_Num] PRIMARY KEY CLUSTERED
(
[HarkatID]
) ON [PRIMARY]
GO