Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6203475
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T04:55:25+00:00 2026-05-24T04:55:25+00:00

Basically we wanted to move a portion of our drupal 6 site to our

  • 0

Basically we wanted to move a portion of our drupal 6 site to our drupal 7 build. Using the migrate module. While migrating 155 nodes with their comments and taxonomy(2 vocabs, one is fixed the other is comma seperated) the last 30 fail giving me this error:

291 Error PDOException: SQLSTATE[HY000]: General error: 1366 Incorrect integer value: '' for column 'tid' at row 1: INSERT INTO {taxonomy_index} (nid, tid, sticky, created) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3); Array ( [:db_insert_placeholder_0] => 3057 [:db_insert_placeholder_1] => [:db_insert_placeholder_2] => 0 [:db_insert_placeholder_3] => 1282050381 ) in taxonomy_field_insert() (line 1675 of /u01/facebase/drupal-7.0/modules/taxonomy/taxonomy.module).

291 Error SQLSTATE[HY000]: General error: 1366 Incorrect integer value: ” for column ‘tid’ at row 1

I’m migrating my terms using this query:

$query = db_select("$this->_db.term_data", 'td')
  ->fields('td', array('tid', 'name', 'weight'))
  ->condition('v.vid', 7);
  $query->innerJoin("$this->_db.vocabulary", 'v', 'td.vid=v.vid');

I do this for 2 vocabularies, and then I map just the name, format, and weight. Then i’m using this query while migrating the nodes:

$query = db_select("$this->_db.node", 'n')
  ->fields('n', array('nid', 'vid', 'type', 'title', 'uid', 'status', 'created', 'changed', 'comment'))
  ->fields('tn', array('tid'))
  ->fields('nr', array('title', 'body', 'teaser'))
  ->condition('n.type', 'dev_content');

  $query->leftJoin("$this->_db.term_node", 'tn', 'tn.vid =n.vid');
  $query->leftJoin("$this->_db.node_revisions", 'nr', 'nr.vid = n.vid');
  $query->addExpression('GROUP_CONCAT(DISTINCT tn.tid)', 'term_list');
  $query->groupBy('n.nid');

Then i’m mapping the term_list for each vocabulary like this:

$this->addFieldMapping('field_dev_tags', 'term_list')
 ->separator(',')
 ->sourceMigration('DevCenterTerm')
 ->arguments(array('source_type' => 'tid'));

$this->addFieldMapping('field_dev_category', 'term_list')
 ->separator(',')
 ->sourceMigration('DevCenterTermPrep')
 ->arguments(array('source_type' => 'tid'));

I know this is happening due to the terms, as when i don’t map the term_list all the nodes get created, but thats about it. Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T04:55:25+00:00Added an answer on May 24, 2026 at 4:55 am

    Is this an issue with those nodes not having a taxonomy assigned to them? If this is the case, try adding a default value to the taxonomy field mapping.

        $this->addFieldMapping('field_dev_category', 'term_list')
     ->separator(',')
     ->sourceMigration('DevCenterTermPrep')
     ->arguments(array('source_type' => 'tid'))->defaultValue(12);
    

    In the beer.inc example, this is documented in the comments:

    You can also use both together – if a default value is provided in
    addition to a source field, the default value will be applied to any
    rows where the source field is empty or NULL.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I recently created a webpage, while using an usbWebserver, so basically a local server.
Im having issues making the code below to work. Basically, I wanted to move
I basically wanted to know what exactly a virtual processor is. At IBM's site
I wanted to add a new property to one of my model (table). Basically
I wanted to create a new property on a table in my model.. Basically
So I wanted to have something like in this image . Basically you have
Basically, I've wanted to get back into Python, so I decided to make a
Basically I wanted to have an if-else statement in my linq to sql statement.
I am new to jqwicket. Basically I wanted to know how to add animation
So basically I just wanted to create an enemy class with pygames.sprite.Sprite as the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.