Perl module DBD::ODBC 0.39 wont compile on CYGWIN

2002-03-25 Thread Paul A. Chernoch

DBD::ODBC Version 0.38 builds and passes the tests, but 0.39 wont even 
compile. Here are the error messages:

$ make
cp ODBC.pm blib/lib/DBD/ODBC.pm
/usr/bin/perl -p -e "s/~DRIVER~/ODBC/g" < 
/usr/lib/perl5/site_perl/5.6.1/cygwin-multi/auto/DBI/Driver.xst > ODBC.xsi
/usr/bin/perl -I/usr/lib/perl5/5.6.1/cygwin-multi -I/usr/lib/perl5/5.6.1 
/usr/lib/perl5/5.6.1/ExtUtils/xsubpp  -typemap
/usr/lib/perl5/5.6.1/ExtUtils/typemap ODBC.xs > ODBC.xsc && mv ODBC.xsc ODBC.c
gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin-multi/auto/DBI 
-DPERL_USE_SAFE_PUTENV -fno-strict-aliasing -I/usr/local/include 
-DUSEIMPORTLIB -O2   -DVERSION=\"0.39\" 
-DXS_VERSION=\"0.39\"  -I/usr/lib/perl5/5.6.1/cygwin-multi/CORE  ODBC.c
gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin-multi/auto/DBI 
-DPERL_USE_SAFE_PUTENV -fno-strict-aliasing -I/usr/local/include 
-DUSEIMPORTLIB -O2   -DVERSION=\"0.39\" 
-DXS_VERSION=\"0.39\"  -I/usr/lib/perl5/5.6.1/cygwin-multi/CORE  dbdimp.c
dbdimp.c: In function `odbc_db_login6':
dbdimp.c:211: `SQL_ATTR_ODBC_VERSION' undeclared (first use in this function)
dbdimp.c:211: (Each undeclared identifier is reported only once
dbdimp.c:211: for each function it appears in.)
dbdimp.c:211: `SQL_IS_INTEGER' undeclared (first use in this function)
dbdimp.c: At top level:
dbdimp.c:1644: warning: `_dbd_rebind_ph' was declared implicitly `extern' 
and later `static'
dbdimp.c:1190: warning: previous declaration of `_dbd_rebind_ph'
make: *** [dbdimp.o] Error 1


When I look, the undeclared symbols are really, truly undefined. 
SQL_ATTR_ODBC_VERSION does not even appear to exist in version 0.38.

(BTW, as far as I can tell, the patch file used some time ago by CYGWIN 
users to fix the Makefile.pl has been fully incorporated into more recent 
builds, so I know that is not the problem.)

I just upgraded today to the latest version of CYGWIN, and with it comes 
perl v5.6.1.

   - Paul
.. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

.. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





RE: How to add Date records to MS ACCESS

2001-04-27 Thread Paul A. Chernoch

I spent a week or so dealing with date conversion issues. I am moving data 
between Access, Oracle and SQL Server and have had to master their 
vicissitudes. Here is what I discovered about formatting dates for ODBC 
(Access and SQL Server). The official version (from the DBI or DBD 
documentation somewhere) differs from my experience.

#How to insert  dates/times in ODBC (Official Version)
#
#ODBC has a special way of handling dates which is generic for all DBMS's.
#You should use the following formats in your statements:
# Dates: {d '-MM-DD'}
# Times: {t 'HH:MM:SS'}
# TimeStamp or DateTime: {ts '-MM-DD HH:MM:SS'}
#
#The best way to handle this is to use sprintf:
#
#$ODBCDate = sprintf("{d '%4d-%02d-%02d'}", $year, $mon, $day);
#Note 1: Years must be 4 digits.
#Note 2: When you do a SELECT the dates get returned in whatever format
#is set for the database, not the ODBC format.
#
#When the above fails to work (as it sometimes does) try this format:
#
#Dates: '-MM-DD'
#Times: 'HH:MM:SS'(optional AM PM: 'HH:MM:SS PM")
#Timestamp: '-MM-DD HH:MM:SS'
#
#This format seems to work for Access and SQL Server 7.

