Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Joshua Partlow updated an issue PuppetDB / PDB-5226 Dotted fact path group by doesn't group Change By: Joshua Partlow Affects Version/s: PDB 6.18.1 Affects Version/s: PDB 6.18.0 Add Comment This message was sent by Atlassian Jira (v8.20.11#820011-sha1:0629dd8) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.409525.1627947342000.9595.1676058540181%40Atlassian.JIRA.
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Austin Blatt updated an issue PuppetDB / PDB-5226 Dotted fact path group by doesn't group Change By: Austin Blatt Fix Version/s: PDB 7.5.2 Add Comment This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.409525.1627947342000.112316.1629395760082%40Atlassian.JIRA.
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Dave Woods commented on PDB-5226 Re: Dotted fact path group by doesn't group Austin Blatt where can we get our hands on a server with this fix? Lynsay Wright has made a fix in the ER Query Service and needs to verify it against the latest fix, before we cut a new release and hand it over to Chris Leicester for a CD4PE release. Add Comment This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.409525.1627947342000.98826.1628069520102%40Atlassian.JIRA.
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Austin Blatt assigned an issue to Austin Blatt PuppetDB / PDB-5226 Dotted fact path group by doesn't group Change By: Austin Blatt Assignee: Austin Blatt Add Comment This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.409525.1627947342000.97064.1627948620156%40Atlassian.JIRA.
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Austin Blatt updated an issue PuppetDB / PDB-5226 Dotted fact path group by doesn't group Change By: Austin Blatt Team: HA Add Comment This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.409525.1627947342000.97065.1627948620201%40Atlassian.JIRA.
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Austin Blatt updated an issue PuppetDB / PDB-5226 Dotted fact path group by doesn't group Change By: Austin Blatt Sprint: HA 2021-08-11 Add Comment This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-bugs/JIRA.409525.1627947342000.97066.1627948620244%40Atlassian.JIRA.
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Austin Blatt updated an issue PuppetDB / PDB-5226 Dotted fact path group by doesn't group Change By: Austin Blatt {code}curl -X POST http://localhost:8080/pdb/query/v4 2>/dev/null \ -H 'Content-Type:application/json' \ -d '{"query": "inventory[facts.osfamily, count()]{ group by facts.osfamily }" }'{code}Produces the SQL{code}2021-08-02 16:36:18,728 INFO [qtp90455758-58] [p.p.query-eng] PDBQuery:b1e56636-dc83-45c4-8943-90620ec4d2d1:["WITH inactive_nodes AS (SELECT certname FROM certnames WHERE (deactivated IS NOT NULL AND deactivated > '2021-07-19T23:36:18.728Z') OR (expired IS NOT NULL and expired > '2021-07-19T23:36:18.728Z')), not_active_nodes AS (SELECT certname FROM certnames WHERE (deactivated IS NOT NULL OR expired IS NOT NULL)) SELECT (fs.stable||fs.volatile)->'osfamily' AS \"facts.osfamily\", count(*) count FROM factsets fs LEFT JOIN environments ON fs.environment_id = environments.id LEFT JOIN certnames ON fs.certname = certnames.certname WHERE NOT ((certnames.certname) in (SELECT certname FROM ( SELECT not_active_nodes.certname AS \"certname\" FROM not_active_nodes ) sub)) GROUP BY (fs.stable||fs.volatile)"]{code}but the {{GROUP BY}} filter is wrong. Instead of the `:field` value of the requested {{facts.osfamily}}, it should be the projection name, surrounded by double quotes.The correct SQL would look like{code}WITH inactive_nodes AS (SELECT certname FROM certnames WHERE (deactivated IS NOT NULL AND deactivated > '2021-07-19T23:36:18.728Z') OR (expired IS NOT NULL and expired > '2021-07-19T23:36:18.728Z')), not_active_nodes AS (SELECT certname FROM certnames WHERE (deactivated IS NOT NULL OR expired IS NOT NULL)) SELECT (fs.stable||fs.volatile)->'osfamily' AS "facts.osfamily", count(*) count FROM factsets fs LEFT JOIN environments ON fs.environment_id = environments.id LEFT JOIN certnames ON fs.certname = certnames.certname WHERE NOT ((certnames.certname) in (SELECT certname FROM ( SELECT not_active_nodes.certname AS "certname" FROM not_active_nodes ) sub)) GROUP BY "facts.osfamily";{code} Add Comment
Jira (PDB-5226) Dotted fact path group by doesn't group
Title: Message Title Austin Blatt created an issue PuppetDB / PDB-5226 Dotted fact path group by doesn't group Issue Type: Bug Affects Versions: PDB 6.18.1 Assignee: Unassigned Created: 2021/08/02 4:35 PM Fix Versions: PDB 6.18.2 Priority: Normal Reporter: Austin Blatt Add Comment This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97)