#9435 closed enhancement (fixed)
DB schema clean-ups
Reported by: | Denis-de-Bernardy | Owned by: | |
---|---|---|---|
Milestone: | 2.8 | Priority: | normal |
Severity: | minor | Version: | 2.8 |
Component: | Optimization | Keywords: | has-patch |
Focuses: | Cc: |
Description
While looking into #9422, it occurred to me that some DB fields weren't necessarily used today. Namely:
links.link_category int(20) seems to be overridden by the terms schema.
The same goes for posts.post_category int(4).
It might be that they've been left around for obsolete plugins, though. In case this isn't the case, the attached patch, for 2.8 trunk, will remove them.
Attachments (6)
Change History (18)
@
15 years ago
use int(11) rather than bigint(20) unsigned, for smaller indexes (and thus faster queries)
@
15 years ago
more relevant text fields: text is 65kb, mediumtext is 16MB, longtext is 4GB - an rss field stored in wp_options is only rarely larger than 65kb, and no post would ever be larger than 16MB
@
15 years ago
the same patch, keeping comment_author and post_title as text fields in case this was needed for any reason
@
15 years ago
drop user_status field -- see http://comox.textdrive.com/pipermail/wp-hackers/2009-January/023550.html
#3
@
15 years ago
Is this correct?
By dropping post_category and link_category, new installs will not see those columns, but upgraded databases will still have the two columns.
#6
@
15 years ago
- Keywords dev-feedback added; needs-testing removed
I take it the other ones are not to be used? close as fixed, or move to 2.9 for the text/varchar/int cleanups?
#10
@
12 years ago
- Milestone changed from Future Release to 2.8
- Resolution set to fixed
- Status changed from new to closed
Marking as needs-testing, in case their absence has any impact I've missed by scanning the source code.