AD0-E716 · Question #3
An Adobe Commerce developer is working on a module to manage custom brand entities and wants to replicate the following SQL query using SearchCriteria: A) B) C)
The correct answer is B. Option B. The following SearchCriteria query will replicate the SQL query: $searchCriteria = new \Magento\Framework\Api\SearchCriteriaBuilder(); $searchCriteria->addFilter('name', 'Brand 1', 'eq'); $searchCriteria->addFilter('status', 1, 'eq'); $brandCollection =…
Question
An Adobe Commerce developer is working on a module to manage custom brand entities and wants to replicate the following SQL query using SearchCriteria:
A) B) C)
Exhibit
Options
- AOption A
- BOption B
- COption C
How the community answered
(39 responses)- A8% (3)
- B77% (30)
- C15% (6)
Explanation
The following SearchCriteria query will replicate the SQL query: $searchCriteria = new \Magento\Framework\Api\SearchCriteriaBuilder(); $searchCriteria->addFilter('name', 'Brand 1', 'eq'); $searchCriteria->addFilter('status', 1, 'eq'); $brandCollection = $this->brandRepository->getList($searchCriteria);
Topics
Community Discussion
No community discussion yet for this question.
