Here is a sample of my table. Field1 datatype is Memo.
Here is a query on that table:
And a sample result from the query:
I am trying to convert the memo field to a date, where applicable, so I can then search the field for dates less than a given date.
But, when I run, for example, this code:
I get rs.nomatch=true.
Same holds for rs.findfirst. It does seem to be able to find !ddate=#1/17/1955#.
How do I get it to find the other dates? I am thinking it's not recognizing them as dates. I've also tried rs.findnext cdate(rs!ddate)>#1/17/55#, no difference.
ID Field1
75244541 ----------------------
75244542 1/25/2009 11:04:49 PM
75244543 Database: A
75244544 GetFileSize
75244545 Source: none
75244546 Err# none
75244547 ----------------------
75244548 1/26/2009 12:04:49 AM
75244549 Database: B
75244550 GetFileSize
75244551 Source: none
75244552 Err# none
75244553 ----------------------
75244554 1/26/2009 12:19:49 AM
75244555 Database: C
75244556 Starting TaskSuccess(PCA2kDaily)
75244557 Source: none
75244558 Err# none
75244559 ----------------------
Here is a query on that table:
select id,field1,cdate(iif(isdate(field1),cdate(field1),#1/17/55#)) as dDate from accesslog order by id
And a sample result from the query:
id field1 dDate
75244541 ---------------------- 1/17/1955
75244542 1/25/2009 11:04:49 PM 1/25/2009 11:04:49 PM
75244543 Database: A 1/17/1955
75244544 GetFileSize 1/17/1955
75244545 Source: none 1/17/1955
75244546 Err# none 1/17/1955
75244547 ---------------------- 1/17/1955
75244548 1/26/2009 12:04:49 AM 1/26/2009 12:04:49 AM
75244549 Database: B 1/17/1955
75244550 GetFileSize 1/17/1955
75244551 Source: none 1/17/1955
75244552 Err# none 1/17/1955
75244553 ---------------------- 1/17/1955
75244554 1/26/2009 12:19:49 AM 1/26/2009 12:19:49 AM
75244555 Database: C 1/17/1955
75244556 Starting TaskSuccess(PCA2kDaily) 1/17/1955
75244557 Source: none 1/17/1955
75244558 Err# none 1/17/1955
75244559 ---------------------- 1/17/1955
I am trying to convert the memo field to a date, where applicable, so I can then search the field for dates less than a given date.
But, when I run, for example, this code:
Set RS = DB.OpenRecordset("select id,field1,cdate(iif(isdate(field1),cdate(field1),#1/17/55#)) as dDate from accesslog order by id", dbOpenDynaset)
rs.FindNext !dDate > #1/17/1955#
I get rs.nomatch=true.
Same holds for rs.findfirst. It does seem to be able to find !ddate=#1/17/1955#.
How do I get it to find the other dates? I am thinking it's not recognizing them as dates. I've also tried rs.findnext cdate(rs!ddate)>#1/17/55#, no difference.