本文介绍了SQL查询问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 大家好,我确实有一个SQL数据库,其中的一个简单表包含几行:零件编号焊件编号长度SmartFeature1      SmartFeature2      SmartFeature3  SmartFeature4 .. SmartFeature15 S-00001        M-00283             150  A-01300-1 1.5  A-01301-3 0.5  A-01401-5   0.4  NULL                    NULL S-00002        M-00283             120  A-01300-1   1.49   A-00834-1   1.63  A-00174- 1个 3.47    NULL                    NULL .....等因此,我正在研究的S​​olidWorks应用正在为具有特征的模型中的结构构件创建字符串列表:该字符串可能类似于以下内容: * M-00283 120/A-01300-1 1.49/A-00174-1 3.47/A-00834-1 1.63/我可以将此字符串拆分成多个部分( M-00283 , A-01300-1 1.49 ,...等),然后开始寻找M-00283零件-那不是问题.在SQL中,如果找到M-00283以开始一直在该特定行中查找直到A-01300-1 1.49,而不是A-00174-1 3.47,而不是A-00834-1,是否存在一种方法1.63? (SQL中的S-00002-与 *,表示功能和暗淡匹配)我可以使用任何特殊技术吗?谢谢亚历克斯. Alex 解决方案 Hello guys,I do have SQL database with one simple table that consist a few rows:PartNumber WeldmentNumber Length SmartFeature1       SmartFeature2      SmartFeature3   SmartFeature4.. SmartFeature15S-00001         M-00283              150  A-01300-1 1.5     A-01301-3 0.5    A-01401-5 0.4   NULL                    NULLS-00002         M-00283              120   A-01300-1 1.49   A-00834-1 1.63  A-00174-13.47   NULL                    NULL.....etcSo the SolidWorks app Im working on is creating a list of strings for structural members that in the model with the features: the string may look like one below:* M-00283 120/A-01300-1 1.49/A-00174-1 3.47/A-00834-1 1.63/I can split this string up into pieces (M-00283, A-01300-1 1.49, ...etc) and start looking for M-00283 part - that`s not a problem.Is there a way in SQL if it finds M-00283 to start looking in that particular row all way to the end for A-01300-1 1.49, than for A-00174-1 3.47 than for A-00834-1 1.63 ? (S-00002 in SQL - matches with* , meaning the features and dims matching)Any special Technics I can use? Thank youAlex.Alex 解决方案 这篇关于SQL查询问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
06-20 23:37