Re: Deleteing Based On Dates
This WebDNA talk-list message is from 2002
It keeps the original formatting.
numero = 41166
interpreted = N
texte = If you are on WC4.x, you can set the century break in WebCat preferences - if you set it to, say 50, then all 2-digit dates <= 50 will be assumed to be in the 2000's, while those >50 will be assumed to be in the 1900's.Execute this code:[math]{06/15/2002}[/math]
[math]{06/15/02}[/math]
They will be the same if WC thinks 02 is 2002. If they aren't, then adjust you're WC Preferences, then (hopefully) the delete will work for you.- brianAt 4:42 PM 7/2/02, Arturo Vargas wrote:>I was having a similar problem earlier.>the reason I was having the problem was that the field that contained the>date was formated dd/mm/yy>and the [math] comand produces a date formated dd/mm/yyyy>>also it is easier for me to debug my code if I do this:>>[math date]mydate={[date]}-{00/07/0000}[/math]>[delete db=[log]&leDTdatarq=[mydate]&DTtype=date]>>>that way I am sure that I am producing mydate correctly.>>Also you can try hardcoding [mydate] with the right value, to see if that>works:>>>ART>>-----Original Message----->From: WebCatalog Talk [mailto:WebDNA-Talk@talk.smithmicro.com]On Behalf>Of Glenn Busbin>Sent: Tuesday, July 02, 2002 4:24 PM>To: WebCatalog Talk>Subject: Re: Deleteing Based On Dates>>>>I want to delete all entries that are 7 days old:>>>>[delete db=[log]&leDTdatarq=[math>>date]{[date]}-{00/07/0000}[/math]&DTtype=date]>>>>Deletes everything in the database (There are things in there from the 17th>>of June)>>>>Ideas?>>You aren't using Date as a field name, are you?>>Glenn>>------------------------------------------------------------->This message is sent to you because you are subscribed to> the mailing list
.>To unsubscribe, E-mail to: >To switch to the DIGEST mode, E-mail to>>Web Archive of this list is at: http://search.smithmicro.com/>>>------------------------------------------------------------->This message is sent to you because you are subscribed to> the mailing list .>To unsubscribe, E-mail to: >To switch to the DIGEST mode, E-mail to >>Web Archive of this list is at: http://search.smithmicro.com/-- <= Brian C. Fries, BrainScan Software http://www.brainscansoftware.com =>-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/
Associated Messages, from the most recent to the oldest:
If you are on WC4.x, you can set the century break in WebCat preferences - if you set it to, say 50, then all 2-digit dates <= 50 will be assumed to be in the 2000's, while those >50 will be assumed to be in the 1900's.Execute this code:[math]{06/15/2002}[/math]
[math]{06/15/02}[/math]
They will be the same if WC thinks 02 is 2002. If they aren't, then adjust you're WC Preferences, then (hopefully) the delete will work for you.- brianAt 4:42 PM 7/2/02, Arturo Vargas wrote:>I was having a similar problem earlier.>the reason I was having the problem was that the field that contained the>date was formated dd/mm/yy>and the [math] comand produces a date formated dd/mm/yyyy>>also it is easier for me to debug my code if I do this:>>[math date]mydate={[date]}-{00/07/0000}[/math]>[delete db=[log]&leDTdatarq=[mydate]&DTtype=date]>>>that way I am sure that I am producing mydate correctly.>>Also you can try hardcoding [mydate] with the right value, to see if that>works:>>>ART>>-----Original Message----->From: WebCatalog Talk [mailto:WebDNA-Talk@talk.smithmicro.com]On Behalf>Of Glenn Busbin>Sent: Tuesday, July 02, 2002 4:24 PM>To: WebCatalog Talk>Subject: Re: Deleteing Based On Dates>>>>I want to delete all entries that are 7 days old:>>>>[delete db=[log]&leDTdatarq=[math>>date]{[date]}-{00/07/0000}[/math]&DTtype=date]>>>>Deletes everything in the database (There are things in there from the 17th>>of June)>>>>Ideas?>>You aren't using Date as a field name, are you?>>Glenn>>------------------------------------------------------------->This message is sent to you because you are subscribed to> the mailing list .>To unsubscribe, E-mail to: >To switch to the DIGEST mode, E-mail to>>Web Archive of this list is at: http://search.smithmicro.com/>>>------------------------------------------------------------->This message is sent to you because you are subscribed to> the mailing list .>To unsubscribe, E-mail to: >To switch to the DIGEST mode, E-mail to >>Web Archive of this list is at: http://search.smithmicro.com/-- <= Brian C. Fries, BrainScan Software http://www.brainscansoftware.com =>-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/
Brian Fries
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
Spamming this list! (2000)
Moment of Thanks (1997)
Max Record length restated as maybe bug (1997)
the dreaded unitShipCost (2003)
WebCat on Intel Core 2 macs anyone? (2007)
autosensing lanague selection (1997)
carriage returns in data (1997)
Why this code works from some places and doesn't from others? (2000)
[WebDNA] Forum using Webdna (2009)
Authorize.net questions ... (2003)
anyone know how to set header for XML/RSS files? (2008)
Only charge card when product shipped ? (1997)
Status of variable hierarchy changes? (2000)
SELECT Into File (2006)
Multiple catalog databases and showcart (1997)
RE: WebCat cannot handle compatible search parameters? (1997)
WC2b15 File Corruption (1997)
emailer setup (1997)
Emailer (1998)
SetMIMEHeader ATTN:John P. (2001)