- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2016 11:14 PM
Hi All,
We are using data source to do the transform of datas from import table to target table, The data source is triggered by scheduled data import.
We specified the header row is 1 in data source so whenever we are updating the excel, it will take the first row of the excel file as header.
Now the challenge is we need to prevent/restrict the next row after the header to be processed.
I have tried to give the Header row as 2 and its not taking the both first and second rows, its taking the second row as the header.
we need to stop processing the record which placed in second row in the excel.
Is there any way to achieve this
Thanks in advance
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2016 11:50 PM
Hi Antony,
Go to your transform map, Checked the run script and write below code in Transform map run script :
if(source.sys_import_row==0 || source.sys_import_row==NULL) {
ignore = true;
}
As after header it will be the first row with index 0, so it will ignore the first row.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-17-2016 11:50 PM
Hi Antony,
Go to your transform map, Checked the run script and write below code in Transform map run script :
if(source.sys_import_row==0 || source.sys_import_row==NULL) {
ignore = true;
}
As after header it will be the first row with index 0, so it will ignore the first row.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2016 01:21 AM
Thanks Paramveer.
Its working .. The script "sys_import_row==0" checks the index of the row. Amazing
Is it possible to count how much rows filled in the Excel by using the "sys_import_row", because we need to allow only 1000 records(header, and row after header are excluded) to process.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2016 01:52 AM
yes It's also possible, you can write code like ;
if(source.sys_import_row >= 999) {
ignore = true;
}
Please mark correct/helpful if you find my reply worthy.
Thanks,
Param
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-18-2016 02:56 AM
Thanks once again paramveer .
Can i count the number of rows filled with data in Excel so that i can dynamically pass the value for validations ??