2013-12-26 06:23 keltezéssel, MinnesotaJon írta: > It appears that the problem happens if the first letter of the string being > matched appears anywhere in the "Pattern" before the actual match. Your > original examples were: > > Print "GambasIDE" Like "{alma,Gambas,szilva,GambasIDE,otto}" > Output: False > > Print "GambasIDE" Like "{alma,GambasIDE,szilva,Gambas,otto}" > Output: True > > *Actually, any "g" in the list, before "GambasIDE", will interfere with the > match:*
Print "GambasIDE" Like "{alma,Gambas,szilva,GambasIDE,otto}" Output: False But this: Print "GambasIDE" Like "{alma,GambasA,szilva,GambasIDE,otto}" Output: True So if the full-length word isn't included in the other, this problem doesn't occur. But the small and capital letters really don't matter. > Print "GambasIDE" Like "{alma,g,szilva,GambasIDE,otto}" > Output: False Yes, "False" with the words: "g", "ga", "gam", "gamb", "gamba" and "gambas". > but: > > Print "GambasIDE" Like "{alma,szilva,otto,GambasIDE,g}" > Output: True > > It is only the *first letter* in the "Pattern" that is a problem -- the > other letters do not have any bad effect. If we delete the "g" from the > word "Gambas", the result is correct: > > Print "GambasIDE" Like "{alma,ambas, ambasIDE,szilva,GambasIDE,otto}" > Output: True Yes, but this not good for me. > *Note that if you use the "*" symbol, it eliminates the problem:* > > Print "GambasIDE" Like "*{alma,Gambas,szilva,GambasIDE,otto}*" > Output: True > > *....* eliminates the sensitivity of the patterns to their location in the > list. Yes, one "*" is enough to end: Print "GambasIDE" Like "{alma,Gambas,szilva,GambasIDE,otto}*" Output: True But this not good for me, because GambasIDE <> GambasID Print "GambasID" Like "{alma,Gambas,szilva,GambasIDE,otto}*" Output: True But of course I need equivalency. > Regards, > Jon > > > Kendek ------------------------------------------------------------------------------ Rapidly troubleshoot problems before they affect your business. Most IT organizations don't have a clear picture of how application performance affects their revenue. With AppDynamics, you get 100% visibility into your Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro! http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user