Skip to main content

Hello people,

I’m testing CDM and I want to extend a current model type, I may do it wrong, but my idea is. I’m creating a new type called MyModel, that will be pretty much and CogniteActivity + new fields.

But I don’t know what I’m doing wrong.


type MyModel
@import (
dataModel: {
externalId: "CogniteActivity",
space: "cdf_cdm",
version: "v1"
}
){
FieldA: String,
FieldB: String
}

I got some guidance from this link https://docs.cognite.com/cdf/dm/dm_guides/dm_extending_core_data_model

When I try to save, I got this error

{   "title": "Error: could not update data model",   "message": "An error has occured. Data model was not published.",   "extra": "ÂLine: 40] Data model 'DataModelRef(space=cdf_cdm, externalId=CogniteActivity, version=v1)' cannot be found" }

Thanks in advance

Hi ​@Alex Almeida 

If you're looking to extend the core data model (cdf_cdm or cdf_idm), I recommend checking out the following documentation and giving Neat a try:

🔗 https://cognite-neat.readthedocs-hosted.com/en/latest/

Let me know if you need any help getting started!

 


Reply