# DvDuration: Mixed Pattern and Interval not supported by ADL Parser **Category:** [Reference Implementation: Java (archive)](https://discourse.openehr.org/c/reference-implementation-java-archive/154) **Created:** 2010-07-12 11:38 UTC **Views:** 4 **Replies:** 1 **URL:** https://discourse.openehr.org/t/dvduration-mixed-pattern-and-interval-not-supported-by-adl-parser/13487 --- ## Post #1 by @system Hi Rong and all, The ADLParser does not appear to support a mixed pattern and Interval for a DV_DURATION. >From the ADL Specs > `Mixed Pattern and Interval` > `In some cases there is a need to be able to limit the allowed units as well as state a duration interval.` > `This is common in obstetrics, where physicians want to be able to set an interval from say 0-50 weeks` > `and limit the units to only weeks and days. This can be done as follows:` > `PWD/|P0W..P50W| -- 0-50 weeks, expressed only using weeks and days` > `The general form is a pattern followed by a slash ('/') followed by an interval, as follows:` > `duration_pattern '/' duration_interval` I have implemented the following change in the Parser (in red). [details="(attachments)"] ![oceanlogo.png|84x82](upload://2EtFgZ1bS4JNl1d51FusTB7hg8M.png) [/details] --- ## Post #2 by @system Hi Sebastian, I can confirm the changes. I just re-arranged the code to make it clearer. Cheers, Rong [details="(attachments)"] ![oceanlogo.png|84x82](upload://2EtFgZ1bS4JNl1d51FusTB7hg8M.png) [/details] --- **Canonical:** https://discourse.openehr.org/t/dvduration-mixed-pattern-and-interval-not-supported-by-adl-parser/13487 **Original content:** https://discourse.openehr.org/t/dvduration-mixed-pattern-and-interval-not-supported-by-adl-parser/13487