Get row count in import set

niharikayb
Kilo Contributor

Hi all,

i have a data source file containing columns "PO number" and "assets" .After running   the transform,   i need to get the count of assets under each PO . How can i achieve this ? please suggest .

NOTE :

I am getting the total row count when am using below script :

ONCOMPLETE Transform Script:

var ast = new GlideRecord('u_dell_data');

ast.addQuery('sys_import_set',source.sys_import_set);

ast.query();

var count = ast.getRowCount();

gs.log("count of all assets":+count);

                             

Thanks in Advance,

Niharika

6 REPLIES 6

Sanjeev Kumar1
Kilo Sage

The ServiceNow Wiki content is no longer supported. Updated information about this topic is located here: GlideAggregate
 




Visit http://docs.servicenow.com for the latest product documentation


Ankur Bawiskar
Tera Patron
Tera Patron

Hi Niharika,



You want to print the import set record count after the transform runs or count related to the target table after the transform map ran



Mark Correct if this solves your issue and also hit Like and Helpful if you find my response worthy based on the impact.


Thanks


Ankur


Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Pranshu5
Giga Contributor

Hi Niharika,

Could you please confirm of any final solution you have received?

I have the same requirement as well!

Thanks & regards,

Pranshu