Re: Safe handling of an SQL query
Jiří Pavlovský <[email protected]>
| Newsgroups | gmane.comp.apache.mod-perl |
|---|---|
| Message-ID | <[email protected]> |
On 16.4.2012 15:55, Vincent Veyron wrote:
>
> My question is :
>
> Can I make sure that whatever query is sent to the server, it will only
> be a SELECT<...> and _never_ a UPDATE or INSERT or DELETE
> ?
>
>
In addition to already mentioned approaches you could also have a look
at the "ReadOnly" attribute supported by DBI:
" An application can set the "ReadOnly" attribute of a handle to a
true value to indicate that it will not be attempting to
make any changes using that handle or any children of it.
"
--
Jiří Pavlovský