{
"@odata.type": "#Microsoft.Dynamics.CRM.LookupAttributeMetadata",
"MetadataId": "c7a58b13-df19-491c-a918-1bc26eaf6eb3",
"HasChanged": null,
"AttributeOf": null,
"AttributeType": "Customer",
"ColumnNumber": 179,
"DeprecatedVersion": null,
"IntroducedVersion": "5.0.0.0",
"EntityLogicalName": "contact",
"IsCustomAttribute": false,
"IsPrimaryId": false,
"IsValidODataAttribute": true,
"IsPrimaryName": false,
"IsValidForCreate": true,
"IsValidForRead": true,
"IsValidForUpdate": true,
"CanBeSecuredForRead": false,
"CanBeSecuredForCreate": false,
"CanBeSecuredForUpdate": false,
"IsSecured": false,
"IsRetrievable": true,
"IsFilterable": false,
"IsSearchable": true,
"IsManaged": true,
"LinkedAttributeId": null,
"LogicalName": "parentcustomerid",
"IsValidForForm": true,
"IsRequiredForForm": false,
"IsValidForGrid": true,
"SchemaName": "ParentCustomerId",
"ExternalName": null,
"IsLogical": false,
"IsDataSourceSecret": false,
"InheritsFrom": null,
"CreatedOn": "1900-01-01T00:00:00Z",
"ModifiedOn": "1900-01-01T00:00:00Z",
"SourceType": null,
"AutoNumberFormat": "",
"Targets": [
"account",
"contact"
],
"Format": "None",
"AttributeTypeName": {
"Value": "CustomerType"
},
"Description": {
"LocalizedLabels": [
{
"Label": "Select the parent account or parent contact for the contact to provide a quick link to additional details, such as financial information, activities, and opportunities.",
"LanguageCode": 1033,
"IsManaged": true,
"MetadataId": "6391aa12-2341-db11-898a-0007e9e17ebd",
"HasChanged": null
}
],
"UserLocalizedLabel": {
"Label": "Select the parent account or parent contact for the contact to provide a quick link to additional details, such as financial information, activities, and opportunities.",
"LanguageCode": 1033,
"IsManaged": true,
"MetadataId": "6391aa12-2341-db11-898a-0007e9e17ebd",
"HasChanged": null
}
},
"DisplayName": {
"LocalizedLabels": [
{
"Label": "Company Name",
"LanguageCode": 1033,
"IsManaged": true,
"MetadataId": "6291aa12-2341-db11-898a-0007e9e17ebd",
"HasChanged": null
}
],
"UserLocalizedLabel": {
"Label": "Company Name",
"LanguageCode": 1033,
"IsManaged": true,
"MetadataId": "6291aa12-2341-db11-898a-0007e9e17ebd",
"HasChanged": null
}
},
"IsAuditEnabled": {
"Value": true,
"CanBeChanged": true,
"ManagedPropertyLogicalName": "canmodifyauditsettings"
},
"IsGlobalFilterEnabled": {
"Value": true,
"CanBeChanged": true,
"ManagedPropertyLogicalName": "canmodifyglobalfiltersettings"
},
"IsSortableEnabled": {
"Value": false,
"CanBeChanged": true,
"ManagedPropertyLogicalName": "canmodifyissortablesettings"
},
"IsCustomizable": {
"Value": true,
"CanBeChanged": false,
"ManagedPropertyLogicalName": "iscustomizable"
},
"IsRenameable": {
"Value": true,
"CanBeChanged": false,
"ManagedPropertyLogicalName": "isrenameable"
},
"IsValidForAdvancedFind": {
"Value": true,
"CanBeChanged": true,
"ManagedPropertyLogicalName": "canmodifysearchsettings"
},
"RequiredLevel": {
"Value": "None",
"CanBeChanged": true,
"ManagedPropertyLogicalName": "canmodifyrequirementlevelsettings"
},
"CanModifyAdditionalSettings": {
"Value": true,
"CanBeChanged": false,
"ManagedPropertyLogicalName": "canmodifyadditionalsettings"
}
}
Solved! Go to Solution.
Hi @loeakaodas,
It will be hard (but possible) to automatically detect the columns within a table. parentcustomerid will not be the only column type that you need to special logic but File type and eventually 1-M (multi-table) lookups also (e.g. parentcustomerid into _parentcontactid_value or _parentaccountid_value). I suggest if you can to keep it simple. It will be a lot of continuous maintenance to always refine as the metadata changes. Maybe you include in your ALM process to automatically detect metadata changes and then manually check with the team what those changes are and if it requires an update to the ETL? You can detect metadata changes with RetrieveMetadataChangesRequest message: https://docs.microsoft.com/powerapps/developer/data-platform/org-service/metadata-retrieve-detect-c...
Hope this helps!
Thanks to everyone for the replies!
I believe I've solved my own problem by retrieving and parsing the $metadata document for the Dynamics instance. The `Property` elements for each `EntityType` match up exactly to the fields returned by calling that specific entity/table endpoint; at least for the few entities I've checked so far like the "contact" entity I was having with issues in the OP.
I'm not concerned with the complex types like lookup, file, and relationships at this time but thanks for the heads up @EricRegnier and @ChrisPiasecki !
Hi @loeakaodas,
Can you utilize the metadata service api to get what you are looking for? https://docs.microsoft.com/en-us/powerapps/developer/data-platform/webapi/query-metadata-web-api
Hope this helps. Please accept if answers your question or Like if helps in any way.
Thanks,
Drew
Sorry, looked more and that is what you tried...
Hi @loeakaodas,
In your example, the parentcustomerid is a Lookup, and actually a special polymorphic Lookup (can be contact or account). Data from related tables are not returned by default and you'll need to use the Expand query operator to get related data.
Have a review of the querying the Web API documentation to get familiar with querying it using OData.
---
Please click Accept as Solution if my post answered your question. This will help others find solutions to similar questions. If you like my post and/or find it helpful, please consider giving it a Thumbs Up.
Hi @loeakaodas,
It will be hard (but possible) to automatically detect the columns within a table. parentcustomerid will not be the only column type that you need to special logic but File type and eventually 1-M (multi-table) lookups also (e.g. parentcustomerid into _parentcontactid_value or _parentaccountid_value). I suggest if you can to keep it simple. It will be a lot of continuous maintenance to always refine as the metadata changes. Maybe you include in your ALM process to automatically detect metadata changes and then manually check with the team what those changes are and if it requires an update to the ETL? You can detect metadata changes with RetrieveMetadataChangesRequest message: https://docs.microsoft.com/powerapps/developer/data-platform/org-service/metadata-retrieve-detect-c...
Hope this helps!
Thanks to everyone for the replies!
I believe I've solved my own problem by retrieving and parsing the $metadata document for the Dynamics instance. The `Property` elements for each `EntityType` match up exactly to the fields returned by calling that specific entity/table endpoint; at least for the few entities I've checked so far like the "contact" entity I was having with issues in the OP.
I'm not concerned with the complex types like lookup, file, and relationships at this time but thanks for the heads up @EricRegnier and @ChrisPiasecki !
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
User | Count |
---|---|
23 | |
5 | |
4 | |
3 | |
3 |
User | Count |
---|---|
24 | |
8 | |
7 | |
6 | |
5 |