Questions tagged [database]

Questions related to Magento's MySQL database, for example, the table schema, plain SQL queries or database configuration. For questions about the Magento database access layer, use other tags, like: eav, model, resource-model, collections, install-script. For questions about SQL queries in particular, the SQL tag is appropriate too.

This tag is for questions about the MySQL database of Magento under the abstraction layer. For example, the table schema or usage of plain SQL queries.

For questions about SQL queries in particular, is appropriate too.

For questions about using the database access layer in Magento code, see:

For questions about infrastructure regarding the database, see

3275 questions
15
votes
5 answers

Convert a production database into test data

The closer a test is to production, the better it can emulate production behavior. I would like to copy the database backups from production into our test environments, but what do I need to change so that test works, and to keep from interfering…
kojiro
  • 1,048
  • 12
  • 22
8
votes
2 answers

Is there still a use case for database table prefix in Magento?

I remember the Prefix once was incented, because a lot of hosters only supported one Database per users, so many applications needed to share one database and it could come to conflicts. Also the prefix enabled you to install more then one magento…
Flyingmana
  • 6,127
  • 3
  • 27
  • 64
8
votes
1 answer

Where does Magento save store view specific product description / short description

I have located the value for short description for the default store store (catalog_product_entity_text.value) but I can't find my modified 'store view' version. Could somebody let me know the exact table please.
Ste
  • 323
  • 1
  • 4
  • 11
6
votes
1 answer

Should I update old magento local.xml?

I am comparing my old local.xml file with a new one (both run same version but one store was upgraded since 2010) and my old one is missing some attributes, should I add them? Is there any advantage by doing so?
Vygantas
  • 373
  • 3
  • 11
4
votes
4 answers

Reduce DB file size

I'm trying to copy my live store to a different test server Due to limit space on my test server, I need to reduce my DB file size when import DB I got 2.5 GB DB file when I dump on live store and hope I can get less than 1 GB DB file Which table…
Yohan
  • 1,610
  • 7
  • 33
  • 51
3
votes
1 answer

How to setup Magento 1.x (or 2.0) run with Oracle Database (instead of MySql)

As title, i want to setup Magento 1.x (or 2.0) run with Oracle Database (instead of MySql). It possible?
andy
  • 33
  • 2
3
votes
1 answer

Set Mysql variable in magento

I want to fire select query which is as follows SET @a = 0; SELECT @a:=@a+1 as count FROM admin_user; How I can add SET variable in SQL query in magento.
YKJ
  • 387
  • 7
  • 16
3
votes
1 answer

What is catalog_product_link_attribute_int used for in Magento v1.9?

The table catalog_product_link_attribute_int is huge in a couple of stores I have built. A store with 1600 products has this table at 771MiB in which is over 10x the size of the next largest table. It makes the store awkward to backup or migrate…
3
votes
4 answers

What is core_file_storage table in Magento?

I have core_file_storage table in Magento with very huge size. What is it's functionality? Can I remove and replace functionality? Is it affects to the speed of my database? Thanks.
mageUz
  • 6,234
  • 3
  • 29
  • 52
2
votes
2 answers

Magento remove table prefix

We want to delete/remove the Magento table prefix. How can this be done? Is there a script available to do this in one-go? Essentialy changing the table myprefix_catalog_category to catalog_category We have had the prefix since 1.3 - but it is…
snh_nl
  • 5,442
  • 13
  • 69
  • 133
2
votes
2 answers

How do I lock a row after using load()?

Let's say I do the following: $favorite = Mage::getModel('testing/favorites')->load(4); ..... $favorite->save(); How do I make sure the row 4 has been locked and can't be accessed until I call save()? Edit: Essentially, I have one table with a…
Pat
  • 794
  • 1
  • 13
  • 30
2
votes
2 answers

How to find the product url in Magento Database

How to find Product URL in Magento database and how assign given URL for add to cart. please guide me.
Mild Milly
  • 103
  • 1
  • 10
2
votes
2 answers

Access denied for user 'root'@'localhost'

i got this error: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) How can i fix the database with the correct password
user21067
  • 31
  • 1
  • 1
  • 2
2
votes
2 answers

Get Image url from database

How to get image from database and display it in magento? my imgs.php is: $a = $_SESSION['id']; $ob = Mage::getModel('management/file')->getCollection(); $res = $ob->addFieldToFilter('task_id',$a); // $res =…
Mahi
  • 23
  • 1
  • 5
2
votes
3 answers

What are reasons for a Magento database become huge?

I am not sure if I am allowed to ask this here but I have a curiosity. Is it normal that a Magento with 800 orders to have 600mb? Also there are only 20 products (12 configurable, 3 bundles)
Denisa
  • 508
  • 1
  • 10
  • 26
1
2 3 4 5 6