为什么在 Visual Studio 2010 中的数据比较中缺少所有表? [英] Why are all tables missing in data comparison in visual studio 2010?

查看:28
本文介绍了为什么在 Visual Studio 2010 中的数据比较中缺少所有表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用 Visual Studio 2010 中的数据比较功能来查看两个不同数据库中的几个表之间有什么不同.两个数据库都是本地的,我可以看到它们并从我正在寻找的表中查询数据.但是,根据 MSDN.结构比较部分工作得很好.对于一些看起来很简单的事情,我可能会遗漏任何想法吗?

I'm trying to use the data comparison feature in visual studio 2010 to see what's different between a couple of tables in two different databases. Both of the database are local and I can see them and query data from the tables I'm looking for. However, on the data comparison wizard, I'm not seeing a list of tables like I should be, according to MSDN. The structural compare part work just fine. Any ideas I might be missing on something that seems straight forward?

推荐答案

找到了答案.链接中的一个注释我说过模式必须匹配,并且必须有一个唯一的或主键或索引.添加主键后还是不行.终于意识到案例在数据定义中很重要.一个数据库有驼峰式大小写,另一个是大写.将大写字母更改为驼峰大小写即可.

Found the answer. One of the notes in the link I had said that the schemas had to match and there has to be a unique or primary key or index. After adding a primary key it still didn't work. Finally realized that case matters in the data definition. One database had camel case and the other was all upper case. Changing the upper case one to camel case made it work.

我没有意识到大小写对 MSSQL 很重要,尤其是因为结构比较有效.

I didn't realize that case mattered on MSSQL, especially since the structure compare worked.

另外:名称必须匹配.由于 EF,我没有意识到一个是复数,另一个是单数.检查名称是否相同.

Additionally: The Names must match. I didnt realize one was plural and the other singular due to EF. Check the names are identical.

这篇关于为什么在 Visual Studio 2010 中的数据比较中缺少所有表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