Issue 104230 - postgresql sdbc driver needs porting
Summary: postgresql sdbc driver needs porting
Status: CLOSED FIXED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: DEV300m54
Hardware: Mac Mac OS X, all
: P3 Trivial (vote)
Target Milestone: ---
Assignee: msicotte
QA Contact: issues@dba
URL:
Keywords: aqua
Depends on:
Blocks:
 
Reported: 2009-08-14 16:32 UTC by msicotte
Modified: 2017-05-20 10:29 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
patch for Mac OS X build (4.24 KB, text/plain)
2009-08-14 16:41 UTC, msicotte
no flags Details
extension for testing - note I had to quit and restart Openoffice after installing the extension for the driver to connect. This version did not display the driver name in the wizard in OOo 3.1.0, but did in DEV300_m54. Both versions would open a previ (337.74 KB, application/octet-stream)
2009-08-14 17:33 UTC, msicotte
no flags Details
extension built on Tiger, tested on Tiger, Leopard, Snow Leopard (346.39 KB, application/octet-stream)
2009-09-05 16:28 UTC, msicotte
no flags Details
test results on Tiger, Leopard, and Snow Leopard (140.22 KB, text/plain)
2009-09-05 16:29 UTC, msicotte
no flags Details
added file needed to run test scripts on Mac OS X (3.87 KB, text/plain)
2009-09-05 16:32 UTC, msicotte
no flags Details
patch to create mac version dataaccess.xcu and changes to makefile (2.68 KB, patch)
2009-09-05 16:49 UTC, msicotte
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description msicotte 2009-08-14 16:32:00 UTC
The postgresql native driver extension was never compiled for Mac OS X.
Comment 1 msicotte 2009-08-14 16:34:45 UTC
started
Comment 2 msicotte 2009-08-14 16:41:16 UTC
Created attachment 64169 [details]
patch for Mac OS X build
Comment 3 msicotte 2009-08-14 17:33:26 UTC
Created attachment 64170 [details]
extension for testing - note I had to quit and restart Openoffice after installing the extension for the driver to connect.  This version did not display the driver name in the wizard in OOo 3.1.0, but did in DEV300_m54.  Both versions would open a previ
Comment 4 joergbudi 2009-08-14 19:17:06 UTC
Hi,

just four remarks:

- its normal that you need to restart the office after installation
- how about sticking to version 0.7.6 as its just a port without different
functionality.
- was it your intention to remove the DriverDisplayName in DataAccess.xcu ?
- did you get the python test skripts to work ?

Bye,

Joerg


Comment 5 msicotte 2009-08-14 21:53:31 UTC
@JOERG
>>>- how about sticking to version 0.7.6 as its just a port without different
functionality.
fine with me
>>>- was it your intention to remove the DriverDisplayName in DataAccess.xcu ?
no - I didn't see DriverDisplayName in the original, just DriverPageDisplayName and 
DriverTypeDisplayName.  Can you send/attach an example - perhaps that's why the name doesn't 
appear in the wizard in 3.1.0
>>>- did you get the python test skripts to work ?
no - following is the error - any ideas?
echo $PYTHONPATH
/Developer/OpenOffice.org.app/Contents/basis-link/program
MacBookPro:postgresql MikeS$ dmake runtest "dburl=sdbc:postgresql:dbname=pqtest"dmake: 
Executing shell macro: +$(IFEXIST) $(TRYSDF) $(THEN) echo $(TRYSDF) $(FI)
start test with  dmake runtest dburl=your-url
  e.g. dmake runtest dburl=sdbc:postgresql:dbname=pqtest
   MUST: Create a separate datbases before (here pqtest),
         (SOME TABLES GET DROPPED)
cd ../../unxmacxi.pro/lib && python main.py "sdbc:postgresql:dbname=pqtest"
Traceback (most recent call last):
  File "main.py", line 67, in <module>
    import statement
  File "/Developer/OpenOffice.org.app/Contents/basis-link/program/uno.py", line 257, in _uno_import
    return _g_delegatee( name, *optargs, **kwargs )
  File "/Developer/Projects/ooo/DEV300_m54/connectivity/unxmacxi.pro/lib/statement.py", line 64, in 
<module>
    import ddl
  File "/Developer/OpenOffice.org.app/Contents/basis-link/program/uno.py", line 257, in _uno_import
    return _g_delegatee( name, *optargs, **kwargs )
  File "/Developer/Projects/ooo/DEV300_m54/connectivity/unxmacxi.pro/lib/ddl.py", line 60, in 
<module>
    from com.sun.star.sdbc2 import SQLException
  File "/Developer/OpenOffice.org.app/Contents/basis-link/program/uno.py", line 295, in _uno_import
    raise ImportError( "type "+ name + "." +x + " is unknown" )
ImportError: type com.sun.star.sdbc2.SQLException is unknown
dmake:  Error code 1, while making 'runtest'
Comment 6 msicotte 2009-09-05 16:28:37 UTC
Created attachment 64565 [details]
extension built on Tiger, tested on Tiger, Leopard, Snow Leopard
Comment 7 msicotte 2009-09-05 16:29:44 UTC
Created attachment 64566 [details]
test results on Tiger, Leopard, and Snow Leopard
Comment 8 msicotte 2009-09-05 16:32:17 UTC
Created attachment 64567 [details]
added file needed to run test scripts on Mac OS X
Comment 9 msicotte 2009-09-05 16:49:44 UTC
Created attachment 64568 [details]
patch to create mac version dataaccess.xcu and changes to makefile
Comment 10 msicotte 2009-09-05 17:00:56 UTC
Tasks left to complete - how to make DataAccess.xcu for all platforms?

Test procedure:
1.  Install extension
2.  make sure postgresql is available, if you need to enter user name or
password add it to the dburl, line 86     dburl = "sdbc:postgresql:dbname=pqtest"
3.  Put all python scripts in Openoffice accessible scripts directory:
    ddl.py	
    preparedstatement.py
    statement.py
    macmain.py  
    metadata.py  
    sdbcx.py	   
    test.py
4.  Start OpenOffice.org from a shell so the script output is visible
Comment 11 msicotte 2009-09-05 17:06:32 UTC
Test procedure:
1.  Install extension
2.  make sure postgresql is available, if you need to enter user name or
password add it to the dburl, line 86     dburl = "sdbc:postgresql:dbname=pqtest"
3.  Put all python scripts in Openoffice accessible scripts directory:
    ddl.py	
    preparedstatement.py
    statement.py
    macmain.py  
    metadata.py  
    sdbcx.py	   
    test.py
4.  Start OpenOffice.org from a shell so the script output is visible
    /Applications/OpenOffice.org.app/Contents/MacOS/soffice
5.  Run the runTests script in macmain

I have tested with several OOo versions and several Mac OS X versions - results
attached above.
Comment 12 msicotte 2009-12-01 16:57:41 UTC
There was an error reported by Julian Hemmerle where a crash occurred when a
filter was applied.  This was fixed by DEV300_m60, and there is no crash in
000320_m6.  I think the attachment uploaded on Sep 5 should be regarded as a
valid port.

@Joerg - any more to do to get it on the driver page?