最新消息:ww12345678 的部落格重装上线,希望大家继续支持。

Powershell(D365FO)中的简单元数据查询 / Simple metadata query in Powershell (D365FO)

网络文摘 William 665浏览 0评论
If I need to extra metadata of a D365FO application, my preferred way is the new metadata API. But sometimes the requirement is so simple that it’s sufficient to query source XML files directly. For example, this all what’s needed to get a list of fields from a table (together with their types) and store it in a CSV file. It’s written in Powershell:
[xml]$xml = Get-Content $inputXmlFilePath
$xml.AxTable.Fields.AxTableField | select Name, ExtendedDataType, EnumType | Export-CSV $outputCsvFilePath -nti
It’s great for trivial cases like this. If I needed more details about fields or I had to take into account table extensions, for example, then the metadata API would be a better choice.
发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址