<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<p>Hi there,</p>
<p><br>
</p>
<p>I've been searching a bit everywhere in the code/issues ... regarding an OGC time filter capability in OWSLib without any success.</p>
<p>The only way I have managed to achieve this so far was do write some dirty xml in my own code. But I'm sure I'm missing something:</p>
<div>
<pre><span>from</span> owslib.fes <span>import</span> PropertyIsGreaterThan

wfs_filter_time <span>=</span> <span><span>"</span>2019-02-18T03:04:00<span>"</span></span>
wfs_property_filter_time <span>=</span> <span><span>'</span>TIME<span>'</span></span>
wfs_date_format<span>=</span><span><span>"</span>yyyy-MM-dd'T'HH:mm:ss<span>"</span></span>
wfs_filter_slevelmax <span>=</span> PropertyIsGreaterThan(<span>propertyname</span><span>=</span>wfs_property_filter_time,
                                             <span>literal</span><span>=</span>wfs_filter_time)

<span><span>#</span> since the function feature doesn't seem to exist, have to create the query manually</span>
filterxml_time <span>=</span> <span><span>'</span><ogc:<span>{property_filter_type}</span> xmlns:ogc="http://www.opengis.net/ogc"><ogc:PropertyName><span>{wfs_property_filter_time}</span></ogc:PropertyName><span>'</span></span> \
                 <span><span>'</span><Function name="dateParse"><Literal><span>{wfs_date_format}</span></Literal><ogc:Literal><span>{wfs_filter_time}</span></ogc:Literal></Function><span>'</span></span> \
                 <span><span>'</span></ogc:<span>{property_filter_type}</span>><span>'</span></span>.format(<span>property_filter_type</span><span>=</span><span><span>'</span>PropertyIsGreaterThan<span>'</span></span>,
                                                        <span>wfs_property_filter_time</span><span>=</span>wfs_property_filter_time,
                                                        <span>wfs_filter_time</span><span>=</span>wfs_filter_time,
                                                        <span>wfs_date_format</span><span>=</span>wfs_date_format)</pre>
</div>
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Is there some proper way to do the equivalent with OWSLib ?</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Regards</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Loz<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div id="signature">
<div name="divtagdefaultwrapper" style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:; margin:0">
<div class="BodyFragment"><font size="2"><span style="font-size:10pt">
<div class="PlainText">~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>
Laurent Besnard, AODN Project Officer<br>
Private Bag 110, University of Tasmania, IMAS Building, Hobart, 7001 Australia<br>
Email: Laurent.Besnard@utas.edu.au, URL: http://portal.aodn.org.au<br>
Tel 0448 710 476</div>
</span></font></div>
</div>
</div>
<p style="font-size:10pt; line-height:10pt; font-family: Calibri,sans-serif;"><br>
<br>
University of Tasmania Electronic Communications Policy (December, 2014). <br>
This email is confidential, and is for the intended recipient only. Access, disclosure, copying, distribution, or reliance on any of it by anyone outside the intended recipient organisation is prohibited and may be a criminal offence. Please delete if obtained
 in error and email confirmation to the sender. The views expressed in this email are not necessarily the views of the University of Tasmania, unless clearly intended otherwise.
</p>
</body>
</html>