Hi,
Can someone please help. I am running the following sql from the query analyzer and vb:
select * from DWCSYPER where convert(datetime,CPFDAT) < '02/01/2000'
Where CPFDAT is a field with datatype char.
When run from vb, I get no records - when run from the Analyzer, I get one record (correct). VB doesn't seem to like the where clause. Does anyone know why?
BTW I can't change the design of the table to make CPFDAT into a date datatype as values are imported into the table in text format.
Thanks,
Gillian
[sig][/sig]
Can someone please help. I am running the following sql from the query analyzer and vb:
select * from DWCSYPER where convert(datetime,CPFDAT) < '02/01/2000'
Where CPFDAT is a field with datatype char.
When run from vb, I get no records - when run from the Analyzer, I get one record (correct). VB doesn't seem to like the where clause. Does anyone know why?
BTW I can't change the design of the table to make CPFDAT into a date datatype as values are imported into the table in text format.
Thanks,
Gillian
[sig][/sig]