比较访问中的字符串集

时间:2015-12-17 10:15:06

标签: string compare

我有一个问题,我认为您也可以在需要时使用。我希望比较由OrderLIKE(正常)标识的单独表格上的字集和单词或值。

以下是该表的快照:

enter image description here

然后我希望完成的结果是这样的:

enter image description here

比较是{{1}}而不是相等。

1 个答案:

答案 0 :(得分:0)

您可以在谓词中执行join并拥有like

select * from table1 t1
inner join table2 t2 on t1.ValueA like '%' + t2.ValueB + '%' or 
                        t2.ValueB like '%' + t1.ValueA + '%'

您可能需要使用*代替%&代替+。我不记得Access的正确语法,但它也是如此。

相关问题