Need example of accessing MS Access via perl on FreeBSD
stan
stanb at panix.com
Tue Jul 22 11:15:22 PDT 2003
On Mon, Jul 21, 2003 at 11:47:25AM -0400, stan wrote:
> I need to get some information that is stored on a windows amchine, in an
> Access "database" via a perl script with FreeBSD.
>
> I'v installed teh DBI::ODBC port. I've alos got working code that accesses
> a remote Oracle instance using Perl's DBD::Oracle. I've got access to a
> person who has admin access on the remote windows box, but is not really
> understanding what I'm trying to do.
>
> A sample snipet of working code would be a wonderful thing.
>
> Can anyone help?
>
> It _appears_ that in addition to DBD and DBI::Oralce, I may need a "ODBC
> manager", and an "ODB driver". Is this correct? If so where can I get them?
>
I thought I'd follow up with a bit more progress on this, in the hpe that
some helpful soul will come to my aid.
I found thta id I run iodbc-odbctest _as root_ it does not exit imediatl. I
still don;t know why this is, but for the moent I thoguht I'd plunge ahead.
So my odbc.ini file _now looks like this:
;
; odbc.ini
;
[ODBC Data Sources]
OpenLink = OpenLink (MT)
Test = Test
[OpenLink]
Driver = /usr/local/lib/libiodbc.so
Description = Sample OpenLink MT DSN
Host = localhost
ServerType = Oracle 8
FetchBufferSize = 99
UserName =
Password =
Database =
ServerOptions =
ConnectOptions =
Options =
ReadOnly = no
[Test]
Driver = /usr/local/lib/libiodbc.so
Description = Test
Host = localhost
Server = xxx.xxx.xxx.xx
ServerType = Odbc
DataBase = AlarmHist062203
UserName =
Password =
Database =
ServerOptions =
ConnectOptions =
Options =
ReadOnly = no
[Default]
Driver = /usr/local/lib/libiodbc.so
Obviouslu with a real IP address.
Now her's what I get:
pm1al# iodbc-odbctest
iODBC Demonstration program
This program shows an interactive SQL processor
Enter ODBC connect string (? shows list): ?
DSN | Description
---------------------------------------------------------------
OpenLink | OpenLink (MT)
Test | Test
Enter ODBC connect string (? shows list): Test
[iODBC][Driver Manager]Dialog failed, SQLSTATE=IM008
So what am I doing wrong here?
--
"They that would give up essential liberty for temporary safety deserve
neither liberty nor safety."
-- Benjamin Franklin
More information about the freebsd-questions
mailing list