RE: LIKE sql optimization

2014-02-12 Thread Zhigang Zhang
Done. Thand you very much! Zhigang _ From: Jesper Wisborg Krogh [mailto:my...@wisborg.dk] Sent: Wednesday, February 12, 2014 5:30 PM To: Morgan Tocker; Zhigang Zhang Cc: mysql@lists.mysql.com Subject: Re: LIKE sql optimization On 12/02/2014 13:16, Morgan Tocker wrote: Hi

Re: LIKE sql optimization

2014-02-12 Thread Jesper Wisborg Krogh
On 12/02/2014 13:16, Morgan Tocker wrote: > Hi Zhigang, > > On Feb 11, 2014, at 8:48 PM, Zhigang Zhang wrote: > >> I want to know the reason, in my opinion, to scan the smaller index data has >> better performance than to scan the whole table data. > I think I understand the question - you are as

RE: LIKE sql optimization

2014-02-11 Thread Zhigang Zhang
Thank you very much! Zhigang -Original Message- From: Morgan Tocker [mailto:morgan.toc...@oracle.com] Sent: Wednesday, February 12, 2014 10:16 AM To: Zhigang Zhang Cc: mysql@lists.mysql.com Subject: Re: LIKE sql optimization Hi Zhigang, On Feb 11, 2014, at 8:48 PM

Re: LIKE sql optimization

2014-02-11 Thread Morgan Tocker
Hi Zhigang, On Feb 11, 2014, at 8:48 PM, Zhigang Zhang wrote: > I want to know the reason, in my opinion, to scan the smaller index data has > better performance than to scan the whole table data. I think I understand the question - you are asking why MySQL will not index scan, find matching

RE: LIKE sql optimization

2014-02-11 Thread Zhigang Zhang
I checked a myisam table index, the index is a copy of the whole field. Zhigang -Original Message- From: Reindl Harald [mailto:h.rei...@thelounge.net] Sent: Wednesday, February 12, 2014 10:02 AM To: mysql@lists.mysql.com Subject: Re: LIKE sql optimization because a index

Re: LIKE sql optimization

2014-02-11 Thread Mathieu Desharnais
smaller index data >> > has >> > better performance than to scan the whole table data. >> > >> > >> > >> > >> > >> > zhigang >> > >> > >> > >> > _ >> > >> > From: Mathieu Desharnais [mai

Re: LIKE sql optimization

2014-02-11 Thread louis liu
ailto:mdesharn...@diffusion.cc] > > Sent: Wednesday, February 12, 2014 9:41 AM > > To: Zhigang Zhang; mysql@lists.mysql.com > > Subject: Re: LIKE sql optimization > > > > > > > > Sql database doesn't use index in like statement if it starts with % .

Re: LIKE sql optimization

2014-02-11 Thread Reindl Harald
data has > better performance than to scan the whole table data. > > From: Mathieu Desharnais [mailto:mdesharn...@diffusion.cc] > Sent: Wednesday, February 12, 2014 9:41 AM > To: Zhigang Zhang; mysql@lists.mysql.com > Subject: Re: LIKE sql optimization > > Sql database doe

Re: LIKE sql optimization

2014-02-11 Thread kitlenv
t; _ > > From: Mathieu Desharnais [mailto:mdesharn...@diffusion.cc] > Sent: Wednesday, February 12, 2014 9:41 AM > To: Zhigang Zhang; mysql@lists.mysql.com > Subject: Re: LIKE sql optimization > > > > Sql database doesn't use index in like statement if it start

RE: LIKE sql optimization

2014-02-11 Thread Zhigang Zhang
@lists.mysql.com Subject: Re: LIKE sql optimization Sql database doesn't use index in like statement if it starts with % .. like 'abcd%' would work though... To use an index you can store your value using reverse function and index it .. then your like would use the index. 2

Re: LIKE sql optimization

2014-02-11 Thread Mathieu Desharnais
Sql database doesn't use index in like statement if it starts with % .. like 'abcd%' would work though... To use an index you can store your value using reverse function and index it .. then your like would use the index. 2014-02-11 20:23 GMT-05:00 Zhigang Zhang : > For example: > > > > Select

Re: LIKE sql optimization

