My choice would be using Pods : https://pods.io/docs/learn/what-are-advanced-content-types/
Non-programmer here... I've layered some pretty complex functionality on top of Wordpress using Toolset: https://wp-types.com/ -- the Views component was especially helpful in allowing me to embed custom functionality on Pages that I could style using CSS and the data short codes generated by the plugin.
I used toolset for a couple of years, now I build anything into plugins or themes using OOP, it makes life easier :-). Currently I am building a full forum system based on the WP Query and Post objects, progressing well, Should be a fast platform as never found bbpress or buddypress much use together so the custom database stores all forum records changed by a forum_type key with forum, topic, replies and I expect Ill add more on next version. I digress lol, your guide to custom tables, one of the best i've found so far so great work buddy :-)
Charles - curious about your approach. I too need to build a forum system, also supporting resources that are shared on the forum. How do you deal with putting your forum data on pages/posts, or do you just have your own custom UI instead of pages/posts?
We store volunteer applications, which have a structure of selectors, check boxes, text lines, and full text fields. The volunteer can retrieve and edit their application. Our admin can search for volunteers. So I have always used several custom tables. Which seems agreeable with your criteria! At the time I set this up, about 10 years ago, Wordpress did not offer much help to integrate an independent table update & retrieve. It seemed like no one in the community had any advice at all. So I used custom php Pages at that time. These pages worked unaltered through the last 8 years of WP releases, so can't have been all bad! I just went through an update and converted all my application DB update & retrieve functionality to Wordpress plugins. Feels a bit cleaner. I would still say there is not much advice about how to integrate such access to an independent DB! I should add that we have about 5000 volunteers with logins on our site.
10 years ago was long before custom post types were introduced so I suppose it was an easy choice to make at the time. Sounds like it's still working well for you, which is impressive after so long. Glad to hear you found the article useful!
pods (a CPT plugin) has it roots in times as CPT didn't exist so it still has a feature called ACT (advanced content types) where the data is stored in separat tables - and it offers the option to store WordPress Meta Data in a separate Table per CPT maybe worth a look - oh and it's open source sponsored by automattic and others ( https://friends.pods.io )
well maybe not as a plugin but as a package ... you can export/import configurations not very friendly right now but pods it open source - contributions welcome ^^
Is it a good solution if we at https://www.browsercam.com query the database directly without involving PHP and wordpress dev to create new/custom table? As we can also do this with SQL alone
Hi Evan Mattson, Thank you very much for post about create custom table wordpress. I think, this post is the best helpful for new wordpress developer. I see your full post. Custom create tale wp full fill example. Thanks Stein & Partners https://www.steinandpartners.com
Is there a guide on how to create a relationship between two (2) custom tables? i.e. Quiz and Question with many-to-many relationship between them? In SQL normalised way it would be a junction table.
Thank you for giving writing this article this really clear my mind since i was googling ways to understand how WordPress DB works. i would like to ask follow up question, how does WordPress handle the delete table ? for example when plugin is deleted from the admin dashboard. all its component will be deleted including the table created , and every time the plugin is activated and deactivated will the function create table overlapped the existing table? sorry for having a lot of question i'm new to WordPress. thanks
Is it a good solution for apk download https://www.theapksfree.com