RE: [PHP] Truncation?

From: Date: Thu, 09 Nov 2000 14:25:15 +0000
Subject: RE: [PHP] Truncation?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-24495@lists.php.net to get a copy of this message
You can use the LIKE keyword in your select statement. For example, if your field name was article_num: SELECT * (or whatever you want to select FROM mytable WHERE article_num LIKE 'f%' This will give you all records from your table where the article_num starts with f. You can do similarly for other fields/values as well. HTH Sam Masiello System Analyst Chek.Com (716) 853-1362 x289 smasiello@chekinc.com -----Original Message----- From: Daniel Alsén [mailto:daniel@innehallsbolaget.com] Sent: Thursday, November 09, 2000 5:14 AM To: PHP Subject: [PHP] Truncation? Hi! Can i truncate SELECT from MySQL? I have a table with a field for article numbers. They are categorized with the first character. I need to be able to call up a category of articles from that (ie x* or f* (where the actual article numbers look like x003 or f674)). ## Daniel Alsén | http://www.eyebee.com # ## Innehållsbolaget | ICQ: 63006462 # ## daniel@eyebee.com | Fax: +46 8 4100 1650 # ## +46 8 4100 1605 | Mob: +46 709 93 57 05 # -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#24495) next »