2014-02-11 Thread Reindl Harald
Am 12.02.2014 02:23, schrieb Zhigang Zhang: > For example: > > Select * from T where col like ‘%abcd’; > > The table T is myisam table and we created a index on col. > > As we known, this like sql does not use the index created on col, it confuse > me, why? > > I think in mysiam engine, the i

Re: Like Syntax

2009-12-07 Thread Johan De Meersman
Have you considered Reading The *Fine* Manual at http://dev.mysql.com/doc/#manual ? On Sat, Dec 5, 2009 at 4:59 PM, Victor Subervi wrote: > Hi; > I remember vaguely how to do this but don't know how to google it: > > show tables like categories$; > > such that it will return tables such as: > >

Re: Like Syntax

2009-12-05 Thread Victor Subervi
On Sat, Dec 5, 2009 at 11:09 AM, Michael Dykman wrote: > show tables like 'categories%'; > Thanks. V

Re: like isn't behave as expected

2009-02-04 Thread Olaf Stein
>From http://dev.mysql.com/doc/refman/5.0/en/string-comparison-functions.html#oper ator_like: Note Because MySQL uses C escape syntax in strings (for example, ³\n² to represent a newline character), you must double any ³\² that you use in LIKE strings. For example, to search for ³\n², specify it

RE: like isn't behave as expected

2009-02-04 Thread Jerry Schwartz
>-Original Message- >From: Yariv Omer [mailto:yar...@jungo.com] >Sent: Wednesday, February 04, 2009 10:50 AM >To: mysql@lists.mysql.com >Subject: like isn't behave as expected > >Hi > >i have one row in the cpe_id column of the cpe_users table in my >database with the value: "d\d". > >when

Re: LIKE problem with characters 'å' (norwe gian) and 'a' (mysql bug?)

2008-02-29 Thread Kent Larsson
> I get incorrect result when searching for the norwegian character 'å' > using LIKE. I get rows with 'a' in it, and visa versa if I search for > 'a', I get results which has 'å' in it in addition to the ones with 'a'. Make sure that your table has: charset=utf8 collation=utf8_norwegian_ci A

Re: Like inside in clause

2006-09-14 Thread Brent Baisley
You probably want to look into using RLIKE or REGEXP. SELECT id,name FROM tabename WHERE name RLIKE '^[abc]' - Original Message - From: "Ravi Kumar." <[EMAIL PROTECTED]> To: Sent: Thursday, September 14, 2006 7:37 AM Subject: Like inside in clause Dear Friends, Is there a way to s

Re: Like inside in clause

2006-09-14 Thread Thomas Spahni
On Thu, 14 Sep 2006, Ravi Kumar. wrote: > Is there a way to specify wildcard inside values of an in clause. I want to > be able to do this: > > select id, name from tableName where name in ('a%', 'b%', 'c%'); > > instead of doing > > select id, name from tableName where name like 'a

Re: 'LIKE' for numbers

2005-12-18 Thread Gleb Paharenko
Hello. > Let's say I wanted to select all rows where column x has a value of ~y Please, could you explain, what does it mean x ~ y. LIKE works for integer, at least in traditional way: mysql> create table tint(a int); Query OK, 0 rows affected (0.04 sec) mysql> insert into tint set a=

Re: 'LIKE' for numbers

2005-12-18 Thread Jochem van Dieten
On 12/18/05, Andy Pieters <[EMAIL PROTECTED]> wrote: > > Is there any operator for mysql that behaves like "LIKE" but can act on > numbers. No. But with a bit of creativity you can use arithmetic to come to a predictae that does the same: SELECT * FROM table WHERE floor(log10(floor(x / y))) <>

Re: 'LIKE' for numbers

2005-12-18 Thread Mark Phillips
In a jsp application I created, I had a similar problem. I defined a constant 'spread' and then searched for values of x that x>= y-spread and x<=y+spread. I then configured the spread value from web.xml, so I could fine-tune the spread when the application was in testing. We didn't have the act

Re: 'LIKE' for numbers

2005-12-18 Thread Yves Goergen
On 18.12.2005 11:06 (+0100), Andy Pieters wrote: > Is there any operator for mysql that behaves like "LIKE" but can act on > numbers. > > Let's say I wanted to select all rows where column x has a value of ~ y > > How should I do this? You can use BETWEEN x AND y or maybe also IN (x, x+