Hope this helps. I use parameter binding, so I do not have to worry about # 
vs ' vs " bracketing issues.

   - Paul

At 09:45 AM 4/27/2001 -0600, Sterin, Ilya wrote:
>-Original Message-
>From: Bodo Eing
>To: Maria Quinn
>Cc: 'mi email '; '[EMAIL PROTECTED] '
>Sent: 04/27/2001 9:03 AM
>Subject: RE: How to add Date records to MS ACCESS
>
>Date sent:  Fri, 27 Apr 2001 15:55:21 +0100 (BST)
>From:   Maria Quinn <[EMAIL PROTECTED]>
>To: "Sterin, Ilya" <[EMAIL PROTECTED]>
>Copies to:  "'mi email '" <[EMAIL PROTECTED]>,
> "'[EMAIL PROTECTED] '" <[EMAIL PROTECTED]>
>Subject:RE: How to add Date records to MS ACCESS
>
> > On Fri, 27 Apr 2001, Sterin, Ilya wrote:
> >
> > > I believe in access you must enter date as "#02/03/1999#"
> > >
> > > Also your query is totally wrong, it's not
> > > "INSERT $date INTO table1
> > > VALUES($date)"
> > >
> > > but rather
> > >
> > > "insert into table 1 date values ($date)
> >
> > Shouldn't that be:
> >
> > insert into table1 values ($date)
> >
> > I'm not familiar with Access SQL syntax, so I may be wrong.
> >
> > Maria
>
>"insert into table1 date values ($date)"
>
> >is probably closest to what was meant by mi email. Ilya's version
> >contained just a typo (the space between 'table' and '1'). BTW, what
> >about storing your dates as long integers and leaving the conversion
> >from input and to formatted output to the application level ?
>
>Wooppss, typing too fast, sorry.
>
>
>
> >Bodo
> >[EMAIL PROTECTED]
> >Dr. med. Bodo Eing
> >Institut fuer Medizinische Mikrobiologie
> >Klinische Virologie
> >v.-Stauffenbergstr. 36
> >48151 Muenster
> >Germany
>
>Phone: ++49 251 7793 111 Fax: ++49 251 7793-104

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





Re: CSV ? Question...

2001-04-20 Thread Paul A. Chernoch

I have only used DBD::CSV a little, but discovered the following:

o SELECT works
o DROP table works
o DELETE works
o UPDATE works
o APPEND works

No real field data type info is preserved. Dates are treated like text. A 
missing column at the end of a record is treated as a NULL, but if a middle 
column is empty it is treated as an empty string, not a NULL.

One annoying feature (I use CYGWIN): The owner of the file becomes the 
owner of the table and when you get the list of tables via DBI, you may get 
something like "username".tablename as the table name. That is great, but 
you cannot select from that table without dropping the username or you get 
a syntax error in your SQL.

Also, do not have spaces or periods in your filenames. Example: You have a 
file named EMPLOYEES.CSV. It wont work. You have to take the ".CSV" off the 
filename.

Read the documentation carefully, as it explains important things like how 
to change the separator from a comma to a semicolon or something else, and 
other neat things.

 - Paul

At 02:53 PM 4/19/2001 +0200, you wrote:
>Hi,
>
>I'd like to do something using DBD::CSV, it's like a good system but does 
>he understand DELETE, UPDATE, DROP reuquest (in sql statement...) ?
>
>There's no information about this kind of things
>
>Well thnks...
>
>
>Ps : an other question, in the same way but, i'd like to do a a report 
>system that should generate one file with a lot of page (one page per 
>client), like tim's report system in ingram group, no ? It's should 
>generate a lot of invoice in a file, and then print (using a printer) all 
>the invoice... any thing can do that, or any module can generate 
>staroffice files ?
>
>
>Thanks,
>
>--
>
>=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=
>Nicolas  JOURDEN - [EMAIL PROTECTED] - #41100039 - +33 0681940905
>http://www.wedoo.com/   - La Nouvelle Facon de Surfer...
>http://ddx.wedoo.com/   - Mon site perso.
>Programmeur, Integrateur  | Perl, CGI, Mysql/PostgreSQL, HTML, Design
>=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=-~-=
>

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





