更新程序“N/A” MS Access 上的空字符串
目前,我在 MS Access 中有一个名为 Total Registrants 的表。如何将字符串“N/A”插入到“EventRegCompany”列有空白单元格的单元格中? 我创建了一个更新查询
UPDATE Test SET Test.eventRegCompany = "N/A" WHERE (((Test.eventRegCompany)=NULL)); 谢谢!
I currently have a table in MS Access called Total Registrants. How can I insert string "N/A" into the cells of the column "EventRegCompany" where there are blank cells?
I created an update query
UPDATE Test SET Test.eventRegCompany = "N/A"
WHERE (((Test.eventRegCompany)=NULL));
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我想通了
更新测试集 Test.eventRegCompany = "N/A" WHERE (((Test.eventRegCompany) IS NULL));
I figured it out
UPDATE Test SET Test.eventRegCompany = "N/A" WHERE (((Test.eventRegCompany) IS NULL));
您已经找到了所需的 SQL,但没有人提供其工作原理的解释。
Null 是一个特殊的实体——它永远不等于任何东西,因为它真正的意思是“未知的值”。由于这些值是未知的,我们不能说它们中的任何两个相等,除了它们的状态为空(因此“为空”)。
有关 Nulls 的特定于 Access/Jet/ACE 的讨论,请参阅 Allen Brown 的精彩文章:
这里解释的概念不仅适用于 Access/Jet /ACE,这是我所知道的最清晰的解释。
You've found the SQL you need, but nobody has provided the explanation of why it works that way.
Null is a special entity -- it is never equal to anything at all because what it really means is "unknown value." Since the values are unknown, we can't say that any two of them are equal, except in their status of being Null (hence "Is Null").
For Access/Jet/ACE-specific discussions of Nulls, see Allen Brown's nice articles:
The concepts explained there apply not just to Access/Jet/ACE and it's as clear an explanation as I'm aware of.