I'm trying to determine how I can find the integer values for picklist fields in Dynamics via the web api. I can access the basic metadata by using:
GET https://[COMPANY].api.crm3.dynamics.com/api/data/v9.0//EntityDefinitions(LogicalName='lead')/Attributes/
but for picklist values I don't see the mapping of the integer value to the displayed string.
Is there a table that holds all of this or a way to expand this information on the above call?
You can use this to retrieve.
https://[COMPANY].api.crm3.dynamics.com/api/data/v9.0/EntityDefinitions(LogicalName='{Entity Name}')/Attributes(LogicalName='{OptionSet Name}')/Microsoft.Dynamics.CRM.PicklistAttributeMetadata?$select=LogicalName&$expand=GlobalOptionSet($select=Options)
Reference
Related
Is it possible to add Edm.DateTime field based on CDS View Date Source Reference without warnings in SAP Gateway Service Builder?
I created simple CDS View based on select from dd07l with Date field just to show this case, code to create date field is taken directly from sap help example: https://help.sap.com/doc/abapdocu_751_index_htm/7.51/en-us/abencds_f1_date_time_conversions.htm
It works fine, but during project check in SAP Gateway Service Builder (segw) there is warning shown due to missing Precision field settings, but it is not possible to change it manually in segw for Data Source Reference.
I was looking for some annotation for that purpose, but I didn't find any suitable for it.
#AbapCatalog.sqlViewName: 'ZTEST2_V'
#AbapCatalog.compiler.compareFilter: true
#AbapCatalog.preserveKey: true
#AccessControl.authorizationCheck: #CHECK
#EndUserText.label: 'Test'
define view ZTEST2_CDS as select from dd07l as domain
{
key domain.domname,
key domain.domvalue_l,
tstmp_to_dats(tstmp_current_utctimestamp(), abap_system_timezone($session.client, 'NULL'), $session.client, 'NULL') as dat
}
Most probably in your SEGW service definition OData V2 is specified. OData V2 only has Edm.DateTime and when converting ABAP DATS field to Edm.DateTime you will always receive this warning.
Starting from NW 750 you can also implement Odata V4 services via SEGW which has special Edm.Date type, but it significantly affects frontend implementation. So, if you have to stick with Odata V2 I would suggest just ignore this warning.
I've created an ADF flow that loops over URL's to fetch OData using the OData connection.
However, not all fields are available in all URL's, there are certain ones that are available in one URL, but not in the other. A $Select is used to select the fields that we need.
Is it possible to have an optional selection (as in, if the path is not available, do not fetch this field and return null instead for instance)? Would help us a great deal.
I've tried adding ? after the field, but that does not work. $select=Field1,Field2,FieldOptional?
Thanks
As I understand you are trying to loop through a bunch of a URL and the query on the ODATA URL will change and so will be the fields . I think you can use a lookup where you pass the unique url and its gives the fields and then concatenate the url with the fields and make a odata call .
I need to call REST API from DENODO (I use denodo express 7) with dynamic query param. This query param value would come from another JDBC data source view so that I can straightaway limit the results.
I have tried using interpolation variables, for example:
http://<hostname:port>/path?id=#{viewname.transaction_id} but it goes as null always, not sure is this correct way of accessing the view fields?
for our scopes we need to use unique ID generated by us for the answers submitted by users. This is possible by adding "?c=" at the end of the survey link followed by the ID number.
Example Format: http://www.surveymonkey.com/s/XXXXX?c=00001
The terrific problem is that the custom value is not returned anyway via API. It is not added as a property of the Answer object neither its value replaces somehow the respondant_id property.
We see that you are able to expose that data from your internal endpoints that you use for your proprietary web interface but how to get this data from he outside via API?
Thanks
When you call 'get_respondent_list', ensure you pass through 'custom_id' in the list of strings in the 'fields' parameter. This will then be returned in the output with the custom value you entered.
Is it possible to query an OData collection filtering by the updated metadata field? The case for that would be to get a list of updates since the last check.
I've tried http://odata.netflix.com/v1/Catalog/People?$filter=updated%20eq%202011-05-15T21:45:31Z, but it gives me "No property 'updated' exists in type 'Netflix.Catalog.Person' at position 0". Is there another way I can do this or reference the updated property in a filter statement?
The updated element in the ATOM feed/entry representation may or may not contain actual data. Some services actually do store the real updated timestamp there, but some don't. Since the element is required to be present in all entries by the ATOM format, services which don't have the data to use there usually put some arbitrary timestamp as the value (by default WCF Data Services uses DateTime.Now for the updated field, which is what netflix service does as well).
The $filter can only reference real properties on a given entity. So if the service does have a property which contains the data backing the updated element you would need to find out the name of such property (in the $metadata for example) and then use that. If the service does not have a property like that (for example the netflix service doesn't), then there's no way to filter based on last updated timestamp, as there's no such thing in the underlying data store (the updated element is effectively a fake).
Also note that if you ask for JSON payload the updated element doesn't exist there and so only the real properties are present. Any query operators in the URL work only on the real properties.