问题描述
大家好,
我是XP上Access 2000的初级用户。
我正在尝试创建查询来自1300多条记录的表格。我需要通过他们的SSN查找个人,这是表的主键)我需要一次查找几个。此外,每次运行此查询时,我都会查找不同的人。
这是SQL:
Hi everyone,
I am a beginning to intermediate user with Access 2000 on XP.
I am trying to create a query from a table of more than 1300 records. I need to look up individuals by their SSN only which is the primary key for the table) and I need to look up several at a time. Also, I will be looking up different individuals every time I run this query.
This is the SQL:
推荐答案
a快捷简单的方法是创建一个表来放置你的ssn''s
然后在你的查询中,你可以使用
select * from table1 where ssn IN(从ssntable选择ssn)
a quick easy way would be to create a table to put your ssn''s
then in your query, you can use it
select * from table1 where ssn IN(Select ssn from ssntable)
这篇关于在一个字段上使用多个条件查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!