Exponential growth of the slots table

John Ralls jralls at ceridwen.us
Fri Dec 3 23:48:32 EST 2010


On Dec 3, 2010, at 7:23 PM, Elwood Hunt wrote:

> Hi,
> 
> I am using version 2.3.16 with MySQL as the database.  For backups, I will
> often use MySQL Administrator to export the entire schema to an SQL DDL
> file.  I recently noticed that the size of my backup file grew from ~ 800K
> to  ~ 2.8MB after adding a budget for one month (I have maybe 25 expense
> accounts).  I also noticed that it was the slots table that grew so much
> (several thousand additional rows).  Is this normal or did something go
> wrong?
> 

Maybe both.

Nested slots weren't supported until 2.3.16 -- and it's something depended upon by several features, including budgeting and  account mapping for imported transactions. The slots architecture doesn't map very well into the relational model, so it's not very efficient in terms of either space or performance. (More like it's very inefficient.) 

It's also possible that slots are being duplicated when they're written out. If you're able, find a slot name and then query in the mysql shell to see if there are duplicates.

Regards,
John Ralls



More information about the gnucash-user mailing list