Re: newbie...

2001-04-14 Thread Paul A. Chernoch

DBI requires the use of the appropriate DBD driver being installed as a 
prerequisite. Which DBD::* module are you using for your test? DBD::CSV 
depends upon a few other modules being installed, like SQL::Statement and 
one other that escapes my recollection. DBD::Oracle itself can be a 
challenge to build and install, because it depends upon how Oracle is 
configured on your system, and you have to build liboci.a and stuff it in 
the right place (in your lib path). And DBD::ODBC offers its own challenges.

BTW - what were the compilation errors? Try "perl -c -w test.pl" and see 
what it suggests.

- Paul


At 11:03 PM 4/13/2001 -0600, Camilo Rostoker wrote:
>Hey fellas,
>
>Just venturing out into the world of DBI.  I downloaded the DBI.pm
>package, and followed the steps to install it, but no luckI wrote a
>test file using DBI from an onlist resource, but I get the following
>error when I try and run it:
>
>Software error:
>Execution of /home/httpd/cgi-bin/test.pl aborted due to compilation
>errors.
>
>Just wondering if you could give me a few hints...
>
>Cheers,
>Camilo
>
>==
>
>Camilo Rostoker
>[EMAIL PROTECTED]
>http://www.rostoker.com/
>
>The 2 most important things in life:
>1. never tell anyone everything you know about something
>2. ...
>
>==

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





Re: In text mode Works, but in HTML does'nt

2001-04-12 Thread Paul A. Chernoch

When I am debugging CGI scripts, I follow this simple approach:

1. Manually set the CGI environment parameters to simulate a CGI call.
2. Invoke the CGI script from the command line on the server.
3. Look at the HTML text that is output. If it looks wrong, fix the script. 
(It helps to create a static HTML file on the server that contains all the 
text except the Content-type header to really make sure the HTML is OK.)
4. If the HTML that is output looks OK, then create a simple Perl script 
that simply prints out this resulting HTML (with the Content type header) 
to see if that works. If it does not, perhaps your web server requires you 
to fill in more of the HTTP headers than just the content-type? (I have 
seen this happen with some web servers.)

If none of this works, you are on your own...

- Paul

At 07:14 PM 4/11/2001 -0500, Aguztyn Garcia-Cruz wrote:
>Some body can Help ME?
>
>Tanks in Advance

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





Re: Help with installing DBD::Oracle

2001-04-10 Thread Paul A. Chernoch

Try using nmake, which you can get free from Microsoft.com. It took me a 
number of searches before I found it and I can't remember which one worked.

- Paul

At 02:12 PM 4/9/2001 -0500, Reuss, Bob wrote:
>Hello All,
>
>I am trying to install the DBD::Oracle module on my Windows 2000 system.  I
>have downloaded the module and have extracted the files via winzip.  Here is
>where I run into problems.  If I follow the installation instructions for
>active state and just move the modules, it doesn't work.  If I run the
>makefile.pl file, I get multiple library errors, but, it finds all the
>oracle paths correctly, and the DBI paths, etc...  The problem then is I
>need to run make on the makefile.  I do not have a make utility installed on
>the windows 2000 server.  I tried to install a few I found on the web but
>they did not work.  Can anyone help me with solutions on how to install the
>module?
>
>TIA,
>Bob Reuss

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





RE: Problems builing and testing DBD::ODBC with Cygwin

2001-04-09 Thread Paul A. Chernoch

Neil,

I must sheepishly admit that I had already made changes to the Makefile.pl 
before applying the patch so the patch was not entirely successful. After 
getting a fresh copy of the library and applying the patch, all is well and 
not only the tests but my application run successfully. Thank you for your 
assistance and those critical words "apply to a clean distribution".

   - Paul

At 10:40 AM 4/9/2001 +1000, Neil Lunn wrote:

