1.这是需要查询string的示例(txt文件)
vivo X5S L
CHE-TL00H
G621-TL00
vivo Y51A
KIW-AL10
Samsung SM-G9200
XiaoMi MI PAD
Samsung SM-G9008V
XiaoMi MI 4C
MX4 Pro
R7007
ALE-TL00
iPad3_4
XiaoMi HM NOTE 1TD
HUAWEI P7-L09
iPhone8_4
2.在Mysql中有这样的一张表(示例)
mid bid sid type productname
p1 mobile81 s000 mobile 多普达S900(Touch Diamond)
p2 mobile81 s000 mobile 多普达T8388(麒麟)
p3 mobile81 s000 mobile 多普达T8588
p4 mobile81 s265 mobile 多普达S1(触动版)
p5 mobile81 s000 mobile 多普达696
p6 mobile81 s000 mobile 多普达838
p7 mobile81 s000 mobile 多普达T2222(Touch Viva)
p8 mobile81 s265 mobile 多普达S1
p9 mobile81 s000 mobile 多普达T5399
p10 mobile81 s267 mobile 多普达A6188
p11 mobile81 s264 mobile 多普达D600(活力版)
p12 mobile81 s000 mobile 多普达P800
p13 mobile81 s000 mobile 多普达C720
p14 mobile81 s264 mobile 多普达D600
3.
需要查询1中在2中的结果并返回mid
Firstly, I have implemented one according to the idea of the topic owner, which should be what the topic owner wants.
If you find any mistakes, please try your best to hit them
You are missing a layer of key-value pair relationships. The English in the txt file corresponds to the productname and its product_code in the data table. This kind of query is too tiring. You might as well use stored procedures or functions or code tools to handle it