Hello Team
Good Day!
We are trying to find if any updated data happened on a table by comparing LAST_RUN and system date updates by using stored procedure but getting stuck here. Please help to correct me on this if any changes required.
Thank you.
Through Sceduled scripts in Source we are testing below code but getting error message.
var channelcache = channelcache.getValue('LAST_RUN');
var DateTime = qie.doQuery('testsqldb','select DateTime from Patient');
function updatedDatafind(channelcache,DateTime)
{
var fchannelcache=channelcache;
var fDateTime=DateTime;
if (DateTime > channelcache)
{
var updateddata = qie.doQuery('testsqldb','select distinct * from Patient');
return updateddata;
}
else
{ return false;
}
}
qie.debug(updatedDatafind(channelcache,DateTime));
And error message getting as below
Error running scheduled script: 'task':
[line: 18] EcmaError: TypeError: Cannot call method "getValue" of undefined