.NET DBF 数据库连接问题
嘿大家,真的在这里用头撞键盘,任何信息或指向正确的方向都会很棒。
我有一组带有 .MDX 索引的 .DBF 文件。 它们应该是 dBASE 版本 7,但根据我的发现,Borland BDE 只能可靠地连接到 5.0。
我可以使用 IV 和 5.0 连接字符串进行连接,如下所示:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\IDS\PowerSell\MyData\;Extended Properties=dBASE 5.0;
我得到的模式与表的实际模式不同,我必须运行尴尬的切碎查询,结果只是来自我的问题我得到:
- 在大多数列上选择都很好,但是 某些列将无法
- 如果我留在某些列上, 插入 我会收到错误
- 否则,如果我不提供位置, 更新 是否
有人对通过 MDX 索引和 .NET 连接和使用 DBF 文件有任何见解? 最有可能的是 dBASE 7 文件?
谢谢,
Hey all, really bashing my head against a keyboard here, any information or pointing in the right direction would be fantastic.
I have a set of .DBF files with .MDX indexes. They're supposed to be dBASE version 7, but the Borland BDE only connects to 5.0 reliably from what I've found.
I can get connected using the IV and 5.0 connection string as follows:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\IDS\PowerSell\MyData\;Extended Properties=dBASE 5.0;
The schema I get is off from what the actual schema of the table is, and I have to run awkward chopped up queries, the results of just come of the problems I'm getting:
- select just fine on most columns but
some columns don't work - insert if I leave on some columns
otherwise I get errors - update if I don't provide a where
clause
Does anyone have any insight into connecting and using DBF files with an MDX index and .NET? Most likely dBASE 7 files?
Thanks,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否尝试过 System.Data.Odbc 驱动程序(不是 OldeDb)?
总而言之,要小心。 我记得有 1 个产品(BDE 或 ODBC)取消了对 FoxPro 数据库的支持,并表示“更新未经认证”之类的。 总而言之,那些“较新”的 DBF 格式通常不会带来任何乐趣,只会带来不兼容性。 您可能想要调查您拥有的 ODBC 驱动程序版本/级别以及您需要的版本/级别。
如果可以,导出数据并以另一种格式运行。
Have you tried a System.Data.Odbc driver (not OldeDb) ?
All in all, be careful. I remember 1 product (BDE or ODBC) retracting support for FoxPro database, saying "updating is not certified" or something. All in all, those 'newer' DBF formats usually bring no joy, just incompatibilities. You may want to investigate what version/level ODBC drivers you've got versus what you need.
If you can, export the data and run to another format.
Sybase 的 Advantage Database(ADS/Advantage 数据库服务器)应该能够与 Foxpro 和早期的 dBase 文件配合良好,并且是目前受支持的产品,作为 BDE(Borland 数据库引擎)的理想替代品上市,请访问 www.sybase.com /优势
The Advantage Database (ADS/Advantage database Server) from Sybase is supposed to work well with Foxpro and earlier dBase files and is a currently supported product marketted as an ideal replacement for the BDE (Borland Database Engine), check out www.sybase.com/advantage