2
In the following query in any SQL
SELECT * FROM TABELA WHERE CAMPO1 = :PARAM1 AND CAMPO2 = :PARAM2
I need to get the names of these parameters, PARAM1
and PARAM2
and store them in a list or array.
Then I can replace it with the values.
How do I do it in C#?
pq you want to do replace or instead of bind?
– Bruno Warmling
I am automating some methods with Reflection, and when I pass a query in the parameter for example, I would need to know which parameters. Roughly speaking, I myself will do the manual bind of the query.
– Jeterson Miranda Gomes
Wouldn’t it be the case to take all the
IndexOf
character : and take the name until you find a space?– Felipe Avelar