Named Query - Specific cell

I have a few named queries setup on my project so I'm semi familiar with queries, but this particular problem is related to a text box that I want to populate with SQL data, depending on the selected dropdown "StepName".

Table: processsteps
Columns: StepNumber, StepName, Editor, Comments

I want to populate a textbox with Editor and Comment data when the particular StepName is selected. I have the dropdown data tied to an internal tag, and I'm trying to use that to point towards the correct row in the SQL table:

SELECT Editor
FROM processsteps
WHERE StepName = {[default]Internal/ActiveStepRecipe.value}

It does not like this, and I'm not sure if it's a formatting problem or linking the tag is where it's going wrong. Any thoughts?

Are you using a scalar named query for the text box?

Since you are using a named query, you parameterize the step name and then use your tag as the parameter in the binding.

Your named query should look like this

Thank you! That took care of that.

If I have a button I want to use to delete a specific row based on this same "StepName" selection, would I set it up the same? Scalar and have step_name as a parameter?

No, scalar queries return a single value instead of a dataset. For deletes and updates you want to change the query type to update