I am looking for a tool that would help me easily reuse queries.

What should it be like?

You type a query like Select * FROM person where name LIKE ${name}
And you would like to re-use this type of query next time like invocation of some function with parameter/s like personWithNameLike(P) or personWithNameLike(name=p}

Is there any tool that could help me in any way?

link|improve this question

"And U would like reuse" - Pleeease use complete words and somewhat correct grammar. – Nifle Jul 13 '11 at 9:51
What type of database are you using? (MySql, Postgres, etc.) – Bryan Agee Jul 13 '11 at 16:06
feedback

1 Answer

up vote 0 down vote accepted

Read about how to setup stored procedures for your version of SQL (if supported).

A stored procedure lets you define what should be done (eg: a query), the expected input and output and then you can 'call' the procedure just as you describe.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.