IF NOT EXISTS(SELECT TOP 1 * FROM STOK WHERE STOKID < 0 AND SATISKDV = 10)
BEGIN
	INSERT STOK (STOKID,KODU,ADI,SSATICI,SALISBFIYAT,SFATTARIHI,ALISKDV,SATISKDV,BIRIM,TURU,KDV,FATURABIRIMI,SERIBARKODKULLANILIR)
	VALUES ((select MIN(STOKID)-10 from STOK WHERE STOKID<0), 'HASTANE', 'HASTANE HÝZMETLERÝ (KDV=%10)', 0,0,'2023-07-10 00:00:00', 10,10,'Adet','HIZMET',10,'Adet',0)
END
GO
IF NOT EXISTS(SELECT TOP 1 * FROM STOK WHERE STOKID < 0 AND SATISKDV = 20)
BEGIN
	INSERT STOK (STOKID,KODU,ADI,SSATICI,SALISBFIYAT,SFATTARIHI,ALISKDV,SATISKDV,BIRIM,TURU,KDV,FATURABIRIMI,SERIBARKODKULLANILIR)
	VALUES ((select MIN(STOKID)-10 from STOK WHERE STOKID<0), 'HASTANE', 'HASTANE HÝZMETLERÝ (KDV=%20)', 0,0,'2023-07-10 00:00:00', 20,20,'Adet','HIZMET',20,'Adet',0)
END