AbanteCart Community
AbanteCart Development => API Development => Topic started by: huyhoang08 on March 17, 2016, 01:46:05 AM
-
i see dataset API:
$db=new ADataset('name','key');
//compare single field
$db->deleteRows(array('column_name' => 'field1', 'operator' => '=', 'value' => $value));
So i want to combine 2 fields with AND/OR relation. how to do this?
-
please help me?
-
i see dataset API:
$db=new ADataset('name','key');
//compare single field
$db->deleteRows(array('column_name' => 'field1', 'operator' => '=', 'value' => $value));
So i want to combine 2 fields with AND/OR relation. how to do this?
please clarify.
What operation do you mean under "to combine 2 fields with AND/OR" ? deleting?
-
for example, i can use this:
$db=new ADataset('name','key');
//compare single field
$db->deleteRows(array(
array('column_name' => 'field1', 'operator' => '=', 'value' => $value1),
array('column_name' => 'field2', 'operator' => '=', 'value' => $value2), # AND relationship
));
I can do this?
-
hmm.. no..
you can delete only one row of dataset with this method.
i think we have method name that confuses developers..