>Paul,
>
>Was the patch applied from this message.
>
>http://sources.redhat.com/ml/cygwin/2000-08/msg00464.html
>
>This should apply to a clean distribution of DBD-ODBC-0.28.
>
>Neil
>
> > -Original Message-
> > From: Paul A. Chernoch [mailto:[EMAIL PROTECTED]]
> > Sent: Sunday, April 08, 2001 7:16 AM
> > To: [EMAIL PROTECTED]
> > Subject: Problems builing and testing DBD::ODBC with Cygwin
> >
> >
> > I searched through the Cygwin archives on redhat and got part
> > way there. I
> > have patched my Makefile.PL to reflect their recommendations
> > (like #UNDEF
> > WIN32 and removing "-lodbccp32") to deal with the win32.h
> > problems. This
> > got me to be able to compile at least. But I get one
> > troublesome warning,
> > and most of the tests fail. The warning below is "warning:
> > passing arg 3 of
> > `SQLDriverConnect' makes integer from pointer without a cast". Any
> > suggestions? I use perl 5.6.1 on Windows 2000, using cygwin 1.1.8.
> >
> > - Paul
> >
> > --
> >
> > gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin/auto/DBI
> > -DPERL_USE_SAFE_PUTENV -DHAS_SBRK_PROTO -fno-strict-aliasing
> >   -DUSEIMPORTLIB -O2   -DVERSION=\"0.28\"
> > -DXS_VERSION=\"0.28\"  -I/usr/lib/perl5/5.6.1/cygwin/CORE  ODBC.c
> > gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin/auto/DBI
> > -DPERL_USE_SAFE_PUTENV -DHAS_SBRK_PROTO -fno-strict-aliasing
> >   -DUSEIMPORTLIB -O2   -DVERSION=\"0.28\"
> > -DXS_VERSION=\"0.28\"  -I/usr/lib/perl5/5.6.1/cygwin/CORE  dbdimp.c
> > dbdimp.c: In function `odbc_db_login':
> > dbdimp.c:171: warning: passing arg 3 of `SQLDriverConnect'
> > makes integer
> > from pointer without a cast
> > Running Mkbootstrap for DBD::ODBC ()
> > chmod 644 ODBC.bs
> > rm -f blib/arch/auto/DBD/ODBC/ODBC.dll
> > LD_RUN_PATH="/usr/local/lib" ld2 -o
> > blib/arch/auto/DBD/ODBC/ODBC.dll  -s
> > -L/usr/local/lib ODBC.o dbdimp.o -lodbc32  /usr
> > /lib/perl5/5.6.1/cygwin/CORE/libperl5_6_1.a -lodbc32
> > dllwrap --dllname ODBC.dll --driver-name gcc --dlltool dlltool
> > --export-all-symbols --as as --output-def libODBC.def --o
> > utput-lib libODBC.a \
> >   -s -L/usr/local/lib ODBC.o dbdimp.o -lodbc32
> > /usr/lib/perl5/5.6.1/cygwin/CORE/libperl5_6_1.a -lodbc32
> > dllwrap: no export definition file provided
> > dllwrap: creating one, but that may not be what you want
> > mv ODBC.dll libODBC.a blib/arch/auto/DBD/ODBC/
> > chmod 755 blib/arch/auto/DBD/ODBC/ODBC.dll
> > cp ODBC.bs blib/arch/auto/DBD/ODBC/ODBC.bs
> > chmod 644 blib/arch/auto/DBD/ODBC/ODBC.bs
> > bash-2.04$ make test
> > PERL_DL_NONLAZY=1 /usr/bin/perl5.6.1 -Iblib/arch -Iblib/lib
> > -I/usr/lib/perl5/5.6.1/cygwin -I/usr/lib/perl5/5.6.1 -e 'use
> >   Test::Harness qw(&runtests $verbose); $verbose=0; runtests
> > @ARGV;' t/*.t
> > t/01baseok
> > t/02simple..ok 1/14  0 [main] perl5.6.1 1980
> > handle_exceptions:
> > Exception: STATUS_ACCESS_VIOLATION
> > 1770 [main] perl5.6.1 1980 stackdump: Dumping stack trace to
> > perl5.6.1.exe.stackdump
> > t/02simple..dubious
> >  Test returned status 0 (wstat 139, 0x8b)
> >  test program seems to have generated a core
> > DIED. FAILED tests 2-14
> >  Failed 13/14 tests, 7.14% okay
> > t/03dbatt...ok 1/6  0 [main] perl5.6.1 2008
> > handle_exceptions:
> > Exception: STATUS_ACCESS_VIOLATION
> > 3815 [main] perl5.6.1 2008 stackdump: Dumping stack trace to
> > perl5.6.1.exe.stackdump
> > t/03dbatt...dubious
> >  Test returned status 0 (wstat 139, 0x8b)
> >  test program seems to have generated a core
> > DIED. FAILED tests 2-6
> >  Failed 5/6 tests, 16.67% okay
> > t/05methok 1/6  0 [main] perl5.6.1 2024
> > handle_exceptions:
> > Exception: STATUS_ACCESS_VIOLATION
> > 1250 [main] perl5.6.1 2024 stackdump: Dumping stack trace to
> > perl5.6.1.exe.stackdump
> > t/05methdubious
> &

Re: (Fwd) Calling an Oracle Stored Procedure from PERL

2001-04-09 Thread Paul A. Chernoch

I have called Oracle stored procedures from Perl successfully using bound 
named parameters. I am too busy to reduce my program down to a size 
suitable for posting to a mailing list, but any interested parties may 
e-mail me directly. In a separate message I will respond directly to the 
questioner.

My success has been with Perl  5.005_03 (an older ActiveState build 523) 
and DBI 1.14. I am trying to port it to Cygwin, but am having trouble with 
DBD::ODBC. (The DBD::Oracle part does work, though.) DBI 1.15 causes 
problems with DBD::Oracle for some reason.

- Paul

At 04:00 PM 4/8/2001 -0700, you wrote:
>I answered you directly last week.  Perhaps you should use SQL*Loader
>instead.
>--
>Mac :})
>** I normally forward private database questions to the DBI mail lists. **
>Give a hobbit a fish and he'll eat fish for a day.
>Give a hobbit a ring and he'll eat fish for an age.
>- Original Message -
>From: "Tim Bunce" <[EMAIL PROTECTED]>
>To: <[EMAIL PROTECTED]>
>Cc: <[EMAIL PROTECTED]>
>Sent: Sunday, April 08, 2001 11:47 AM
>Subject: (Fwd) Calling an Oracle Stored Procedure from PERL
>
>
> > From: [EMAIL PROTECTED] ()
> > To: [EMAIL PROTECTED]
> > Subject: Calling an Oracle Stored Procedure from PERL
> > Date: Fri, 6 Apr 2001 16:13:49 -0700
> >
> > I am a beginner PERL programmer and looking for some advice if anyone can
> > help.  I just started to learn PERL about 2-3 weeks ago and I like it
> > alot!!!
> >
> > The problem...I currently receive a daily flat file that is loaded into an
> > Oracle (8.0.5) database.  When I assumed responsibility of this system the
> > PERL scripts were already written.  Since some of the data is incorrect
>that
> > gets loaded into the Oracle db I need to update it.  I have written an
> > Oracle Package (Stored Procedure) in PL/SQL to perform this update
>HOWEVER,
> > I don't know how to call the package from the PERL script.  I'm assuming
>it
> > is relatively simple however I'm unsure and was looking for some help.
> >
> > I have installed the DBI, DBD::Oracle modules.  I am able to connect and
> > retrieve data from my Oracle db.  Do I need anything more?  It just the
> > procedure that I have all my update code written into and compiled reside
>on
> > the server and I'm not sure how to call the Package.  Help??
> >
> > Anyone have any suggestions/advice...or better yetAn example piece of
> > code with comments would be great if you have one!?!?!

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





RE: Problems builing and testing DBD::ODBC with Cygwin

2001-04-09 Thread Paul A. Chernoch

That was indeed the patch that I used. I have since discovered that there 
were many copies of sqlext.h on my machine and one had an erroneous 
function prototype:

The prototype that I found was:
SQLRETURN SQL_API 
SQLDriverConnect(SQLHDBC,SQLHWND,SQLCHAR,SQLSMALLINT,SQLCHAR*,SQLSMALLINT,SQLSMALLINT*,SQLUSMALLINT);

But it should have been:
SQLRETURN SQL_API 
SQLDriverConnect(SQLHDBC,SQLHWND,SQLCHAR*,SQLSMALLINT,SQLCHAR*,SQLSMALLINT,SQLSMALLINT*,SQLUSMALLINT);

This fixes the compiler warning, but the tests still fail as bad as before. 
What next?

- Paul

At 10:40 AM 4/9/2001 +1000, Neil Lunn wrote:

>Paul,
>
>Was the patch applied from this message.
>
>http://sources.redhat.com/ml/cygwin/2000-08/msg00464.html
>
>This should apply to a clean distribution of DBD-ODBC-0.28.
>
>Neil
>
> > -Original Message-
> > From: Paul A. Chernoch [mailto:[EMAIL PROTECTED]]
> > Sent: Sunday, April 08, 2001 7:16 AM
> > To: [EMAIL PROTECTED]
> > Subject: Problems builing and testing DBD::ODBC with Cygwin
> >
> >
> > I searched through the Cygwin archives on redhat and got part
> > way there. I
> > have patched my Makefile.PL to reflect their recommendations
> > (like #UNDEF
> > WIN32 and removing "-lodbccp32") to deal with the win32.h
> > problems. This
> > got me to be able to compile at least. But I get one
> > troublesome warning,
> > and most of the tests fail. The warning below is "warning:
> > passing arg 3 of
> > `SQLDriverConnect' makes integer from pointer without a cast". Any
> > suggestions? I use perl 5.6.1 on Windows 2000, using cygwin 1.1.8.
> >
> > - Paul
> >
> > --
> >
> > gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin/auto/DBI
> > -DPERL_USE_SAFE_PUTENV -DHAS_SBRK_PROTO -fno-strict-aliasing
> >   -DUSEIMPORTLIB -O2   -DVERSION=\"0.28\"
> > -DXS_VERSION=\"0.28\"  -I/usr/lib/perl5/5.6.1/cygwin/CORE  ODBC.c
> > gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin/auto/DBI
> > -DPERL_USE_SAFE_PUTENV -DHAS_SBRK_PROTO -fno-strict-aliasing
> >   -DUSEIMPORTLIB -O2   -DVERSION=\"0.28\"
> > -DXS_VERSION=\"0.28\"  -I/usr/lib/perl5/5.6.1/cygwin/CORE  dbdimp.c
> > dbdimp.c: In function `odbc_db_login':
> > dbdimp.c:171: warning: passing arg 3 of `SQLDriverConnect'
> > makes integer
> > from pointer without a cast
> > Running Mkbootstrap for DBD::ODBC ()
> > chmod 644 ODBC.bs
> > rm -f blib/arch/auto/DBD/ODBC/ODBC.dll
> > LD_RUN_PATH="/usr/local/lib" ld2 -o
> > blib/arch/auto/DBD/ODBC/ODBC.dll  -s
> > -L/usr/local/lib ODBC.o dbdimp.o -lodbc32  /usr
> > /lib/perl5/5.6.1/cygwin/CORE/libperl5_6_1.a -lodbc32
> > dllwrap --dllname ODBC.dll --driver-name gcc --dlltool dlltool
> > --export-all-symbols --as as --output-def libODBC.def --o
> > utput-lib libODBC.a \
> >   -s -L/usr/local/lib ODBC.o dbdimp.o -lodbc32
> > /usr/lib/perl5/5.6.1/cygwin/CORE/libperl5_6_1.a -lodbc32
> > dllwrap: no export definition file provided
> > dllwrap: creating one, but that may not be what you want
> > mv ODBC.dll libODBC.a blib/arch/auto/DBD/ODBC/
> > chmod 755 blib/arch/auto/DBD/ODBC/ODBC.dll
> > cp ODBC.bs blib/arch/auto/DBD/ODBC/ODBC.bs
> > chmod 644 blib/arch/auto/DBD/ODBC/ODBC.bs
> > bash-2.04$ make test
> > PERL_DL_NONLAZY=1 /usr/bin/perl5.6.1 -Iblib/arch -Iblib/lib
> > -I/usr/lib/perl5/5.6.1/cygwin -I/usr/lib/perl5/5.6.1 -e 'use
> >   Test::Harness qw(&runtests $verbose); $verbose=0; runtests
> > @ARGV;' t/*.t
> > t/01baseok
> > t/02simple..ok 1/14  0 [main] perl5.6.1 1980
> > handle_exceptions:
> > Exception: STATUS_ACCESS_VIOLATION
> > 1770 [main] perl5.6.1 1980 stackdump: Dumping stack trace to
> > perl5.6.1.exe.stackdump
> > t/02simple..dubious
> >  Test returned status 0 (wstat 139, 0x8b)
> >  test program seems to have generated a core
> > DIED. FAILED tests 2-14
> >  Failed 13/14 tests, 7.14% okay
> > t/03dbatt...ok 1/6  0 [main] perl5.6.1 2008
> > handle_exceptions:
> > Exception: STATUS_ACCESS_VIOLATION
> > 3815 [main] perl5.6.1 2008 stackdump: Dumping stack trace to
> > perl5.6.1.exe.stackdump
> > t/03dbatt...dubious
> >  Test returned status 0 (wstat 139, 0x8b)
> >  test program seems to have generated a core
> > DIED. FAILED tests 2-6
> >  Failed 5/6 tests, 16.67% okay
> > t/05methok 1/6  0 [main] perl5.6.1 2024
> > handle_exceptions:
> > Exception: STATUS_ACC

