Hello everyone,
I've had a problem for several days that I can't solve. I want to create an advanced view from 2 hosted views.
Let me explain:
I have a hosted feature layer for which I'm creating a view (I'm only interested in certain fields). No problem to create this view.
I have a hosted table for which I'm creating a view (I'm only interested in certain fields). No problem to create this view.
For each of these views I use the manager.create_view method
My problem is that I can't create a new view from the 2 previous views, whereas I can do it perfectly well from the graphical interface of map viewer classic.
The join_features method doesn't seem to be what I'm looking for because it creates a new independent hosted feature layer (which I don't want).
So I used the method gis.content.create_service(name='xyz', service_type='featureService', is_view=True)
It seems to work, but I still have to update the layer definition using the fl.manager.update_definition(definition) method to modify the [layers] tag in the properties, and that's where I run into my problem, because I don't know how to make sure my json is properly parameterized.
If you have an idea, I'd love to hear from you.
many thanks in advance.
Translated with DeepL.com (free version)