Forum Discussion

baxterfly's avatar
baxterfly
New Contributor
2 years ago

How to replace a hardcoded value with a snap variable GraphQL Snap Query

Hi there, 

I have a GraphQL Client snap with a query which works well when i hardcode an ID I am looking to search. 

However I want to replace this hard coded ID "screenshot 1 in blue" with a variable which I define in an earlier mapper snap screenshot 2. 
When I try and replace it with $HistoricalValue, i get an error. saying its undefined. Is there a way I can insert this variable into a graphQL query?

Any help greatly appreciated

 

Screenshot 1

Screenshot 2