1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
| with Logiciels as
(
select '1.13.225' as version from dual
union all select '1.13.226' as version from dual
union all select '0.13.225' as version from dual
union all select '1.12.225' as version from dual
)
SELECT --* from
DISTINCT max(Version) over (ORDER BY X desc,Y desc,Z desc) FROM
(
SELECT to_number(substr(Version ,1,instr(Version ,'.')-1)) AS X,
to_number(substr(substr(substr(Version,instr(Version,'.')),2),1,instr(substr(substr(Version,instr(Version,'.')),2),'.')-1)) AS Y,
to_number(substr(substr(substr(substr(Version,instr(Version,'.')),2),instr(substr(substr(Version,instr(Version,'.')),2),'.')),2)) AS Z,
Version
FROM Logiciels
) |
Partager