EXECUTE "SET-THOUS ."
EXECUTE "SET-DEC ,"
EXECUTE "DATE.FORMAT"
OPEN "", "DETAILPREST" TO F.DETAILPREST ELSE STOP
OPEN "", "MT" TO F.MT ELSE STOP
EXECUTE 'SELECT DETAILPREST AVEC 5 = "089"'
W_Fin = "F"
LOOP
READNEXT CLE ELSE W_Fin = "V"
WHILE W_Fin = "F"
READ ENR_DETAILPREST FROM F.DETAILPREST, CLE THEN
READ ENR FROM F.MT, CLE THEN
	i = 0
	LOOP
	i = i + 1
	WHILE ENR_DETAILPREST<5,i> # "" AND ENR_DETAILPREST<5,i> # "089"
	REPEAT
	IF ENR_DETAILPREST<5,i> = "089" THEN
		k = 0
		LOOP
		k = k +1
		WHILE ENR<5,k> # "" AND ENR<5,k># "089"
		REPEAT
		IF ENR<5,k> = "089" THEN
			IF ENR<6,k> # ENR_DETAILPREST<6,i> THEN
				PRINT "DIFFERENCE : ":CLE
			END
			DELETE F.MT, CLE
		END ELSE
			PRINT "Anomalie2 : ":CLE
		END
	END ELSE
		PRINT "Anomalie 1 : ":CLE
	END
END ELSE
	PRINT CLE : " PAS DE CALCUL REEL"
END
END
REPEAT
STOP
