Re: Feature Request: SQL parameters

Поиск
Список
Период
Сортировка
От Bernhard Neuhauser
Тема Re: Feature Request: SQL parameters
Дата
Msg-id FACFAC06BB4349408E9FD5D9CAAE6F920854861BB3@SEAMBX.corp.real.com
обсуждение исходный текст
Ответ на Re: Feature Request: SQL parameters  (Eric Schwarzenbach <subscriber@blackbrook.org>)
Список pgadmin-support
Hi,

> Ok, but the use-case I'm talking about is debugging applications using 
> SQL, in my case an application using JDBC. Maybe I'm misunderstanding 
> the point of your post. I'm taking it as suggesting I switch to using $n 
> notation. This isn't an option.

If you are using hibernate (which is not to uncommon in javas world), 
it's possible to bind variables in native queries using ":bindingname".

Spring itself is also using the an identical named parameter binding mechanic.
(You need to use Spring JDBC Templates).

Additionally I know that toad for oracle uses named parameters like that.
That’s somehow funny, because oracle itself is not capable of this syntax (at least not the version I use).
But I still like it, because you only need to add the ":" in front of the already available parameter names for debug
purpose.

I am not sure if this helps, because I don’t know how this mechanics could fit into the PG world.

But it highlights one simple aspect:
Several independent dev teams tried to bind parameters per name, 
because often it's most important to create a bug free application in time.

Regards,
Bernhard

В списке pgadmin-support по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: Feature Request: SQL parameters
Следующее
От: Edgar Sepulveda
Дата:
Сообщение: Re: Execute arbitrary SQL queries does not come up in pgAdmin