﻿UPDATE T_ORARENDIORA_OSSZES SET C_KAPORA = 'F' WHERE TOROLT = 'F' AND  C_KAPORA = 'T'
UPDATE T_ORARENDIORA_OSSZES SET C_KAPORA = 'T' WHERE TOROLT = 'F'
  AND (C_ISDFHTORA = 'T' 
    OR C_ISRAHANGOLODAS = 'T'
    OR C_ISTESTMOZGASALAPUALPROGRAM = 'T'
    OR C_ISMUVESZETALAPUALPROGRAM = 'T'
    OR C_KIPORA = 'T'
    OR C_KOMPLEXORA = 'T'
    OR C_ISELETGYAKORLATALAPUALPROGRA = 'T'
    OR C_ISLOGIKAALAPUALPROGRAM = 'T'
    OR C_ISTEORAD = 'T'
    OR C_ISDIGITALISALAPUALPROGRAM = 'T')

UPDATE T_TANITASIORA_OSSZES SET C_KAPORA = 'F' WHERE TOROLT = 'F' AND  C_KAPORA = 'T'
UPDATE T_TANITASIORA_OSSZES SET C_KAPORA = 'T' WHERE TOROLT = 'F'
  AND (C_ISDFHTORA = 'T' 
    OR C_ISRAHANGOLODAS = 'T'
    OR C_ISTESTMOZGASALAPUALPROGRAM = 'T'
    OR C_ISMUVESZETALAPUALPROGRAM = 'T'
    OR C_KIPORA = 'T'
    OR C_KOMPLEXORA = 'T'
    OR C_ISELETGYAKORLATALAPUALPROGRA = 'T'
    OR C_ISLOGIKAALAPUALPROGRAM = 'T'
    OR C_ISTEORAD = 'T'
    OR C_ISDIGITALISALAPUALPROGRAM = 'T')