[nycphp-talk] Re: [front-end] Querying a DB for Items with Names that Start withaNumber
harvey
list at harveyk.com
Fri Mar 26 11:52:35 EST 2004
hi and thanks. i tried the below, but for some reason it didn't work. no
errors, but it didn't find any items. i used the following that someone else
recommended and it worked fine:
SELECT * FROM data WHERE LEFT(NAME, 1) REGEXP "[0-9]";
----- Original Message -----
From: "Robert Mullaney" <robert at simp-tech.com>
To: "NYPHP SIG: Front End" <front-end at lists.nyphp.org>
Sent: Friday, March 26, 2004 11:03 AM
Subject: RE: [front-end] Querying a DB for Items with Names that Start
withaNumber
> SELECT * FROM `data` WHERE `name` LIKE '[0-9]%'
>
> Hope it helps :)
>
> -----Original Message-----
> From: front-end-bounces at lists.nyphp.org
> [mailto:front-end-bounces at lists.nyphp.org]On Behalf Of harvey
> Sent: Friday, March 26, 2004 10:02 AM
> To: NYPHP SIG: Front End
> Subject: [front-end] Querying a DB for Items with Names that Start with
> aNumber
>
>
> hello,
> i would like to query a database and select only those records where the
> name field starts with a numeric character. how can i do something like
the
> following? thanks in advance...
> harvey
>
> SELECT * FROM data WHERE is_numeric(name{0})
>
>
> _______________________________________________
> front-end mailing list
> front-end at lists.nyphp.org
> http://lists.nyphp.org/mailman/listinfo/front-end
>
>
> _______________________________________________
> front-end mailing list
> front-end at lists.nyphp.org
> http://lists.nyphp.org/mailman/listinfo/front-end
>
More information about the talk
mailing list