All,

I was hoping this would be a easy job, but I'm a bit stuck now. Let me give you a little background on what I'm trying to accomplish.

Over the past few years I've written a web-based tool used for tracking test cases and results, it runs directly on Linux and there's a postgres db in the back end where everything is stored. I wrote a module specific for database transactions (queries, inserts, updates, etc).

Anyway, we have a automation team that are writing scripts that mostly run on Windows, I was hoping I could give them my Database module, and they would integrate it into their scripts and then they would have direct access to the database. Currently, they are writing their results out to a flat file, I thought if they could write to our database directly, it would be must more efficient and we would get results from the scripts in "real-time".

So, I write a little script on Windows, and included my db module (which I slightly modified). I installed ActivePerl 5.8 and installed the DBI module (using ppm).

But now it's complaining about a DBD::pg.pm module (see below).

install_driver(Pg) failed: Can't locate DBD/Pg.pm in @INC (@INC contai +ns: C: ne 3. Perhaps the DBD::Pg perl module hasn't been fully installed, or perhaps the capitalisation of 'Pg' isn't right. Available drivers: DBM, ExampleP, File, PgPP, Proxy, Sponge. at DataBaseActions.pm line 43
I've looked in ppm, and searched on DBD and got the following:
ppm> search DBD Searching in Active Repositories 1. DBD-ADO [2.95] DBD-ADO 2. DBD-AnyData [0.08] DBD-AnyData 3. DBD-Chart [0.80] DBD-Chart 4. DBD-CSV [0.22] DBD-CSV 5. DBD-Excel [0.06] DBD-Excel 6. DBD-File [0.34] DBD-File 7. DBD-LDAP [0.07] DBD-LDAP 8. DBD-Log [0.21] DBD-Log 9. DBD-Mimer [1.00] DBD-Mimer 10. DBD-Mock [1.32] DBD-Mock 11. DBD-Multiplex [1.98-1] DBD-Multiplex 12. DBD-mysql [3.0002] DBD-mysql 13. DBD-mysql-SimpleMySQL [0.5] DBD-mysql-SimpleMySQL 14. DBD-mysqlPP [0.04] DBD-mysqlPP 15. DBD-ODBC [1.13] DBD-ODBC 16. DBD-Oracle [1.17] DBD-Oracle 17. DBD-Ovrimos [0.12] DBD-Ovrimos 18. DBD-PgPP [0.05] DBD-PgPP 19. DBD-Redbase [0.21] DBD-Redbase 20. DBD-Sprite [0.56] DBD-Sprite 21. DBD-SQLite [1.11] DBD-SQLite 22. DBD-SQLite2 [0.33] DBD-SQLite2 23. DBD-SQLrelay [0.1] DBD-SQLrelay 24. DBD-Template [0.01] DBD-Template 25. DBD-XBase [0.241] DBD-XBase 26. DBIx-AnyDBD [2.01] DBIx-AnyDBD 27. FabForce-DBDesigner4 [0.02] FabForce-DBDesigner4 ppm> install DBD-pgPP
So, at this point I'm not sure what else I can do ??? I don't see a DBD::pg.pm module. I did try to load the PgPP driver, but that didn't help.

If anybody has any ideas I would greatly appreciate it.

UPDATE:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

ok, I've installed the DBD::PgPP driver and I'm trying to run my script, and I'm getting the following error:

DBD::PgPP::db selectall_arrayref failed: Unknown message type: ' at DataBaseActions.pm line 124.

I know my code is ok because it's the same code that runs on Linux. Any thoughts ?


In reply to Running a script on Windows to access a postgres database on Linux by TASdvlper

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.