Hey team! I'm trying to create/transfer a visualiz...
# gooddata-cloud
e
Hey team! I'm trying to create/transfer a visualization object from one workspace to another and - even though the API request gives me 201 - I can't still see the object. Viz object id:
viz.anpr.sessions.accuracy
Source workspace id:
dev.master
Target workspace id:
stage.master
https://data.park46.se/analyze/#/dev.master/viz.anpr.sessions.accuracy/edit Can you please check the logs to see what can be the problem?
m
Hi Evangelos, thank you for this. May I ask how did you 'transfer' them? I would like to refer this old thread where a customer is asking the same. Please have a look, in the meantime I will check our logs.
I have check the LDM, I can see you you are not using the same datasource (different ID) , which may not be the problem if all dependencies are correct. I found the following error:
Copy code
Caused by: net.snowflake.client.jdbc.SnowflakeSQLException: SQL compilation error: error line 29 at position 4\ninvalid identifier 'IS_START_TIME_INVALID'
Thus, I would suggest to check the datasource of the TargetWS, specifically the invalid identifier.
m
just out of curiosity - do both workspaces have the same datamodel and are you sure all the metrics and other objects used by that visualization exist in the twrget workspace? As far as I know you can in some cases create an entity that refers to non-existent object and in that case the entity will be considered "broken" and will not appear in the lists on the UI. For these cases there is a special HTTP header that can be used in some API requests:
X-GDC-VALIDATE-RELATIONS: true
When used the relations of the entities are scanned and the APIs return if all the relations are valid or not.
e
Thanks for pointing out the problem and for the fast response @Mauricio Cabezas , it was a change that wasn't deployed in the staging db in Snowflake.
🙌 1
Thanks for the tip @Michal Hauzírek. We're currently using this request: https://www.gooddata.com/docs/cloud/api-and-sdk/api/api_reference_all/#operation/createEntity@VisualizationObjects Can the mentioned HTTP header be used in this case?
m
I am afraid it is currently not supported at the moment of creation of the object, but rather when listing the existing objects, mostly in those listing one or multiple existing objects of some kind (metrics, visualizations...) API calls. The API reference should list the http header by those API calls that support it. i.e.
e
Cool, we can implement something on top of it after the object creation. Thanks for the tip @Michal Hauzírek 👌