Skip to content
Snippets Groups Projects
Commit 385124d6 authored by root's avatar root
Browse files

Merge branch 'develop' of https://labs.maarch.org/maarch/MaarchCourrier into develop

parents 51130f1f c4d77099
No related branches found
No related tags found
No related merge requests found
......@@ -4090,3 +4090,11 @@ CREATE TABLE thesaurus_res
WITH (
OIDS=FALSE
);
CREATE FUNCTION order_alphanum(text) RETURNS text AS $$
SELECT regexp_replace(regexp_replace(regexp_replace(regexp_replace($1,
E'(^|\\D)(\\d{1,3}($|\\D))', E'\\1000\\2', 'g'),
E'(^|\\D)(\\d{4,6}($|\\D))', E'\\1000\\2', 'g'),
E'(^|\\D)(\\d{7}($|\\D))', E'\\100\\2', 'g'),
E'(^|\\D)(\\d{8}($|\\D))', E'\\10\\2', 'g');
$$ LANGUAGE SQL;
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment