DB Index Error
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
-
- Posts: 40
- Joined: 12 Jul 2018, 19:57
DB Index Error
I'm seeding some data in mshop_product_property table and some values are very long and I'm getting this error Program limit exceeded: 7 ERROR: index row requires 13632 bytes, maximum size is 8191
My questions are ?
1. Can I drop the index ?
2. What happens if I drop it ?
3. Is there a way to fix that ?
Thanks
My questions are ?
1. Can I drop the index ?
2. What happens if I drop it ?
3. Is there a way to fix that ?
Thanks
--
Jorge A Ramirez
System Engineer
PHP Developer
Jorge A Ramirez
System Engineer
PHP Developer
Re: DB Index Error
Product properties are not meant for large amounts of data (usually not more than a few bytes). If you need to store long texts, please use the mshop_text table. If you delete the index, performance will drop severely.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
-
- Posts: 40
- Joined: 12 Jul 2018, 19:57
Re: DB Index Error
I did it as you said in the mshop_text_table, but i got the same error about index, this is a part of the error:aimeos wrote:Product properties are not meant for large amounts of data (usually not more than a few bytes). If you need to store long texts, please use the mshop_text table. If you delete the index, performance will drop severely.
Code: Select all
SQLSTATE[54000]: Program limit exceeded: 7 ERROR: index row requires 16488 bytes, maximum size is 8191 (SQL: insert into "mshop_text" ("siteid", "typeid", "label", "content", "langid", "domain", "status", "mtime", "ctime", "editor") values (1, 44, Tab one content, <p class="TOCtitle">Chapter 1<br /> Introduction to the Public Domain</p>
<p class="TOCheading1">What Is the Public Domainen................................................................................. 4</p>
<p class="TOCheading2">Copyright and the Public Domain................................................................ 4</p>
<p class="TOCheading2">What Is in the Public Domainproduct...................................................................... 5</p>
<p class="TOCheading2">How Can You Use the Public Domain1....................................................... 5</p>
<p class="TOCheading2">Why Have a Public Domain2018-09-17 09:37:51.......................................................................... 6</p>
<p class="TOCheading2">How Do You Know If a Work Is in the Public Domain2018-09-17 09:37:51........................ 9</p>
<p class="TOCheading2">How Do You Find Public Domain Materials......................................... 10</p>
<p class="TOCheading2">Are Public Domain Works Always Free?................................................ 10</p>
<p class="TOCheading1">Dealing With Public Domain Gray Areas...................................................... 11</p>
<p class="TOCheading2">What Is the Likelihood of Discovery?....................................................... 12</p>
<p class="TOCheading2">How Valuable Is the Material?................................................................... 13</p>
<p class="TOCheading1">What If Someone Challenges Your Public Domain Claim?..................... 14</p>
<p class="TOCheading2">Handling the Claim Yourself....................................................................... 14</p>
<p class="TOCheading2">Hiring a Lawyer............................................................................................... 15</p>
<p class="TOCheading1">Documenting Your Use of Public Domain Materials................................. 15</p>
Any idea to help me?
Thanks
--
Jorge A Ramirez
System Engineer
PHP Developer
Jorge A Ramirez
System Engineer
PHP Developer
Re: DB Index Error
There's no index on the content so the problem might be (contrary to the error message) that column is simply not long enough. The default size is 64kb. Does your text you want to insert has more than that?
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
-
- Posts: 40
- Joined: 12 Jul 2018, 19:57
Re: DB Index Error
Yes, content could have more than 64kb,hiw can I change that size?
Thanks
Thanks
--
Jorge A Ramirez
System Engineer
PHP Developer
Jorge A Ramirez
System Engineer
PHP Developer
Re: DB Index Error
This commit in dev-master might fix the problem:
https://github.com/aimeos/aimeos-core/c ... 29a34fb60d
Can you check? Beware: Doctrine doesn't seem to update the size of text columns if they already exist!
https://github.com/aimeos/aimeos-core/c ... 29a34fb60d
Can you check? Beware: Doctrine doesn't seem to update the size of text columns if they already exist!
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
-
- Posts: 40
- Joined: 12 Jul 2018, 19:57
Re: DB Index Error
Your commit doesn't work, also you said that there isn't index with content, but there is a compound index named idx_mstex_sid_dom_cont https://ibb.co/iO0juz that index is getting the error I mentioned you.aimeos wrote:There's no index on the content so the problem might be (contrary to the error message) that column is simply not long enough. The default size is 64kb. Does your text you want to insert has more than that?
Thanks
--
Jorge A Ramirez
System Engineer
PHP Developer
Jorge A Ramirez
System Engineer
PHP Developer
-
- Posts: 40
- Joined: 12 Jul 2018, 19:57
Re: DB Index Error
Yes, there's actually an index and did you try to remove that index and add it again using this statement?
Code: Select all
CREATE INDEX "idx_mstex_sid_dom_cont" ON "mshop_text" ("siteid", "domain", left("content", 255) );
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star