can we use parameters from parameters.yml into spa...
# questions
d
can we use parameters from parameters.yml into spark sql ? Something like params.yml
x = 123
node.py
df = spark.sql(''''select * from table where x = '{x}' ''')
d
it would have to be via a node
but there is no reason why you can’t do that
aside from managing SQL injection risk
d
the thing is when i try the above , its passing the variable directly as a string generated sql : `select * from table where x = `{x}``
d
in a node or catalog entry?
d
node
d
then you need to do python string interpolation with
.format
or
f
strings
it’s just a python string
d
so
spark.sql('''f"my query"''')
?
oh no i got it
d
cool
d
spark.sql(f"my query")
worked
d
🚀