Re: LIKE problem part II

2005-11-19 Thread Peczöli Zoltán
Exporting and then importing the table helped, now both the regexp and the like query produce the same result. I saved the table MYI file and will keep experimenting with it, maybe I can come up with something useful. Thanks for the idea. Zoltan On Fri, 18 Nov 2005, Scott Haneda wrote: on 1

Re: LIKE problem part II

2005-11-18 Thread Scott Haneda
on 11/18/05 7:18 AM, Peczöli Zoltán at [EMAIL PROTECTED] wrote: > The result of the second query matches that of the corresponding LIKE > query, but the first seems to be correct. > > Any ideas what the problem might be? You are getting strange results. At this point I would suggest dumping the

Re: LIKE problem?

2005-11-14 Thread Gleb Paharenko
Hello. Really, seems a bit weird for me. I suggest you to check your 'character_set_xxx' variables to be sure that there're no unnecessary translations from one encoding to another. If you're able to make a small repeatable test case, install on your Debian server second instance of MySQL (u

Re: LIKE problem?

2005-11-12 Thread delta
select count(*) from user where username like 'a%'; select count(*) from user where username not like 'a%' or username is null; is not the same for all letters of the alphabet: letter like not-like sum n 2304 59317 61621 o 0 60797 60797 p 3048 58573 61621 Sounds like a

Re: LIKE problem?

2005-11-11 Thread Jeremy Cole
Hi, Moreover, the sum of the results of these two queries select count(*) from user where username like 'a%'; select count(*) from user where username not like 'a%' or username is null; is not the same for all letters of the alphabet: letter like not-like sum n 2304 59317 61621 o

Re: LIke

2005-06-28 Thread Michael Stassen
Jerry Swanson wrote: How to make this work? field like '%DATA_FORMAT(now(), '%m%d%y') %' field LIKE CONCAT('%',DATE_FORMAT(now(), '%m%d%y'),'%'); -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: LIKE question - is it possible?

2005-04-14 Thread Stefan Kuhn
Not sure if your query works. But what should work is SELECT * FROM table WHERE c LIKE "%word1%" and c LIKE "%word2%" and c LIKE "%word3%"; But might be slow ... Am Thursday 14 April 2005 13:53 schrieb Micha Berdichevsky: > Hi group. > I have a table with a varchar(250) column in it (let's call

RE: LIKE question - is it possible?

2005-04-14 Thread mel list_php
I think that if you explode your words with AND it should work in any order: SELECT * FROM table WHERE c LIKE '%word1%' AND c LIKE '%word2%' AND c LIKE '%word3%'; but there's maybe something better to do! From: Micha Berdichevsky <[EMAIL PROTECTED]> To: mysql@lists.mysql.com Subject: LIKE questi

Re: LIKE question - is it possible?

2005-04-14 Thread Alec . Cawley
Micha Berdichevsky <[EMAIL PROTECTED]> wrote on 14/04/2005 12:53:31: > Hi group. > I have a table with a varchar(250) column in it (let's call it c) > I want to select values that contain a number of given words in them > (three or more), in any words order > I currently use > SELECT * FROM table

Re: Like statement help

2005-01-18 Thread SGreen
Craig Hoffman <[EMAIL PROTECTED]> wrote on 01/18/2005 04:17:30 PM: > Hi There, > I have web form where a user can search certain fields and then have > them displayed aggregated. For example, find all the routes I climbed > with partner A in area(s) ALL (% - wildcard) between date1 and date2 --

RE: Like - Problem

2004-09-23 Thread Laercio Xisto Braga Cavalcanti
Try the following sintax: Select * from fruits where (fruits.color like '%Green%' or fruits.color like '%Apple%') or (fruits.type like '%Green%' or fruits.type like '%Apple%'); Regards, Laercio. -Original Message- From: Rui Monteiro [mailto:[EMAIL PROTECTED] Sent: quarta-feira, 22

Re: Like - Problem

2004-09-23 Thread gerald_clark
This is the third time you have asked this, and it has been answered twice. Once is enough. Rui Monteiro wrote: Hello there, I was wondering how I could make a specific type of search when the string has more than one word. Ex.- String = "Green Apple"

Re: Like - problems

2004-09-22 Thread mos
At 04:17 PM 9/22/2004, you wrote: Hello there, I was wondering how I could make a specific type of search when the string has more than one word. Ex.- String = "Green Apple" Select * from fruits where (fruits.color like '%Green Apple%' or fruits.type li

Re: Like question

2004-09-22 Thread Alec . Cawley
"RuiSMonteiro" <[EMAIL PROTECTED]> wrote on 22/09/2004 09:35:00: > Hello there, > I was wondering how I could make a specific type of search when the > string has more than one word. > Ex.- > String = "Green Apple" > Select * from fruits > where > (frui

Re: LIKE question

2004-08-25 Thread Michael Stassen
V. M. Brasseur wrote: How about... SELECT foo FROM bar WHERE LCASE(this) = "that"; Although there are always other ways to do it, of course. Cheers, --V Schalk Neethling wrote: If I search a field for 'doone' and one of the fields contains 'Lorna Doone' what is the best comparator to use as LIKE

Re: LIKE question

2004-08-25 Thread V. M. Brasseur
How about... SELECT foo FROM bar WHERE LCASE(this) = "that"; Although there are always other ways to do it, of course. Cheers, --V Schalk Neethling wrote: If I search a field for 'doone' and one of the fields contains 'Lorna Doone' what is the best comparator to use as LIKE is skipping this one

RE: LIKE question

2004-08-25 Thread Schalk Neethling
If I search a field for 'doone' and one of the fields contains 'Lorna Doone' what is the best comparator to use as LIKE is skipping this one and I imagine '=' will do the same? -- Kind Regards Schalk Neethling Web Developer.Designer.Programmer.President Volume4.Development.Multimedia.Branding em

RE: LIKE search with different orders

2004-04-10 Thread Matt Chatterley
Hmm. You might be best off using the FIND_IN_SET function (check the manual at mysql.com for more information). In short, if you replace all spaces in your string to search with commas, you should be able to do something like: SELECT * FROM xyz WHERE FIND_IN_SET(test_column, your string here) >

Re: LIKE % not including NULL values?

2004-03-03 Thread Jonas Lindén
Thats true, but the actuall query looked more like this SELECT * FROM testdb WHERE col1 LIKE '$var%' and if I left the $var empty my plan was to get all columns. But I use the "OR col1 IS NULL" trick which solved my problem. Thanks anyway /Jonas If you want all values why not just do SELECT *

Re: LIKE % not including NULL values?

2004-03-03 Thread vpendleton
If you want all values why not just do SELECT * FROM testdb ... The `%` will not match NULL values. >> Original Message << On 3/3/04, 9:41:22 AM, "Jonas Lindén" <[EMAIL PROTECTED]> wrote regarding LIKE % not including NULL values?: > Hello list > SELECT * FROM

Re: LIKE % not including NULL values?

2004-03-03 Thread Egor Egorov
Jonas Lind?n <[EMAIL PROTECTED]> wrote: > SELECT * FROM testdb WHERE col1 LIKE '%' > > The above SELECT statement doesnt return columns with NULL values. Should it? ;). Yes. % matches any number of characters, NULL is not character string. Use IS NULL or IS NOT NULL operators if you want to test

Re: LIKE % not including NULL values?

2004-03-03 Thread Bostjan Skufca (at) domenca.si
seems like gotcha :)) use: SELECT * FROM testdb WHERE col1 LIKE '%' OR col1 IS NULL; On Wednesday 03 of March 2004 16:41, Jonas Lindén wrote: > Hello list > > SELECT * FROM testdb WHERE col1 LIKE '%' > > The above SELECT statement doesnt return columns with NULL values. Should > it? ;). Should I

Re: Like MySQL Dump, but with FoxPro Tables

2003-09-29 Thread Ed Leafe
On Monday, September 29, 2003, at 03:29 PM, Carlos Vazquez wrote: I want to create an application that transfers data from FoxPro (*.dbf) tables to MySQL. Does MySQL have a DUMP like or LOAD LIKE function that transfers this data in one step? I just don't want to loop into thousands of records

Re: Like MySQL Dump, but with FoxPro Tables

2003-09-29 Thread Mojtaba Faridzad
you can export the foxpro table to a text file and import to your mysql table. like this: mysql> SET AUTOCOMMIT=1; # Used for quick re-create of the table mysql> DELETE FROM pet; mysql> LOAD DATA LOCAL INFILE "pet.txt" INTO TABLE pet FIELDS TERMINATED BY ',' ENCLOSED BY '"' LINES TERMINATED

RE: like problem

2002-08-29 Thread Jorge Martinez
gust 29, 2002 2:08 PM Subject: Re: like problem > How about > > select a.name from table1 a, table2 b where a.name like > concat("%",b.name,"%"); > > You might want to read chapter 6.3 in the mysql manual: > http://www.mysql.com/doc/en/Functions.html > >

RE: like problem

2002-08-29 Thread Jorge Martinez
OTECTED]> To: Jorge Martinez <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Thursday, August 29, 2002 1:52 PM Subject: RE: like problem > > > ok try this > select a.name from table1 a, table2 b where a.name like > '%'+ b.name + '%'; > > &

Re: like problem

2002-08-29 Thread Jed Verity
ct a.name from table1 a, table2 b where a.name like > '%'b.name'%'; > > is an error > > > - Original Message - > From: Mary Stickney <[EMAIL PROTECTED]> > To: Jorge Martinez <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> > Sent:

Re: like problem

2002-08-29 Thread Gelu Gogancea
NY Permanent e-mail address : [EMAIL PROTECTED] [EMAIL PROTECTED] - Original Message - From: "Jorge Martinez" <[EMAIL PROTECTED]> To: "Mary Stickney" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Thursday, Augu

RE: like problem

2002-08-29 Thread Mary Stickney
ok try this select a.name from table1 a, table2 b where a.name like '%'+ b.name + '%'; -Original Message- From: Jorge Martinez [mailto:[EMAIL PROTECTED]] Sent: Thursday, August 29, 2002 11:48 AM To: Mary Stickney; [EMAIL PROTECTED] Subject: RE: like problem ye

RE: like problem

2002-08-29 Thread Jorge Martinez
yes, but select a.name from table1 a, table2 b where a.name like '%'b.name'%'; is an error - Original Message - From: Mary Stickney <[EMAIL PROTECTED]> To: Jorge Martinez <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Thursday, August 29,

RE: like problem

2002-08-29 Thread Mary Stickney
that would be because b.name is inside the ' ' and it is taken as a constant. -Original Message- From: Jorge Martinez [mailto:[EMAIL PROTECTED]] Sent: Thursday, August 29, 2002 11:10 AM To: [EMAIL PROTECTED] Subject: like problem i need this consult select a.name from table1 a, table

Re: LIKE work around??

2002-02-13 Thread Cindy
Paul DuBois writes: >At 12:50 -0800 2/7/02, Cindy wrote: >>"Rutledge, Aaron" writes: >> >MySQL doesn't support LIKE does it? I got an error when I tried. >> >>I use it all the time. Maybe post the error message you got. >> >>RLIKE on the other hand > >sigh, what? RLIKE works. I

RE: LIKE work around??

2002-02-13 Thread Rutledge, Aaron
--Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 1:12 PM To: Rutledge, Aaron Cc: Mysql List (E-mail) Subject: Re: LIKE work around?? Work-around? LIKE should work just fine... mysql> select * from fruits where fruit_name like '%banana%

Re: LIKE work around??

2002-02-12 Thread Paul DuBois
At 12:50 -0800 2/7/02, Cindy wrote: >"Rutledge, Aaron" writes: > >MySQL doesn't support LIKE does it? I got an error when I tried. > >I use it all the time. Maybe post the error message you got. > >RLIKE on the other hand sigh, what? RLIKE works. It's the same as REGEXP. > >--Cindy -

RE: LIKE work around??

2002-02-11 Thread Noel Clarkson
You don't want to use LIKE in mysql - or have you not read about LIKE in the fine mysql manual?? If you use LIKE you will also need to use a % sign signify which bit is the variable bit. This is because mysql allows you to say if the variable bit is at the start or the end or both. LIKE 'ban

Re: LIKE work around??

2002-02-11 Thread Mike Wexler
> input is >SELECT dog_name FROM hold_tbl WHERE dog_name RLIKE "^sam[0123456789]*" > ORDER BY dog_name< > > (and then printing out each of the matches made) > Sam > Sam4 > Sam5 > Sammie6 > Sammy7 > Sampson2 > Samson > Samuel > > As I understand it, only the first three should have match

Re: LIKE work around??

2002-02-11 Thread Joshua J . Kugler
Umm, I take it you haven't read the documentation? MySQL fully supports LIKE. Can you tell us the error you are getting? Along with the full query? j- k- On Thursday 07 February 2002 11:11, Rutledge, Aaron wrote: > MySQL doesn't support LIKE does it? I got an error when I tried. --

Re: LIKE work around??

2002-02-11 Thread Cindy
"Rutledge, Aaron" writes: >MySQL doesn't support LIKE does it? I got an error when I tried. I use it all the time. Maybe post the error message you got. RLIKE on the other hand --Cindy - Before posting, please check:

RE: LIKE work around??

2002-02-11 Thread Rutledge, Aaron
MySQL doesn't support LIKE does it? I got an error when I tried. =20 -Original Message- From: Nathan [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 1:04 PM To: Rutledge, Aaron Subject: Re: LIKE work around?? Um... keep using LIKE? Just a thought... :-) - Ori

Re: LIKE work around??

2002-02-11 Thread ju
Work-around? LIKE should work just fine... mysql> select * from fruits where fruit_name like '%banana%'; On Thu, 7 Feb 2002, Rutledge, Aaron wrote: > I am trying to query the database for records that have the same > sequence of starting characters--such as banana1 and banana2 and have a > re

Re: LIKE work around??

2002-02-07 Thread Mike Wexler
> input is >SELECT dog_name FROM hold_tbl WHERE dog_name RLIKE "^sam[0123456789]*" > ORDER BY dog_name< > > (and then printing out each of the matches made) > Sam > Sam4 > Sam5 > Sammie6 > Sammy7 > Sampson2 > Samson > Samuel > > As I understand it, only the first three should have match

Re: LIKE work around??

2002-02-07 Thread Cindy
Paul DuBois writes: >At 12:50 -0800 2/7/02, Cindy wrote: >>"Rutledge, Aaron" writes: >> >MySQL doesn't support LIKE does it? I got an error when I tried. >> >>I use it all the time. Maybe post the error message you got. >> >>RLIKE on the other hand > >sigh, what? RLIKE works. I

Re: LIKE work around??

2002-02-07 Thread Paul DuBois
At 12:50 -0800 2/7/02, Cindy wrote: >"Rutledge, Aaron" writes: > >MySQL doesn't support LIKE does it? I got an error when I tried. > >I use it all the time. Maybe post the error message you got. > >RLIKE on the other hand sigh, what? RLIKE works. It's the same as REGEXP. > >--Cindy -

Re: LIKE work around??

2002-02-07 Thread Cindy
"Rutledge, Aaron" writes: >MySQL doesn't support LIKE does it? I got an error when I tried. I use it all the time. Maybe post the error message you got. RLIKE on the other hand --Cindy - Before posting, please check:

Re: LIKE work around??

2002-02-07 Thread Joshua J . Kugler
Umm, I take it you haven't read the documentation? MySQL fully supports LIKE. Can you tell us the error you are getting? Along with the full query? j- k- On Thursday 07 February 2002 11:11, Rutledge, Aaron wrote: > MySQL doesn't support LIKE does it? I got an error when I tried. --

RE: LIKE work around??

2002-02-07 Thread Rutledge, Aaron
al Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 1:12 PM To: Rutledge, Aaron Cc: Mysql List (E-mail) Subject: Re: LIKE work around?? Work-around? LIKE should work just fine... mysql> select * from fruits where fruit_name like '%banana%

Re: LIKE work around??

2002-02-07 Thread ju
Work-around? LIKE should work just fine... mysql> select * from fruits where fruit_name like '%banana%'; On Thu, 7 Feb 2002, Rutledge, Aaron wrote: > I am trying to query the database for records that have the same > sequence of starting characters--such as banana1 and banana2 and have a > re

RE: LIKE work around??

2002-02-07 Thread Rutledge, Aaron
MySQL doesn't support LIKE does it? I got an error when I tried. -Original Message- From: Nathan [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 1:04 PM To: Rutledge, Aaron Subject: Re: LIKE work around?? Um... keep using LIKE? Just a thought... :-) - Ori

RE: LIKE work around??

2002-02-07 Thread Matthew Walker
SELECT * FROM Table WHERE Fruit LIKE "banana%" Matthew Walker Ecommerce Project Manager Mountain Top Herbs -Original Message- From: Rutledge, Aaron [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 12:56 PM To: Mysql List (E-mail) Subject: LIKE work around?? I am trying to

Re: LIKE work around??

2002-02-07 Thread Christopher Thompson
On Thursday 07 February 2002 12:56 pm, Rutledge, Aaron wrote: > I am trying to query the database for records that have the same > sequence of starting characters--such as banana1 and banana2 and have a > result set returned that contains everything that starts with banana. > Any way to do this?

Re: Like and '\\'

2002-01-18 Thread Paul DuBois
At 14:20 -0800 1/18/02, Stuart Scamman wrote: >What is the syntax to make '\\' work with like statement ? That depends on what you're trying to match. Please specify. > >This example is always empty: > >SELECT * from table where field LIKE '%\\mydir\\myfile%' -

Re: Like and '\\'

2002-01-18 Thread Mike Gleason Jr Couturier
'\' is an escape character... so to escape it you must : SELECT * from table where field LIKE '%mydirmyfile%' Mike - Original Message - From: "Stuart Scamman" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, January 18, 2002 5:20 PM Subject: Like and '\\' > What is t

Re: LIKE Magic

2001-07-05 Thread Paul DuBois
> > Dibo Chen == [EMAIL PROTECTED] napisa?(a): > >> You must have 8001 - 1 - 2788 NULLs for kword_10. Please confirm it. > >Yes it's true! But why NOT LIKE gives false for NULL values? NULL values fail all comparisons except IS NULL. >How can I get rid of this NULL's? >Is "update docs set

Re: LIKE Magic

2001-07-05 Thread Jakub Wasielewski
> Dibo Chen == [EMAIL PROTECTED] napisał(a): > You must have 8001 - 1 - 2788 NULLs for kword_10. Please confirm it. Yes it's true! But why NOT LIKE gives false for NULL values? How can I get rid of this NULL's? Is "update docs set kword_10 = '' where kword_10 IS NULL" enough? Cheers, I love

Re: LIKE Magic

2001-07-05 Thread Dibo Chen
You must have 8001 - 1 - 2788 NULLs for kword_10. Please confirm it. Jakub Wasielewski wrote: > > Hello! > > Could somebody explain me why it's like that: > > mysql> select count(*) from docs where kword_10 LIKE '%Ukraina%'; > +--+ > | count(*) | > +--+ > |1 | > +-

Re: LIKE

2001-07-02 Thread Paul DuBois
>Hi Everyone, > >Does this make sense: >select * from table_name where column_1 LIKE "%word1% OR %word2%"; That should be: column_1 LIKE "%word1%" OR column_1 LIKE "%word2%" > >yeilds 1 record but... > >select * from table_name where column_1 LIKE "%word2% OR %word1%"; > >yields 0 records. > >

Re: LIKE

2001-07-02 Thread David Robley
On Tue, 3 Jul 2001 09:44, Eric Fegraus wrote: > Hi Everyone, > > Does this make sense: > select * from table_name where column_1 LIKE "%word1% OR %word2%"; > > yeilds 1 record but... > > select * from table_name where column_1 LIKE "%word2% OR %word1%"; > > yields 0 records. > > I'm scanning a VA

Re: like

2001-06-09 Thread Benjamin Pflugmann
Hello Antonio. On Fri, Jun 08, 2001 at 11:50:25PM -0700, [EMAIL PROTECTED] wrote: [...] > select * from [table] where ([string] like %[keyword]$) SELECT * FROM table1 WHERE ("helloworld" like CONCAT("%",keyword,"%") should work, IMHO. Another possibility is to use string functions like this:

Re: LIKE clause in DELETE-Statement

2001-04-25 Thread Siomara Pantarotto
Dear all, Does anyone know how I can run a script that calls other scripts in order to create the DB and its tables? How do I do it from my Windows NT? Thanks >From: "Sascha Dahl" <[EMAIL PROTECTED]> >To: <[EMAIL PROTECTED]> >Subject: LIKE clause in DELETE-Statement >Date: Wed, 25 Apr 2001 1