Hi Allin,
Am 23.02.2020 18:41 schrieb Allin Cottrell:
On Wed, 19 Feb 2020, Sven Schreiber wrote:
> Am 19.02.2020 um 10:19 schrieb atecon:
> >
> > 1) I want to write a open_odbc_connection() function. Unfortunately,
> > the 'open' command cannot be executed within a function. For its
> > standard application loading a data set I fully understand the reason.
> > However, for just opening a ODBC connection by the '--odbc" option, I
> > don't get rational for this restriction.
> > Feature request: Allow making use of the open command in case the
> > --odbc option is passed.
>
> Wanting this functionality sounds very reasonable, but I'm noticing that
> 'open .... --odbc' does not seem to be documented in the command reference.
As I mentioned previously, Artur's request is now granted. In response
to Sven's observation I've now added references to the ODBC option to
the doc for the "open" and "data" commands.
I just compiled latest source code from git. Unfortunately, the 'open'
command still returns an error when calling the function:
<hansl>
function void open_odbc_connection (string DSN,
string USER,
string PW)
open dsn=@DSN user=@USER password=@PW --odbc
end function
</hansl>
The error message is: "The "open" command cannot be used in this context
*** error in function open_odbc_connection, line 1"
Outside the function, the "open" command works fine.
I've also added a little to the ODBC chapter of the User's
Guide, and
changed its status to a regular chapter rather than an appendix. (That
makes it easier to hot-link into the online help.)
Thanks for the update!