Postgres到MS Access [英] postgres to MS Access
问题描述
我将要开始一个需要将数据库加载到MS Access 2003中的项目(我认为它使用JET db).我不能忍受使用MS Access gui/界面的想法,并且想知道是否有可能在Postgres中构建数据库并将其移植到MS Access或输出可以在Windows上加载的.mdb
.从我的搜索看来,似乎有很多MS Acess到Postgres的迁移教程/设施,但我找不到任何相反的方向.
I am about to start working on a project that requires the database to be loaded in MS Access 2003 (I think it uses JET db). I can't stand the idea of using the MS Access gui/interface and was wondering if it were at all possible to build the database in Postgres and port it to MS Access or output an .mdb
that I could load on windows. From my searches, it seems there are lots of MS Acess to Postgres migration tutorials/facilities but I couldn't find anything going in the opposite direction.
如何在Postgres中建立数据库并输出某种转储文件,该文件将在MS Access中加载?
How can I build my db in Postgres and output some kind of dump file that will load up in MS Access?
推荐答案
在 PostgreSQL ODBC驱动程序上安装您的Windows计算机.
Install the PostgreSQL ODBC driver on your Windows machine.
创建一个指向您的PostgreSQL数据库的DSN.
Create a DSN which points to your PostgreSQL database.
启动Access会话,并使用DSN导入PostgreSQL表.
Start an Access session and use the DSN to import the PostgreSQL tables.
我过去已经做过几次,发现它又快又简单.使用ODBC驱动程序进行访问会将PostgreSQL列数据类型转换为与Access兼容的类型.
I've done this a few times in the past and found it quick and easy. Access with the ODBC driver will translate the PostgreSQL column data types to Access-compatible types.
此方法应适用于简单表.但是,如果您的设计使用了PostgreSQL的高级功能,则这些功能可能无法很好地(或根本无法)转换为Access.
This approach should work for simple tables. However if your design uses advanced PostgreSQL features, those may not translate well (or at all) to Access.
但是,由于尚未创建数据库,因此建议您允许使用Access表设计GUI.首先,在Access中设计数据库对我来说似乎更简单.
However, since you haven't created the database yet, I encourage you to tolerate the Access table design GUI. It seems simpler to me to design the database in Access in the first place.
这篇关于Postgres到MS Access的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!