Node-Red Influxdb In Querry field


i would like to have a query with dynamical variable.

Example that works but it doesnt have dynamical variable. "-5d" is hardcoded.

When i set my date in date picker msg.payload goes to my influxdb input.

Something like this?

I got errors:

Is this possible?

Try using a Template node to construct the query. There is a built in example in the node that explains the syntax.