IF NOT EXISTS (SELECT * FROM SYSCOLUMNS INNER JOIN SYSOBJECTS ON SYSOBJECTS.id = SYSCOLUMNS.id 
              WHERE SYSOBJECTS.name = 'HOSGBDOKUMAN')

CREATE TABLE [dbo].[HOSGBDOKUMAN](
	[ID] [int] NOT NULL,
	[HDOSYAID] [int] NULL,
	[HESAPISLID] [int] NULL,
	[HTETKIKID] [int] NULL,
	[ADRES] [nvarchar](150) NULL,
	[DOSYA] [nvarchar](150) NULL,
	[ACIKLAMA] [nvarchar](150) NULL,
	[KYTARIH] [datetime] NULL,
	[KYKULLANICI] [nvarchar](50) NULL,
	[SGTARIH] [datetime] NULL,
	[SGKULLANICI] [nvarchar](50) NULL,
	[DOKUMANBASE64] [ntext] NULL,
 CONSTRAINT [PK_HOSGBDOKUMAN] PRIMARY KEY CLUSTERED 
(
	[ID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO






