Sayfayı Yazdır | Pencereyi Kapat

5.0.12 Update

Nereden Yazdırıldığı: ERP Nedir? | Türkiye'nin ERP Forum Platformu
Kategori: ERP İnsan Kaynakları
Forum Adı: ERP Personel Bordro Modülü
Forum Tanımlaması: Bordro Modülü İle İlgili Bilgiler ve Sorular İçin...
URL: http://www.erpne.org/forum_posts.asp?TID=3301
Tarih: 22 Kasım 2024 Saat 13:24
Program Versiyonu: Web Wiz Forums 11.10 - http://www.webwizforums.com


Konu: 5.0.12 Update
Mesajı Yazan: social
Konu: 5.0.12 Update
Mesaj Tarihi: 30 Kasım 2012 Saat 20:11
Arkadaslar 5.0.10 surumden 12 ye update yapiyorum ama personel ad soyad bos geliyor,yeni yapida tblozluk tablosuna atiyor ama benim tblsicildekileri oraya aktarmiyor.Bunlari aktarmasi için bir kodmu çalistirmak gerekiyor acaba.Netsis dbupdate kendisi yapiyor diyor ama 30.11.2012 ve 29.11.2012 setlerini webftpden çektim nafile ikisindede olmuyor.Manuel olarak tblsicildeki personelin adini ve soyadini tblozluk tablosuna ekliyorum ve verdigi ozlukid sini tblsicildeki ilgili personele ekledigimde isim ve soyisim geliyor ama 1000 personel için tek tek t.c sinden ssk sina kadar bir suru bilgi aktarilmasi gerekiyor.Bu konuda bilgisi olan varmi acaba
tesekkurler



Cevaplar:
Mesajı Yazan: micromak
Mesaj Tarihi: 01 Aralık 2012 Saat 13:31
netsisten sql script cümlesi var onu çalistirman lazim


Mesajı Yazan: social
Mesaj Tarihi: 03 Aralık 2012 Saat 08:12
Orjinalini yazan: micromak micromak Yazdı:

netsisten sql script cümlesi var onu çalistirman lazim
 
Iste bende script mevcut degil bende cumleyi ariyorum,sizde varmi acaba
 


Mesajı Yazan: rabia_bayrakdar
Mesaj Tarihi: 03 Aralık 2012 Saat 09:32


Mesajı Yazan: rabia_bayrakdar
Mesaj Tarihi: 03 Aralık 2012 Saat 09:34
merhaba sciript bende mevcut mail adresinize gönderebilirim. ayni sorun bende de var  netsis ile görüstüm herseyi yaptim yine de isimler gelmiyor. bugün tekrar görüsecegim. düzelme olursa bilgilendiririm.


Mesajı Yazan: social
Mesaj Tarihi: 03 Aralık 2012 Saat 09:38
merhaba mailto:tanjudemir@hotmail.com - tanjudemir@hotmail.com adresine gonderebilirmisiniz.
Netsis artik cumleye ihtiyaç olmadigini,dbupdate kendisi artik aktariyor diyor ama nafile çalismiyor bir turlu.Siz cumleyi çalistirdiginiz haldemi aktarim olmadi acaba


Mesajı Yazan: Conari
Mesaj Tarihi: 05 Aralık 2012 Saat 09:45
buyrun,
 
IF EXISTS (SELECT * FROM tempdb..sysobjects WHERE id=OBJECT_ID('tempdb..#tmpErrors')) DROP TABLE #tmpErrors
GO 
CREATE TABLE #tmpErrors (Error int)
GO 
SET XACT_ABORT ON
GO 
SET TRANSACTION ISOLATION LEVEL SERIALIZABLE
GO
BEGIN TRANSACTION
GO
IF NOT EXISTS
(SELECT S1.NAME, S2.NAME FROM SYSCOLUMNS S1, SYSOBJECTS S2
WHERE S1.ID = S2.ID AND S2.type ='U' AND S1.name = 'GRUP' AND S2.name = 'TBLSICIL')
BEGIN RAISERROR('KAYITLAR YAPILMIS',16,1) INSERT INTO #tmpErrors (Error) SELECT 1 END
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
INSERT INTO TBLOZLUK
(ISLETME_KODU, OZLUKKODU, HITAP, ADI, SOYADI, ILKSOYADI,
BUNYE_GIRTAR, SSK_NO, SSK_DURUM, EMEK_NO,
GRUP, KOD1, KOD2, KOD3, KOD4, KOD5, KOD6, KOD7, KOD8,
ORGULKEID, ANABOLGE_KOD, ALTBOLGE_KOD, ORGIL_KOD, BOLUM_KOD, DEPARTMAN_KOD,
GOREV_TANIMI, POZISYON_KOD,
CINSIYET, MEDENIHAL, COCUK_ADEDI, ESADI,
ASKERLIKTIP, TECIL_TERHIS_TAR, MUAFNEDEN,
SAKATLIK_DRC, SAKATKATEGORI, SAKATORAN, SAKATACIKLAMA, SAKATEXPIRE,
ESKIHUKUMLU, HUKUMACIKLAMA, TERORLEMUCADELE, GOCMEN,
BITIRDIGITAHSILI, DEVAMETTIGITAHSILI,              
KUL_NUMERIC_1, KUL_NUMERIC_2, KUL_NUMERIC_3, KUL_NUMERIC_4,
KUL_STRING_1, KUL_STRING_2, KUL_STRING_3, KUL_STRING_4,
ISYERI, SICILNO
)
(SELECT SIR.ISLETME_KODU, SC.ISYERI+SPACE(8-LEN(SC.ISYERI))+SC.SICILNO,
SC.UNVAN, SC.ADI, SC.SOYADI, SC.ILKSOYADI,
SC.BUNYE_GIRTAR, SC.SSK_NO, SC.SSK_DURUM, SC.EMEK_NO,
SC.GRUP, SC.KOD1, SC.KOD2, SC.KOD3, SC.KOD4, SC.KOD5,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, SC.GOREVI,
NULL,SC.CINSIYET, SC.MEDENIHAL, SC.COCUK_ADEDI, SC.ESADI,
'M', NULL, NULL,SC.SAKATLIK_DRC, NULL, NULL, NULL, NULL,
EK.B_YEDEK1, NULL, EK.I_YEDEK1, SC.GOCMEN,
SC.TAHSILI, '-',         
SC.KUL_NUMERIC_1, SC.KUL_NUMERIC_2, SC.KUL_NUMERIC_3, SC.KUL_NUMERIC_4,
SC.KUL_STRING_1, SC.KUL_STRING_2, SC.KUL_STRING_3, SC.KUL_STRING_4,
SC.ISYERI, SC.SICILNO
FROM TBLSICIL SC
LEFT OUTER JOIN TBLSICILEK EK ON EK.SICILNO = SC.SICILNO AND EK.ISYERI=SC.ISYERI
INNER JOIN TBLSIRKET SIR ON SC.ISYERI = SIR.ISYERI)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
UPDATE TBLSICIL SET OZLUKID = TBLOZLUK.OZLUKID
FROM TBLOZLUK, TBLSICIL WHERE TBLSICIL.ISYERI=RTRIM(SUBSTRING(TBLOZLUK.OZLUKKODU, 1, 8))
                             AND TBLSICIL.SICILNO=RTRIM(SUBSTRING(TBLOZLUK.OZLUKKODU, 9, 15))
                             AND TBLSICIL.OZLUKID IS NULL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
