using date before 1/1/100 
Author Message
 using date before 1/1/100
How can i read dates = '01/01/0001' in an informix database ?
with ODBCDirect VB returns me 01/01/1901


Tue, 06 Nov 2001 03:00:00 GMT
 using date before 1/1/100

I think the Problem is VB's converter for the Dateformat the default for 0001 is 1 = 1901. You can slit the result in SQL and work with the results.
SELECT RIGHT('0' + LTRIM(str(datepart('d', gebdatum))), 2) AS Tag, RIGHT('0' + LTRIM(str(datepart('m', gebdatum))), 2) AS Monat, LTRIM(str(datepart('yyyy', gebdatum))) AS Jahr
FROM Mitglieder
(work with ACCESS97)

A other way is to convert via SQL in a String str(Field)

Quote:

>How can i read dates = '01/01/0001' in an informix database ?
>with ODBCDirect VB returns me 01/01/1901

-----------------** -- Posted from CodeGuru -- **-----------------
http://www.codeguru.com/vb         The website for VB programmers.


Tue, 06 Nov 2001 03:00:00 GMT
 
 [ 2 post ] 

 Relevant Pages 

1. Using b.c. Dates In Date fields

2. Using the Date value for assigning Today's date to a field

3. Using Julian Dates r.t. regular dates

4. Using a table of dates verses SQL Date Functions

5. Creating date using date in milliseconds

6. ((Current Date - Start Date)/(End Date - Start Date))*Contract Amt

7. Dates, Dates, & More Dates

8. SQL: Select some data with date criteria, but only by Date part of date field

9. DATE DATE DATE Filemaker and Month names

10. sp shell command using form with date parameter

11. using dates as stored procedure paramaters

12. Problem with date ranges using GETDATE()


 
Powered by phpBB® Forum Software