Could it be possible to also implement the \set mechanism of defining the key-value pairs as it is done in either PostgreSQL's psql [1] or Vertica's vsql [2]?
My current problem is that when I have some named parameter markers that I want to apply to a series of 20 or so SQL-statements (same values for all statements), I have to press the 'Continue' button in pop-up dialogs 20 or so times after selecting those statements and 'Ctrl+.'. It would be so much more convenient to be able to define those parameters in the code, as psql and vsql allow me to.
Also, such addition would make it easy to run the same parameterized SQL scripts in either psql/vsql or DBVis.
[1] http://www.postgresql.org/docs/current/static/app-psql.html
[2] https://my.vertica.com/docs/7.1.x/HTML/index.htm#Authoring/ConnectingToHPVertica/vsql/Variables.htm
Vladim,
Your request is certainly good. The main challenge however is that it would be a rather big hassle offering support for other tools variable management in DbVisualizer.
In DbVisualizer there is the ${variable}$ syntax which has been around since the early days of DbVisualizer with support for default values and a lot more, and since 9.2 there is now also support for parameter markers that are found in most programming languages, such as :var, ?, :'var', and so on.
I will open a new feature request ticket and we will have a discussion internally.
Regards
Roger
Thank you, Roger.
I would also note that this \set feature seem to be present in many PostgreSQL-derived databases:
https://wiki.postgresql.org/wiki/PostgreSQL_derived_databases
anonymous