Re: RE: SELECT WHERE length of content question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Do not forget to use TRIM function as well:


in order to elliminate leading and trailing spaces.


----- Original Message ----- From: "Geoffrey Pitman" <geoffrey.pitman@xxxxxxxxx>
To: <php-db@xxxxxxxxxxxxx>
Sent: Friday, March 11, 2011 7:59 PM
Subject:  RE: SELECT WHERE length of content question

You should be able to use the MySQL command LENGTH() command. I'm assuming
that your fax field is a varchar or char(10) field. If it's a number (which
it probably shouldn't be), I suppose you could write a query to find values
equal to or greater than 100,000,000,000.

I hope this helps.


---------- Forwarded message ----------
From: "Ron Piggott" <ron.piggott@xxxxxxxxxxxxxxxxxx>
To: <php-db@xxxxxxxxxxxxx>
Date: Wed, 9 Mar 2011 17:49:42 -0500
Subject: SELECT WHERE length of content question

Is there a command in mySQL that would allow me to SELECT the rows where the
`fax` column is more than 11 characters long?


Do I need to use PHP to assess this?


The Verse of the Day
“Encouragement from God’s Word” <>

PHP Database Mailing List (
To unsubscribe, visit:

[PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Plagiarism Notes]     [Postgresql]     [Yosemite News]

Powered by Linux