Problems builing and testing DBD::ODBC with Cygwin

2001-04-07 Thread Paul A. Chernoch

I searched through the Cygwin archives on redhat and got part way there. I 
have patched my Makefile.PL to reflect their recommendations (like #UNDEF 
WIN32 and removing "-lodbccp32") to deal with the win32.h problems. This 
got me to be able to compile at least. But I get one troublesome warning, 
and most of the tests fail. The warning below is "warning: passing arg 3 of 
`SQLDriverConnect' makes integer from pointer without a cast". Any 
suggestions? I use perl 5.6.1 on Windows 2000, using cygwin 1.1.8.

- Paul

--

gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin/auto/DBI 
-DPERL_USE_SAFE_PUTENV -DHAS_SBRK_PROTO -fno-strict-aliasing
  -DUSEIMPORTLIB -O2   -DVERSION=\"0.28\" 
-DXS_VERSION=\"0.28\"  -I/usr/lib/perl5/5.6.1/cygwin/CORE  ODBC.c
gcc -c -I. -I/usr/lib/perl5/site_perl/5.6.1/cygwin/auto/DBI 
-DPERL_USE_SAFE_PUTENV -DHAS_SBRK_PROTO -fno-strict-aliasing
  -DUSEIMPORTLIB -O2   -DVERSION=\"0.28\" 
-DXS_VERSION=\"0.28\"  -I/usr/lib/perl5/5.6.1/cygwin/CORE  dbdimp.c
dbdimp.c: In function `odbc_db_login':
dbdimp.c:171: warning: passing arg 3 of `SQLDriverConnect' makes integer 
from pointer without a cast
Running Mkbootstrap for DBD::ODBC ()
chmod 644 ODBC.bs
rm -f blib/arch/auto/DBD/ODBC/ODBC.dll
LD_RUN_PATH="/usr/local/lib" ld2 -o blib/arch/auto/DBD/ODBC/ODBC.dll  -s 
-L/usr/local/lib ODBC.o dbdimp.o -lodbc32  /usr
/lib/perl5/5.6.1/cygwin/CORE/libperl5_6_1.a -lodbc32
dllwrap --dllname ODBC.dll --driver-name gcc --dlltool dlltool 
--export-all-symbols --as as --output-def libODBC.def --o
utput-lib libODBC.a \
  -s -L/usr/local/lib ODBC.o dbdimp.o -lodbc32 
/usr/lib/perl5/5.6.1/cygwin/CORE/libperl5_6_1.a -lodbc32
dllwrap: no export definition file provided
dllwrap: creating one, but that may not be what you want
mv ODBC.dll libODBC.a blib/arch/auto/DBD/ODBC/
chmod 755 blib/arch/auto/DBD/ODBC/ODBC.dll
cp ODBC.bs blib/arch/auto/DBD/ODBC/ODBC.bs
chmod 644 blib/arch/auto/DBD/ODBC/ODBC.bs
bash-2.04$ make test
PERL_DL_NONLAZY=1 /usr/bin/perl5.6.1 -Iblib/arch -Iblib/lib 
-I/usr/lib/perl5/5.6.1/cygwin -I/usr/lib/perl5/5.6.1 -e 'use
  Test::Harness qw(&runtests $verbose); $verbose=0; runtests @ARGV;' t/*.t
t/01baseok
t/02simple..ok 1/14  0 [main] perl5.6.1 1980 handle_exceptions: 
Exception: STATUS_ACCESS_VIOLATION
1770 [main] perl5.6.1 1980 stackdump: Dumping stack trace to 
perl5.6.1.exe.stackdump
t/02simple..dubious
 Test returned status 0 (wstat 139, 0x8b)
 test program seems to have generated a core
DIED. FAILED tests 2-14
 Failed 13/14 tests, 7.14% okay
t/03dbatt...ok 1/6  0 [main] perl5.6.1 2008 handle_exceptions: 
Exception: STATUS_ACCESS_VIOLATION
3815 [main] perl5.6.1 2008 stackdump: Dumping stack trace to 
perl5.6.1.exe.stackdump
t/03dbatt...dubious
 Test returned status 0 (wstat 139, 0x8b)
 test program seems to have generated a core
DIED. FAILED tests 2-6
 Failed 5/6 tests, 16.67% okay
t/05methok 1/6  0 [main] perl5.6.1 2024 handle_exceptions: 
Exception: STATUS_ACCESS_VIOLATION
1250 [main] perl5.6.1 2024 stackdump: Dumping stack trace to 
perl5.6.1.exe.stackdump
t/05methdubious
 Test returned status 0 (wstat 139, 0x8b)
 test program seems to have generated a core
DIED. FAILED tests 2-6
 Failed 5/6 tests, 16.67% okay
t/09bindok 1/9  0 [main] perl5.6.1 1968 handle_exceptions: 
Exception: STATUS_ACCESS_VIOLATION
1240 [main] perl5.6.1 1968 stackdump: Dumping stack trace to 
perl5.6.1.exe.stackdump
t/09binddubious
 Test returned status 0 (wstat 139, 0x8b)
 test program seems to have generated a core
DIED. FAILED tests 2-9
 Failed 8/9 tests, 11.11% okay
Failed Test  Status Wstat Total Fail  Failed  List of Failed

t/02simple.t   0   13914   13  92.86%  2-14
t/03dbatt.t0   139 65  83.33%  2-6
t/05meth.t 0   139 65  83.33%  2-6
t/09bind.t 0   139 98  88.89%  2-9
Failed 4/5 test scripts, 20.00% okay. 31/40 subtests failed, 22.50% okay.
make: *** [test_dynamic] Error 2
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .





RE:DBI, DBD::Oracle problem

2001-04-06 Thread Paul A. Chernoch

Javier -
I have not had any luck on Solaris or Win2000 with DBI 1.15 and 
DBD::Oracle. DBD::Oracle fails some of the same tests for me as you 
described in your e-mail, even though DBI installs and tests fine. The only 
solution for me was backing up to DBI 1.14. I don't have the patience to 
rebuild and mess with compiler switches and the like.

- Paul
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Paul Anton Chernoch
Zeborg, Inc.
500 West Cummings Park
Woburn, MA 01801

t: 781.759.0105
f: 781.935.5090
c: 781.606.7382

http://www.zeborg.com
This message is a personal and confidential communication. If you are not
the intended recipient, please do not read, copy, or use it, and do not
disclose it to others. Please notify the sender of the delivery error by
replying to this message, and then delete it from your system. Thank you.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .