<div>
Wouldn't a combination of to_days(date) en from_days(ulong) help ?
</div><div>Using from_days(some number equal to the date you need) is always correct no matter what date time format is used.</div><div>This is what we did when trying to escape hardcoding dates.</div><div><br></div><div>hth</div>
<div><div><br></div><div>-- </div><div>Bart Pietercil</div><div>CTO Cognosis NV</div><div>Dorpstraat 28</div><div>3560 Lummen<br></div><div><br></div></div>
<p style="color: #A0A0A8;">On Thursday 28 June 2012 at 14:47, jda wrote:</p>
<blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;">
<span><div><div><div><br></div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal 'Times New Roman'; "> dateAdded > datediff( now(), '01/01/1904 00:00:00', 'second' ) - (14 * 24 * 60 * 60)<span style="font: normal normal normal 12px/normal Helvetica; "> </span></div></div></blockquote></div></div></blockquote></div></div></blockquote><div><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; font: normal normal normal 12px/normal 'Times New Roman'; "><span style="font: normal normal normal 12px/normal Helvetica; "><br></span></div></div></blockquote></div></div></blockquote><br></div><div><br></div></div></div><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Hi Ivan,</div><div><br></div><div>But that's not the problem. It works just fine form my purposes (local time). The problem is the format for the date parameter:</div><div><br></div><div> 01/01/1904</div><div><br></div><div>works if the system language (international setting) is set to English.</div><div><br></div><div>It fails if the language is set to German. I thought</div><div><br></div><div><div> 01-01-1904</div><div><br></div><div>would work, but the search -> no results (there should be many when the language is German (or English).</div><div><br></div><div>This is all on the same Mac in one time zone, there there should be no issues with now().</div><div><br></div></div></div></blockquote></div><div><br></div>Hi Jon,<div><br></div><div>Actually, it is not related to the language - it is only related to the date-time format property.</div><div>And so, if user can set any format himself you can not hardcoded date literals in your queries.</div><div><div><font color="#000000"><br></font></div></div></div></blockquote><br></div><div>Thanks. It would help if I knew what the possibilities are, though. I can document this for my users. For example, what would you use for such a query in Ukraine? What about a romance language or other European languages? There can't be too many variations.</div><div><br></div><div>Ruslan had suggested</div><div><br></div><div>01-01-1904</div><div><br></div><div>but that doesn't work. Or do I also have to put the parameter 'second' in the language selected by the user?</div><div><br></div><div>Jon</div><div><br></div><div><br></div><br></div><div><div>_______________________________________________</div><div>Valentina mailing list</div><div><a href="mailto:Valentina@lists.macserve.net">Valentina@lists.macserve.net</a></div><div><a href="http://lists.macserve.net/mailman/listinfo/valentina">http://lists.macserve.net/mailman/listinfo/valentina</a></div></div></div></span>
</blockquote>
<div>
<br>
</div>