INSERT INTO TBLILETISIM
(OZLUKID, ISMAIL, SAHSIMAIL, DAHILI1, DAHILI2, ISCEPTEL, SAHSICEPTEL,
EVTEL, DIGERTEL, EVADRESI, EVIL, EVILCE, EVSEMT, EVPOSTAKODU,
DIGERADRESI, DIGERIL, DIGERILCE, DIGERSEMT, DIGERPOSTAKODU
)
SELECT OZ.OZLUKID, SC.EMAIL, NULL, NULL, NULL, NULL, EK.CEPTEL,
SC.TEL, NULL, SC.ADRES, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL
FROM TBLSICIL SC
INNER JOIN TBLOZLUK OZ ON OZ.OZLUKKODU = SC.ISYERI+SPACE(8-LEN(SC.ISYERI))+SC.SICILNO
LEFT OUTER JOIN TBLSICILEK EK ON SC.ISYERI = EK.ISYERI AND SC.SICILNO = EK.SICILNO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
INSERT INTO TBLKIMLIK
(OZLUKID, MERNISNO, UYRUGU, BABAADI, ANAADI, DOG_TARIH, DOG_YERI, DINI, KANGRUBU,
NUFUS_IL, NUFUS_ILCE, NUFUS_MAH, NUFUS_KOY, CILT_NO, KUTUK_NO, SAYFA_NO, VERILISTAR,
CUZDAN_SERI_NO, CUZDAN_KAYIT_NO, VERILIS_NEDENI, VERGIDAIRE, VERGINO,
PASAPORTNO, PASAPORTYER, PASAPORTIL, UYRUKULKEID, PASAPORTTAR, PASAPORTEXPIRE, VERILDIGI_YER)
(SELECT TBLOZLUK.OZLUKID, MERNISNO, UYRUGU, BABAADI, ANAADI, DOG_TARIH, DOG_YERI,
DINI, KANGRUBU, NUFUS_IL, NUFUS_ILCE, NUFUS_MAH, NUFUS_KOY, CILT_NO, KUTUK_NO, SAYFA_NO, VERILISTAR,
SERI_NO, KAYIT_NO, NULL, VERGIDAIRE, VERGINO,
NULL, NULL, NULL, NULL, NULL, NULL, NUFUS_DAIRESI
FROM TBLSICIL, TBLOZLUK WHERE TBLOZLUK.OZLUKKODU = TBLSICIL.ISYERI+SPACE(8-LEN(TBLSICIL.ISYERI))+TBLSICIL.SICILNO)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
INSERT INTO TBLBANKAHES
(OZLUKID, BANKA_1, SUBE_1, HESAP_1, BANKA_2, SUBE_2, HESAP_2, BANKA_3, SUBE_3, HESAP_3,
BANKA_4, SUBE_4, HESAP_4, BANKA_5, SUBE_5, HESAP_5,
IBAN_1, IBAN_2, IBAN_3, IBAN_4, IBAN_5)
(SELECT TBLOZLUK.OZLUKID, BANKA_1, SUBE_1, HESAP_1, BANKA_2, SUBE_2, HESAP_2,
BANKA_3, SUBE_3, HESAP_3, BANKA_4, SUBE_4, HESAP_4, BANKA_5, SUBE_5, HESAP_5,
IBAN_1, IBAN_2, IBAN_3, IBAN_4, NULL
FROM TBLSICIL, TBLOZLUK WHERE TBLOZLUK.OZLUKKODU = TBLSICIL.ISYERI+SPACE(8-LEN(TBLSICIL.ISYERI))+TBLSICIL.SICILNO)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
UPDATE TBLES_COCUK SET OZLUKID = SC.OZLUKID FROM TBLSICIL SC
WHERE SC.ISYERI=TBLES_COCUK.ISYERI AND SC.SICILNO=TBLES_COCUK.SICILNO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
UPDATE TBLES_COCUK SET EVLATDURUMU = 'V' WHERE TUR = 1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
UPDATE TBLES_COCUK SET EVLATDURUMU = 'O' WHERE TUR IN (4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
AND EVLATDURUMU IS NULL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN GRUP
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''GOCMEN'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN GOCMEN
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''TAHSILI'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN TAHSILI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''KUL_NUMERIC_1'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_NUMERIC_1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''KUL_NUMERIC_2'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_NUMERIC_2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''KUL_NUMERIC_3'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_NUMERIC_3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''KUL_NUMERIC_4'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_NUMERIC_4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_STRING_1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_STRING_2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_STRING_3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUL_STRING_4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN EMAIL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN TEL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN ADRES
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN MERNISNO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN UYRUGU
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BABAADI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN ANAADI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN DOG_TARIH
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN DOG_YERI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN DINI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KANGRUBU
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN NUFUS_IL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN NUFUS_ILCE
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN NUFUS_MAH
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN NUFUS_KOY
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN CILT_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KUTUK_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SAYFA_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN VERILISTAR
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SERI_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KAYIT_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN VERGIDAIRE
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN VERGINO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN NUFUS_DAIRESI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BANKA_1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SUBE_1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN HESAP_1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BANKA_2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SUBE_2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN HESAP_2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BANKA_3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SUBE_3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN HESAP_3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BANKA_4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SUBE_4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN HESAP_4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BANKA_5
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SUBE_5
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN HESAP_5
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN IBAN_1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN IBAN_2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN IBAN_3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN IBAN_4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KOD1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KOD2
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KOD3
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KOD4
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN KOD5
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN UNVAN
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN ADI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SOYADI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN ILKSOYADI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN BUNYE_GIRTAR
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SSK_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''SSK_DURUM'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SSK_DURUM
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN EMEK_NO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN GOREVI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''CINSIYET'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN CINSIYET
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''MEDENIHAL'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN MEDENIHAL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''COCUK_ADEDI'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN COCUK_ADEDI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN ESADI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DECLARE @cmd VARCHAR(1000)
SET @cmd = 'DBO.DROPCONSTRAINT '+'''SAKATLIK_DRC'''+', '+'''TBLSICIL'''
EXEC(@cmd)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICIL DROP COLUMN SAKATLIK_DRC
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICILEK DROP COLUMN B_YEDEK1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICILEK DROP COLUMN I_YEDEK1
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLSICILEK DROP COLUMN CEPTEL
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLES_COCUK DROP ESCOCUK_FKEY
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
DROP INDEX TBLES_COCUK_IND_1 ON TBLES_COCUK
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLES_COCUK DROP COLUMN ISYERI
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLES_COCUK DROP COLUMN SICILNO
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLES_COCUK ALTER COLUMN ADI VARCHAR(50)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
ALTER TABLE TBLES_COCUK ALTER COLUMN SADI VARCHAR(50)
GO
IF @@ERROR<>0 AND @@TRANCOUNT>0 ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT=0 BEGIN INSERT INTO #tmpErrors (Error) SELECT 1 BEGIN TRANSACTION END
GO
IF EXISTS (SELECT * FROM #tmpErrors) ROLLBACK TRANSACTION
GO
IF @@TRANCOUNT>0 BEGIN
COMMIT TRANSACTION
END
GO
DROP TABLE #tmpErrors


-------------
Netsisden vazgeçemiyorum. Beni engelliyor..



Sayfayı Yazdır | Pencereyi Kapat

Forum Software by Web Wiz Forums® version 11.10 - http://www.webwizforums.com
Copyright ©2001-2017 Web Wiz Ltd. - https://www.webwiz.net