Deleting a Relationship for Previous Generations

Hi! How can I remove a BOM relationship for previous generations of a Part? I tried to write a SQL Query but I couldn't mange it. thanks  
Parents
  • Manipulating previous released Generations of an Item is not recommended. But if you really need to fix a previous generation for once, you can do this with applySQL. Something like this may work:
    
    string bomId = "1234567889............"; // id of BOM relationship in your previous generation. Not ID of related Part!
    string mySQL = "DELETE FROM PART_BOM WHERE [ID]='" + bomId +"'";
    Item  myResult = this.getInnovator().applySQL(mySQL);
    Please be aware, that your existing Change Managment processes may contain invalid information. MPP process plans may become corrupted. You can really produce many negative side effects when manipulating previous Part versions the db. So you really need to take care what you do!
Reply
  • Manipulating previous released Generations of an Item is not recommended. But if you really need to fix a previous generation for once, you can do this with applySQL. Something like this may work:
    
    string bomId = "1234567889............"; // id of BOM relationship in your previous generation. Not ID of related Part!
    string mySQL = "DELETE FROM PART_BOM WHERE [ID]='" + bomId +"'";
    Item  myResult = this.getInnovator().applySQL(mySQL);
    Please be aware, that your existing Change Managment processes may contain invalid information. MPP process plans may become corrupted. You can really produce many negative side effects when manipulating previous Part versions the db. So you really need to take care what you do!
Children
No Data