init
This commit is contained in:
commit
e124a47765
19374 changed files with 9806149 additions and 0 deletions
|
@ -0,0 +1,24 @@
|
|||
IF OBJECT_ID('fnGetDokumentumOsztalyVagyTanoraiCsoport') IS NOT NULL BEGIN
|
||||
DROP FUNCTION fnGetDokumentumOsztalyVagyTanoraiCsoport
|
||||
END
|
||||
GO
|
||||
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
|
||||
CREATE FUNCTION fnGetDokumentumOsztalyVagyTanoraiCsoport (@tanevId int)
|
||||
RETURNS TABLE
|
||||
RETURN (
|
||||
SELECT
|
||||
T_OSZTALYCSOPORT_OSSZES.ID
|
||||
FROM T_OSZTALYCSOPORT_OSSZES
|
||||
WHERE
|
||||
( EXISTS (SELECT TOP 1 ID FROM T_OSZTALY_OSSZES WHERE T_OSZTALY_OSSZES.ID = T_OSZTALYCSOPORT_OSSZES.ID )
|
||||
OR
|
||||
EXISTS (SELECT TOP 1 ID FROM T_CSOPORT_OSSZES WHERE C_TIPUSA IN (SELECT ID FROM fnGetTanoraiCeluCsoportTipusok(@tanevId)) AND T_CSOPORT_OSSZES.ID = T_OSZTALYCSOPORT_OSSZES.ID)
|
||||
)
|
||||
AND T_OSZTALYCSOPORT_OSSZES.C_TANEVID = @tanevId
|
||||
AND TOROLT = 'F'
|
||||
)
|
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue