Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Transformation using CDATE
Message
 
To
All
General information
Forum:
Microsoft SQL Server
Category:
Import/Export
Title:
Transformation using CDATE
Miscellaneous
Thread ID:
00417891
Message ID:
00417891
Views:
51
I assume that any date form determined by ISDATE to be a valid date form should also be transformable using CDATE. The destination SQLServer7 table has a "start_date" field with datetime data type. The source is CSV text with a date form like [01/30/2000 07:17:11]. This date form results from a VFP remote view of an Oracle table, exported to CSV. It is a valid Microsoft datetime while it is in the remote view. ISDATE says it is a valid date form when using the SQL7 Query Analyzer. But when CDATE is used in my DTS transformation, it does not seem to recognize the form as valid. And the Query Analyzer does not recognize CDATE as a valid function.

I guess I have the proper syntax. From SQL BOL:
__________
Transforming Date Data
When importing data from a file to an OLE DB destination table, you may need to use the CDATE function to convert date data if the date format is in a text or character field and is not in the format required by OLE DB, which is yyyy-mm-dd hh:mm:ss:sss:

function main()

DTSDestination("Total Sales") = DTSSource("Total Sales ")
DTSDestination("DestColumnDate") = CDATE(DTSSource("SourceColumnDate"))

Main = DTSTransformStat_OK

end function
__________

Could my problem be occurring because I'm using ODBC instead of OLE DB?
Next
Reply
Map
View

Click here to load this message in the networking platform