Project

General

Profile

Actions

Anomalie #2603

open

AdminAgim – Refonte PHP - Evolution #2599: Reprise des données

Analyse négo - inutilisés

Added by Emanuel Stancu 24 days ago. Updated 24 days ago.

Status:
Nouveau
Priority:
Normal
Category:
-
Start date:
10/06/2026
Due date:
% Done:

0%

Estimated time:

Description

SELECT count(*)  from negociateurs n 
WHERE n.nego_typenego = 1 -- 13695 en tout, pas dans mandats_nego ni util actifs
and n.nego_actif=0 -- 13576 inactifs
AND n.nego_id not in (select mn.com_idnego from mandats_nego mn where mn.com_idnego IS NOT NULL)
 AND n.nego_id not in (select u.util_idnego from utilisateurs u where u.util_idnego IS NOT NULL AND u.util_actif=1)
 AND n.nego_id not in (SELECT m.mdt_conseilleruvr FROM mandats m WHERE mdt_conseilleruvr IS NOT NULL) -- 13431 inactifs, pas dans mandats
 AND n.nego_id not in (SELECT m.Lot_IdNego FROM Lots m WHERE Lot_IdNego IS NOT NULL) -- 13426 inactifs, pas dans mandats, ni lots
 AND n.nego_id not in (SELECT m.ges_conseilleruvr FROM mandats_gestion m WHERE ges_conseilleruvr IS NOT NULL) -- 13270 inactifs, ni mandats gestion
 AND n.nego_id not in (SELECT m.LGe_IdNego FROM LotGestions m WHERE LGe_IdNego IS NOT NULL) -- 13269 ni LotGestions
 AND n.nego_id not in (SELECT m.Syn_IdNego FROM Syndic m WHERE Syn_IdNego IS NOT NULL) -- 13197 ni Syndic
 AND n.nego_id not in (SELECT m.Vir_IdNego FROM Virements m WHERE Vir_IdNego IS NOT NULL) -- 13179 Virements
 AND n.nego_id NOT IN (SELECT o.Ofr_IdNegociateurSortie FROM offres o WHERE Ofr_IdNegociateurSortie IS NOT NULL) -- 13070 ni dans offres

;

Files

Analyse négo - inutilisés.sql (2.33 KB) Analyse négo - inutilisés.sql Emanuel Stancu, 10/06/2026 11:57 AM
Actions #1

Updated by Emanuel Stancu 24 days ago

  • Parent task set to #2599
Actions #2

Updated by Emanuel Stancu 24 days ago

  • Description updated (diff)
Actions

Also available in: Atom PDF