简体   繁体   English

我应该写一个访问前端或c#前端吗?

[英]should i write an access front end or c# front end?

I have an Access database currently. 我目前有一个Access数据库。 There is a backend, and there are multiple users who use this database with their own front end. 有一个后端,有多个用户使用这个数据库和他们自己的前端。 The size of the data is very small; 数据的大小非常小; however there are several forms that are constantly in use. 但是有几种形式一直在使用。

I need to migrate the data to MySQL. 我需要将数据迁移到MySQL。 Should I continue to use an Access front end or program my own c# front end? 我应该继续使用Access前端还是编写我自己的c#前端? Why would one be better over the other? 为什么一个人比另一个好?

I think you all are either completely crazy or don't know a damned thing about Access. 我想你们都要么完全疯狂,要么不知道关于Access的诅咒。

It is certainly true that the upsizing tools for SQL Server are easier to use than anything available to you for upsizing to MySQL. 毫无疑问,SQL Server的升迁工具比升级到MySQL的任何可用内容更容易使用。 But the difficulty of upsizing should not drive your choice of back end, because it's a one-time choice. 但是升级的难度不应该推动你选择后端,因为它是一次性的选择。 Choose your back end database based on what works best for you. 根据最适合您的方式选择后端数据库。 While SQL Server Express is free, it has a number of limitations that MySQL itself does not have. 虽然SQL Server Express是免费的,但它有许多MySQL本身没有的限制。

As I said in comments, you can export an Access table to MySQL by defining a DSN for your MySQL database and simply using the EXPORT command on the Access file menu. 正如我在评论中所说,您可以通过为MySQL数据库定义DSN并在Access文件菜单上使用EXPORT命令将Access表导出到MySQL。 The results will not necessarily be perfect, so you might have to tweak the results, truncate the MySQL table and then insert the real data once the MySQL tables are all in place. 结果不一定是完美的,因此您可能必须调整结果,截断MySQL表,然后在MySQL表全部到位后插入实际数据。 Yes, this is more work than the SQL Server upsizing tools, but it's still pretty easy to do. 是的,这比SQL Server升迁工具更多的工作,但它仍然很容易做到。

And it's not something you have to get right on the first go, nor do you have to do it multiple times. 这不是你必须在第一时间做到正确的事情,也不是你必须多次这样做。

If MySQL is your preferred database engine for your app, then go with it. 如果MySQL是您的应用程序的首选数据库引擎,那么请继续使用它。 Using SQL Server entirely because of the more elaborate upsizing tools is really a case of the tail wagging the dog! 完全使用SQL Server是因为更加精细的升尺寸工具实际上是尾巴摇摆的情况!

I would recommend migrating to SQL Server instead of MySQL. 我建议迁移到SQL Server而不是MySQL。 You could simply upsize the Access database to SQL Server and let it handle the heavy lifting on data. 您可以简单地将Access数据库升迁到SQL Server,并让它处理繁重的数据。 Access forms can continue to be your front end. 访问表单可以继续作为您的前端。

Per David Fenton below in comments: "Upsizing is a one-time operation and ease of doing so shouldn't drive the choice of back end." Per David Fenton在下面的评论中说:“升迁是一次性的操作,这样做的好处不应该推动后端的选择。” I think this is a good argument. 我认为这是一个很好的论据。 I recommended SQL Server for ease of upsizing and existing tools, but this rebuttal brings MySQL back into the picture for me. 我推荐使用SQL Server以便于升级和使用现有工具,但这种反驳让MySQL重新回到了我的面前。

Rewriting the front end will make this project more complicated, not simpler. 重写前端将使这个项目更复杂,而不是更简单。 Migrate the backend first, then evaluate whether there is a need to rewrite the UI. 首先迁移后端,然后评估是否需要重写UI。 You may need to make some code changes to adapt Access to the new back end data source, but this will be far less effort than a full rewrite. 您可能需要进行一些代码更改以使Access适应新的后端数据源,但这比完全重写要少得多。

If you migrate to SQL Server instead of MySQL you could develop your front-end in C# and use for it the built-in LINQ capabilities to access your data. 如果迁移到SQL Server而不是MySQL,则可以使用C#开发前端,并使用内置的LINQ功能来访问数据。 Much easier and gratifying than Access front-end with Visual Basic for Applications ;-) 使用Visual Basic for Applications比Access前端更容易和令人满意;-)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM