[wp-trac] [WordPress Trac] #5240: taxonomy - incorrect query in
update or insert term to increase term_group
WordPress Trac
wp-trac at lists.automattic.com
Sun Oct 21 10:18:03 GMT 2007
#5240: taxonomy - incorrect query in update or insert term to increase term_group
----------------------------+-----------------------------------------------
Reporter: michelwp | Owner: anonymous
Type: defect | Status: new
Priority: high | Milestone: 2.4
Component: Administration | Version: 2.3
Severity: major | Keywords: taxonomy term slug term_group alias_of needs-patch
----------------------------+-----------------------------------------------
In both functions (wp_insert_term and wp_update_term, the SQL query - ''to
increase the term_group when creating an alias of a term not yet in a
term_group'' - is incorrect.
The query was
{{{
SELECT MAX(term_group) FROM $wpdb->terms GROUP BY term_group
}}}
but must be
{{{
SELECT MAX(term_group) FROM $wpdb->terms
}}}
'''GROUP BY''' is not here necessary !
(I am testing taxonomy.php script and features to create a multilingual
dictionary of terms that can be used in themes or elsewhere)
About '''alias_of''' features : See also Trac #5230
--
Ticket URL: <http://trac.wordpress.org/ticket/5240>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list