<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Accessing Tags in XQL in General Topics</title>
    <link>https://live.paloaltonetworks.com/t5/general-topics/accessing-tags-in-xql/m-p/517006#M107349</link>
    <description>&lt;P&gt;I have this working, but it still returns the value in double quotes. I've no idea if there is a btter way to a cheive thgis nor if it possible to remove the quotes but this works for me for now&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;dataset = endpoints 
| alter server = json_extract(tags,"$.server_tags")
| alter server = trim(server,"[]")
| fields endpoint_name as Host_Name, agent_version as Version, server as Server_Tag&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 06 Oct 2022 13:39:44 GMT</pubDate>
    <dc:creator>ianatgrafton</dc:creator>
    <dc:date>2022-10-06T13:39:44Z</dc:date>
    <item>
      <title>Accessing Tags in XQL</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/accessing-tags-in-xql/m-p/517003#M107346</link>
      <description>&lt;P&gt;I can see that tags are exposed on the endpoints dataset in XQL but when I inlcude them in a query they appear (vaguely) as key value pairs thus:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"endpoint tags": [], "server_tags":["IAN"]&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The schema though reports tags as being of type string and not an array&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would like to be able to extract just the server tag value(s) and present that in an XQL query, is that possible?&lt;/P&gt;</description>
      <pubDate>Thu, 06 Oct 2022 13:15:31 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/accessing-tags-in-xql/m-p/517003#M107346</guid>
      <dc:creator>ianatgrafton</dc:creator>
      <dc:date>2022-10-06T13:15:31Z</dc:date>
    </item>
    <item>
      <title>Re: Accessing Tags in XQL</title>
      <link>https://live.paloaltonetworks.com/t5/general-topics/accessing-tags-in-xql/m-p/517006#M107349</link>
      <description>&lt;P&gt;I have this working, but it still returns the value in double quotes. I've no idea if there is a btter way to a cheive thgis nor if it possible to remove the quotes but this works for me for now&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;dataset = endpoints 
| alter server = json_extract(tags,"$.server_tags")
| alter server = trim(server,"[]")
| fields endpoint_name as Host_Name, agent_version as Version, server as Server_Tag&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 06 Oct 2022 13:39:44 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/general-topics/accessing-tags-in-xql/m-p/517006#M107349</guid>
      <dc:creator>ianatgrafton</dc:creator>
      <dc:date>2022-10-06T13:39:44Z</dc:date>
    </item>
  </channel>
</rss>

