Using Materialized Data in Typescript

I am new to typescript in Foundry, but I need to access a materialized object that I’ve configured to take entries from workshop, within my typescript function. I am not sure how to access materialized object sets in typescript. What would I need to import and how do I call it?

@ctakla , typically in TypeScription and Functions, users are expected to interact with Objects and ObjectSets, this will contain all of the user edits and will have the same data that is present in the materialized dataset.

Docs for Functions on Objects

You shouldn’t need to interact with the materalized dataset directly, everything should be available via Functions on Objects.

1 Like

I thought so, but It is not accessing the materialized rows through the object.

Can you explain what you mean by it’s not accessing the materialized rows through the object? Functions on Objects will always be accessing the most up to date data in the ontology.

in workshop, an action is used to materialize a row in the object’s materialization dataset, it does not configure the original dataset that backs the object. So, in other actions where it is referencing the object through a link, it is not showing any items that are in the materialization only. The link isn’t linking to the full object, just the backing dataset is my suspicion, because when i start with the object associated with the materialization, everything works great. In my code I need to traverse to the object, but it is only gathering information from the backing dataset.

That’s correct, Actions will not make changes to the original dataset that backs the object. However, actions apply edits to an Object, and that Object will reflect the ontology changes for future queries. The Object will not be only referencing the original backing dataset, it will contain the ontology edits without a developer having to configure anything else. Can you confirm that you’re referencing the objects that have the changes? I suspect there’s a configuration issue where you’re not referencing the same object, or you’re not applying the edits to the object.

You can read more on object edits in the docs here: https://www.palantir.com/docs/foundry/object-edits/how-edits-applied

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.