MySQL Lists are EOL. Please join:

List:General Discussion« Previous MessageNext Message »
From:David McInnis Date:February 13 2002 3:59pm
Subject:RE: ignoring in ORDER
View as plain text  
You may be able to sort using a regex expression.


-----Original Message-----
From: DL Neil [mailto:PHPml@stripped] 
Sent: Wednesday, February 13, 2002 1:39 AM
To: 'abdul - ÚÈÏ ÇáÑÍãä'
<ababab90@stripped; mysql@stripped>
Subject: Re: ignoring in ORDER

Hi Abdul,

Can Mysql  ignore alphabet , like  'the'  when
ORDERING a name.

A sample :

I have a table (first_name) :

- The test.
- Falcon
- The Armageddon
- Battle

When ordering it will be :

The Armageddon
The test.

Can it be like this :

The Armageddon
The test.

Is that possible?

=Anything is possible!

=This is a common 'problem' in the library world where in the context of
titles 'the', 'a', 'al' are considered
'noise-words'. Some of the 'library' scripts available on the various
support/tutorial sites may offer

=Here are three choices:
1 regimentation: insist that all title data entered, is expressed in a
sequence-friendly fashion, eg
"Armageddon, The";
2 smart data: have two title fields in your db. One which is the title
straight off the cover. The other which
is a 'sequencing field' - sometimes with noise words removed/words
re-ordered, sometimes exactly the same. Users
should be presented with the former, but the RDBMS is programmed to
use/sequence using the latter;
3 smart queries: (this is more of a challenge) look up IF() [6.3
Functions for Use in SELECT and WHERE Clauses]
and rewrite the query so that if the title commences with a noise word
miss it out of the sort process, eg if
the left three characters are "the" sequence using only the
"Arrmageddon" part.


Before posting, please check:   (the manual)           (the list archive)

To request this thread, e-mail <mysql-thread99828@stripped>
To unsubscribe, e-mail
Trouble unsubscribing? Try:

ignoring in ORDERabdul - "ÚÈÏ" "ÇáÑÍãä12 Feb
RE: ignoring in ORDERRick Emery12 Feb
  • Re: ignoring in ORDERDL Neil13 Feb
    • RE: ignoring in ORDERDavid McInnis13 Feb