| PHP/MySQL Tutorial - PHP MySQL Connection |
How to Select Individual RecordsStep 5: As well as showing the whole Database, PHP can be used to select individual records, or records which match certain criteria. To do this you must use a variation of the SELECT query. To display the whole table you used the query: SELECT * FROM tablename If we just want to select records which have value=1 in the field1-name row we would use the following query: SELECT * FROM tablename WHERE field1-name='1' In the same way you could select records based on any field in the database. You can also search in more fields by adding more: field='value' sections into the query. For further reference you can visit the official websites of PHP and MySQL. One of the most important things about using PHP and MySQL is to have a PHP/MySQL specialized Host. Here are some of the things we at SiteGround are proud of:
Our PHP hosting package is the best offer on the market - it has the lowest price for the quality and features it includes. Sign up now for our Professional PHP Hosting! |
| < Prev | Next > |
|---|




