我有两列。我想比较那两个中的一些算术词。如果A列具有“hp A234f printer”而列B具有“a234f”。然后它将显示resullt [英] i have two column .i want to compare some mathching word in those two.like if A column having"hp A234f printer".and column B having "a234f" then it ll show the resullt

查看:99
本文介绍了我有两列。我想比较那两个中的一些算术词。如果A列具有“hp A234f printer”而列B具有“a234f”。然后它将显示resullt的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

列A:B列:
hp 1234打印机1234
hp 123456打印机abcd
佳能1234打印机空白





结果应该是:

 AB 
hp 1234 printer 1234

解决方案

  SELECT  *  FROM  table1  WHERE  
[ A] LIKE ' %' + [ B] + ' %'


column A:                column B:
hp 1234 printer          1234
hp 123456 printer        abcd
canon 1234 printer       blank



result should be:

A                        B
hp 1234 printer          1234

解决方案

SELECT * FROM table1 WHERE
[column A] LIKE '% '+ [column B] +' %'


这篇关于我有两列。我想比较那两个中的一些算术词。如果A列具有“hp A234f printer”而列B具有“a234f”。然后它将显示resullt的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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