In a SQL server, how can I query an Oracle Timestamp column through a Linked Server connection?

The query I made in oracle does not work with the linked server with SQL Server 2008.

OLE DB provider "MSDAORA" for linked server "ORACLE" supplied incorrect metadata for column "DATETIME_INS". The data type is not supported.

Inquiry:

select * from ORACLE..U_GERAN.CELLSTATS4 

enter image description here

What modification needs to be done to complete the request.

+4
source share
1 answer

Try

 SELECT * FROM OPENQUERY(ORACLE, 'select cast(DATETIME_INS as DATE) from U_GERAN.CELLSTATS4') 

You can add other columns to the query after this column has worked.

+4
source

Source: https://habr.com/ru/post/1403427/


All Articles