Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+2 votes
592 views
in Q2A Core by
edited by
Q2A version: 1.7.0

1 Answer

+2 votes
by
selected by
 
Best answer

All the metadata access functions can be found in db/metas.php. If you take a look at the core's code, you'll find out that those functions are rarely used. "Metadata" means "data about data". In this case, the name might not be quite accurate as the core uses the metadata as "extra data".

This means the core allows the user to store additional data about some entities, e.g., posts or users. By "additional" I mean data that is not already present in the ^posts table, for example. This is useful to plugin developers. In some scenarios you might need to store data abouta user and, instead of creating a new table to hold it, you could use the metadata table for users.

The good thing about following that approach is that you don't need to create the table and you don't need an data access functions (because they're already implemented). The downside about using those functions and tables is performance as they follow an Entity Attribute Value model.

In most cases I would advise against these tables and recommend creating your own, with the appropriate data structure, normalization and indexes. However, for developers who don't know much about data modelling, SQL, indexes, etc., then they might be the best way to go.

...