Re: Delete a record
| From: | Michael Sims | Date: | Sat, 14 Sep 2002 00:31:52 +0000 |
| Subject: | Re: Delete a record | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-116334@lists.php.net to get a copy of this message | ||
On Fri, 13 Sep 2002 19:44:52 -0400, you wrote:
>You missing an element in your statement. Are you deleting on cell in
>that table row? Or are you deleting the whole row? It should look like
>
>$query = "DELETE * FROM logiciellg WHERE LOGICIEL_ID=$ID"; // If you
>want to delete the entire row
>
>$query = "DELETE cell_name FROM logiciellg WHERE LOGICIEL_ID=$ID"; //
>If you want to delete just one part of the row
[...]
Which RDBMS are you using that allows you to delete specific FIELDS
from a row? How would such a thing even be possible?
MySQL allows you to issue a query of the form:
delete a, b from a, b, c where <join condition>
But a and b in this case are TABLE names, not field names. In MySQL
it is not possible to delete specific fields, you may only delete the
entire row. The normal syntax of a delete command is
delete from tablename where <condition>