Title: insert into term_relationships
Last modified: August 20, 2016

---

# insert into term_relationships

 *  [jmastrom](https://wordpress.org/support/users/jmastrom/)
 * (@jmastrom)
 * [14 years, 6 months ago](https://wordpress.org/support/topic/insert-into-term_relationships/)
 * How do I do this:
    ` $term_values=array(3,4,16,17); foreach($term_values as $
   _in){ $sql=”INSERT INTO “.$is_test.”wp_term_relationships (object_id, term_taxonomy_id)
   VALUES($db_row, $_in)”; $r_=mysql_query($sql); } Using WordPress function?

The topic ‘insert into term_relationships’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [jmastrom](https://wordpress.org/support/users/jmastrom/)
 * Last activity: [14 years, 6 months ago](https://wordpress.org/support/topic/insert-into-term_relationships/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
