Showing posts with label query. Show all posts
Showing posts with label query. Show all posts

6 Nov 2013

Magento: Using Or And And Query Condition To Collection

Please check the below details how we can use AND and OR query condition in magento collection.
Product collection :



2 Nov 2013

Magento: Use Mysql Functions With Addexpressionattributetoselect

Function addExpressionAttributeToSelect as defined in Mage_Eav_Model_Entity_Collection_Abstract (/app/code/core/Mage/Eav/Model/Entity/Collection/Abstract.php) allows us to use MySQL functions in Magento collection. Here is an example of using MYSQL IN() clause in magenot more product collection at once :

1 Nov 2013

Magento: How To Get List Of All Modules Programmatically?

One of the most great advantages of magento is it supports various of modules to install for a different type of work.Also it has default modules,So for knowing how many modules installed in magento and to check whether that is active or not please follow below details:

31 Oct 2013

Magento: How To Select, Insert, Update, And Delete Data?

Suppose, I have a database table named ‘test‘ with the following fields:-
id : int, auto increment, primary key
title : varchar
content : text
status : 1
Suppose, I have a module named ‘mytest‘. Here follows the code to select, insert, update, and delete data from the ‘test‘ table.