Why are the custom fields created in the database so memory-heavy?

stefanstp

Member
I'm switch from vBulletin 3.8 to XenForo and wonder why the custom fields (xf_user_field_value) are not created in the database as in vBulletin:

UserID field1 field2
1(userid) 12345(icq) 67890(msn)
2(userid) 346676(icq) 7466046(msn)

but in xenforo:
user_id field_id field_value
1 icq 12345
1 msn 67890
2 icq 346676
2 msn 7466046
etc.

In my more than 300,000 members, the extremely occupied memory is noticeable. In vBulletin approximately 27 MB required XenForo need for the same data after importing about 130 MB (in phpmyadmin by only 7 fields per user and not 20 as in vbulletin). Is the reason the Compact-Format? What the benefits? Sorry for my bad english :cry:.

xen.webp ).

What is the reason?
 
It's a fundamental shift in DB design. IIRC, vBulletin serialized every friend into a single record. XenForo only stores the data that's needed.
 
Yes, but with the custom fields are created in the database even lines (without content), even though the member has not completed all profile fields. Since it would have been more practical to apply only the elements in the database that were actually completed, or I got this wrong?

ubuntu5.webp
 
Technically, an empty value can be construed differently than the lack of a value (the lack of a value indicating that they have never attempted to set a value for the field).
 
Where exactly is the advantage, just so I can better understand? A few of my external scripts based on the custom fields that I need to reprogram it. So I wonder, that the storage of the data is done very differently here, although I have to save as in vBulletin felt quite practical. Is the mysql query faster?
 
You are now able to query an individual field, rather than fetching the full amount of fields.
 
Top Bottom