how to load timestamp type in dataset in oracle and sqlserver

G

Guest

My app have two scenario. one type is base on sql server database,the other
is on oracle. In code, i used typed dataset to fill load data from DB.but i
met a problem,that the type of timestamp is differen between sql server and
oracle. so i can't define the type of timestamp cloumn in dataset. What can i
do? I don't want to use two class to do the same job.

thanks
 
M

Mary Chipman [MSFT]

Would converting the timestamp value to string work with your data
logic?

-mary
 
W

William Vaughn

How about defining the DataTable column as a SQL_VARIANT
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/tsqlref9/html/01229779-8bc1-4c7d-890a-8246d4899250.htm
It's designed to morph to any datatype...

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant, Dad, Grandpa
Microsoft MVP
INETA Speaker
www.betav.com
www.betav.com/blog/billva
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
Visit www.hitchhikerguides.net to get more information on my latest book:
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
and Hitchhiker's Guide to SQL Server 2005 Compact Edition (EBook)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top