Hi,
I use this code for delete a rows in a table but no result :s
someone help me ^^
I use this code for delete a rows in a table but no result :s
<?php
jimport( 'joomla.database.table' );
$db =& JFactory::getDBO();
$table = $db->getTable('MyTable');
$table->delete($id);
?>
someone help me ^^
Hi yuki,
Do you want to delete the whole table or just selected records from the table?
To delete selected records it would be
Bob
Do you want to delete the whole table or just selected records from the table?
To delete selected records it would be
<?php
$db =& JFactory::getDBO();
$query = "
DELETE
FROM `#__some_table`
WHERE `column_name` = 'value' ;
";
$db->setQuery($query);
$db->query();
?>
Bob
This topic is locked and no more replies can be posted.