Closed pskrbasu closed 6 months ago
Running a named query with no args doesnt work:
query "list_vpcs" {
sql = <<-EOQ
select
title,
vpc_id,
region,
account_id
from
aws_vpc
EOQ
}
passing args by index doesn't work when no params defined:
query "list_vpcs" {
sql = <<-EOQ
select
title,
vpc_id,
region,
account_id
from
aws_vpc
where
region = any($1)
EOQ
}``
passing args by index doesn't work when params are defined:
```hcl
query "list_vpcs" {
sql = <<-EOQ
select
title,
vpc_id,
region,
account_id
from
aws_vpc
where
region = any($1)
EOQ
param "region" {}
}
powerpipe query run list_vpcs --arg '1=["us-east-1"]'
Error: failed to resolve args for custom.table.results: region
$ powerpipe query run list_vpcs --arg 1='["us-east-1"]'
Error: failed to resolve args for custom.table.results: region```
Running a named query with no args doesnt work:
query "list_vpcs" {
sql = <<-EOQ
select
title,
vpc_id,
region,
account_id
from
aws_vpc
EOQ
}
passing args by index doesn't work when no params defined:
query "list_vpcs" {
sql = <<-EOQ
select
title,
vpc_id,
region,
account_id
from
aws_vpc
where
region = any($1)
EOQ
}```
passing args by index doesn't work when params are defined:
```hcl
query "list_vpcs" {
sql = <<-EOQ
select
title,
vpc_id,
region,
account_id
from
aws_vpc
where
region = any($1)
EOQ
param "region" {}
}
powerpipe query run list_vpcs --arg '1=["us-east-1"]'
Error: failed to resolve args for custom.table.results: region
$ powerpipe query run list_vpcs --arg 1='["us-east-1"]'
Error: failed to resolve args for custom.table.results: region```
In net-insights mod:
Running
powerpipe query run "query.dns_parent_report(domain_name_input => \"steampipe.io\")"
works, butRunning
powerpipe query run net_insights.query.dns_parent_report --arg domain_name_input=steampipe.io
FAILS.