Trying to access a sys_property from a metric

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-26-2024 02:30 AM
Hi Experts,
I'm trying to access a system property containing sys_ids of catalog items in a metric definition. However, everything I've tried so far isn't working. Code is below - any help is appreciated!
Thank you!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-26-2024 02:37 AM
Hi Richard,
Metric is on which table? I assume it to be Catalog Task. Also, I see you have added log statements. What is that is generated in the logs.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-26-2024 02:48 AM
Hi Jaspal - thanks for your reply.
Yes it's on the catalog task table. the Logs are returning the sys_ids as required but the script is not working as it's generating metrics for all sc tasks created
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-26-2024 02:56 AM
Hi @Richard Thomas2 ,
Insted of toString () try replacing with below one
var arrString = array[i].trim();
And after createMetric() use break;
Mark it as helpful and solution proposed if it serves your purpose.
Thanks,
Anand

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-26-2024 04:03 AM
Hi Jaspal,
Not it's still not working I'm afraid :(. Will keep trying!