Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Link Server + VFP Data
Message
From
26/05/2005 21:44:42
 
 
To
All
General information
Forum:
Microsoft SQL Server
Category:
Import/Export
Title:
Link Server + VFP Data
Miscellaneous
Thread ID:
01017988
Message ID:
01017988
Views:
67
Hi I have old Foxdata (vfp5 ) and i want to open it to SQL server.Currently I can fetch data on some table but there are some some that i cant open. I notice on on some field with numeric(10,2) data type and date datatype with values {}. Do you have any solution ? my current solution for Numeric are as follow but for date data i received some error
EXEC sp_addlinkedserver 
   @server = 'LNK_VINS', 
   @provider = 'VFPOLEDB.1', 
   @srvproduct = '',
   @datasrc = 'D:\nosij\vinstron\MIS\Data\mis.dbc'
go
This one work with numeric(10,2)
Select A.*
 FROM OPENQUERY( LNK_VINS,'SELECT pro_code,val(transform(price1,"999999.99")) as Price1,FROM Products where !deleted()') AS a
This is with a date problem and i can make it work
Select   *
FROM OPENQUERY( LNK_VINS,
   'SELECT chkdate  FROM paytran where !deleted()') 
order by 1
This are the errors on date
Server: Msg 8114, Level 16, State 10, Line 11
Error converting data type DBTYPE_DBDATE to datetime.
This are the errors when fetching NUmeric data
Select A.*
 FROM OPENQUERY( LNK_VINS,'SELECT pro_code,price1 FROM Products where !deleted()') AS a
Server: Msg 7341, Level 16, State 2, Line 1
Could not get the current row value of column '[a].price1' from the OLE DB provider 'VFPOLEDB.1'. The provider cannot determine the value for this column.
OLE DB error trace [OLE/DB Provider 'VFPOLEDB.1' IRowset::GetData returned 0x80040e21:  Data status returned from the provider: [COLUMN_NAME=price1 STATUS=DBSTATUS_E_UNAVAILABLE]].
Thanks
Roses are #FF0000 Violets are #0000FF all my base are belong to you
Next
Reply
Map
View

Click here to load this message in the networking platform