Bulk Upload Data

kailashthiyagar
Kilo Guru

I m in Fuji Release. I would like to provide an interface for the end user which allows them to upload an excel sheet which will be updated in the original table.

As an admin, we can use load data-> Import sets - > Transform Data and populate the required information. How we can give this functionality to the end user. Do we have an example?

18 REPLIES 18

Thanks Gary... I m waiting


Okay, here is my write up!




Bulk upload from templated spreadsheet


Thanks Gary.. Let me try it out and post my queries..


garyopela



Hi Gary



Could you please help on this...i got stuck on this for a week now:(


Hi garyopela



I got stuck in the initial stage itself..



  • I created a table "Bulk Upload" (Name : x_21105_first_appl_bulk_upload ... Created it in scoped Appln)
  • Added two fields "Import Name (import_name)" and "Scheduled Import (scheduled_import) reference to scheduled import"
  • Added a UI action Import
  • Created Another Table named as "My Table"
  • Using Load Data, created import set and created a data source, associated transform map and scheduled import.. Marked it as inactive


Opened new record in Bulk Load Table, gave import name as "Test" and chose my "Scheduled Import"


Clicked on import



For debugging purpose, added gs.infoMessage in UI action script as below.. in the delete Data source attachment, nothing happens beyoud getAllAttachment.. I m not sure why.. Will it not work in scoped application.. Or am i doing anything wrong here?



deleteDSAttachments();


attachFile();


runImport();


deleteCurrentAttachment();




function deleteDSAttachments(){


  gs.addInfoMessage('Delete');


  var attachment = new GlideSysAttachment();


  //var agr = attachment.getAllAttachments("sys_data_source", getDSSysID());


  var agr = attachment.getAllAttachments("sys_data_source", 'b7afbf470f903200d5b945ace1050e71'); //Hardcoded SysID of my data source


  gs.addInfoMessage('getRecords');


  while(agr.next()) {


  gs.addInfoMessage('loop');


  attachment.deleteAttachment(agr.getValue("sys_id"));


  }


}