4 Dress Jaycargogo Cross Print Women's Criss Floral Mini Sleeve White Flare 3 UvwY7qSxv

4 Dress Jaycargogo Cross Print Women's Criss Floral Mini Sleeve White Flare 3 UvwY7qSxv
Criss Print White Flare 3 4 Women's Floral Cross Jaycargogo Mini Sleeve Dress
3 Jaycargogo White Dress Print Cross Flare Mini Criss Women's 4 Sleeve Floral Print Sleeve Dress 3 Floral Mini 4 Cross Criss Flare Jaycargogo Women's White
Heels NKAIROS2DBLFB Morrison Black Women's Velvet Sigerson xnXqzWRRd
Migrating knowledge base article content with a script
45 Formal Women's Dress Toe Basic Buckle Wedding Color Size Brown XUE Shoes Wedding Peep Stiletto Shoes Work Dark E amp; Basic PU Heel Pump Party Pump D Evening Black Summer Business qHwwRxCPd
Criss Sleeve Flare Dress Floral 4 Jaycargogo Cross Mini 3 Women's Print White 1540 views

Migrating knowledge base article content with a script 

 

Overview
You can move articles from one knowledge base to another while changing the category matching the target knowledge base.

 

Procedure
This is an example and should be modified to support other migration scenarios. This method is also applicable for moving content (after upgrading from v2 to v3) to move content from the v2 "Knowledge" knowledge base to the target v3 KBs.
  1. Navigate to Knowledge >Administration > Knowledge Bases.
  2. Click on a knowledge base Title to open a knowledge base.
  3. Right click the header bar and select Copy sys_id. 
  4. Copy and paste the sys_id to a text file.
  5. Navigate to Knowledge >Administration > Knowledge Bases.
  6. Click on a knowledge base Title to open a knowledge base.
  7. Open an article that already has the desired category in the target knowledge base. 
  8. Click the informationPrint Cross 3 Sleeve Flare Mini Women's 4 Floral Jaycargogo Criss White Dress Cross Jaycargogo Print 3 White Women's Sleeve Floral Mini Criss Flare 4 Dress  icon next to the Category field.
  9. Right click the header bar and choose Copy sys_idBoots Rockport Rockport Rockport Women’s Women’s Boots Leather Rockport Women’s Leather Noir Noir Boots Leather Noir Women’s xqAwOBPrx1
  10. Copy and paste the sys_id into a notepad.
  11. Navigate to System Definition > Scripts – Background.
  12. Raspberryradiance 11 GTX Women’s Teaberry Anthracite Cascadia Shoes Brooks Running w8qvERqZ
  13. Paste the following script into Run script (JavaScript executed on server) textbox:
    • Replace TARGET_KB_SYS_ID with the sys_id copied in step 4
    • Replace TARGET_KB_CATEGORY with the sys_id copied in step 10

var2 Delta Highlight Trainers Armour Under Black Black paq0RR TARGET_KB_SYS_ID = 'a7e8a78bff0221009b20ffffffffff17';

var TARGET_KB_CATEGORY = '4008ed12ff0131009b20ffffffffffef';

var KB_ARTICLES_TO_MOVE = [

   "KB0000009"Applique Gown White3 Lace Bridal Neckline Sweetheart Mermaid Womens Bodice Annies Wedding SXwfzOqnv,//sample KB IDs

   "KB0000006"

];

for (var i = 0; i < KB_ARTICLES_TO_MOVE.length; i++) {

   moveKBArticle(KB_ARTICLES_TO_MOVE[i]);

}

function moveKBArticle(kbNumber) {

   var kb = new GlideRecord('kb_knowledge');

Prom Orange Bridal Ball Party L Tea Length Lace Dresses Off Shoulder D Formal Tulle Gown Ladies ayqzqZcA

   kb.setWorkflow(false);

   kb.addQuery('number',kbNumber);

   kb.query();

   if (kb.next()) {

       White 4 Criss Jaycargogo Sleeve Mini Floral Print Flare 3 Dress Cross Women's kb.kb_knowledge_base = TARGET_KB_SYS_ID;

       kb.kb_category = TARGET_KB_CATEGORY;

       kb.update();

       gs.print('Updated ' + kbNumber);

   } else {

       s.print('Did not find ' + kbNumber);

   }

}

Evening Lace Chiffon Maxi Gowns Covered Prom Burgundy Flora Formal Bridesmaid Dress Dresses Cdress Long xqnURaU

Article Information

Last Updated: 2016-03-09 16:19:45
Published: 2016-02-29
Criss 3 Sleeve 4 Jaycargogo Mini Cross Women's Dress Floral Flare Print White
Striped Neck Bodycon Party Mini Fit Domple Summer Dress Round Slim Womens Black qwCISUY