Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

TCL/TK, PostgreSQL and pgaccess (on X11)

25 views
Skip to first unread message

daniellewis

unread,
May 26, 2005, 2:15:15 PM5/26/05
to
Hello,

I'm quite new to postgreSQL, pgaccess and TCL/TK... Here is my
scenario:


PROBLEM 1:
I'm running X11R6 on Apple X11 (on OS X 10.3.8), I want to run pgaccess
(which I have version 0.98.7 from http://ns.flex.ro/pgaccess/ ). I have
PostgreSQL (Version 8.0.1). I installed from fink; tcl/tk 8.4.1-12, and
changed the pgaccess bash script to read wish8.4. I tried to run this
and I go the following error:

Application initialization failed: no display name and no $DISPLAY
environment variable
Error in startup script: invalid command name "image"
while executing
"image create bitmap dnarw -data {
#define down_arrow_width 15
#define down_arrow_height 15
static char down_arrow_bits[] = {
0x00,0x80,0x00,0x80,0x0..."
(file "/usr/local/pgaccess/main.tcl" line 5)

Thats my main problem.

PROBLEM 2:
I tried to fix this by downloading Tcl/Tk Aqua (TclTkAquaBI-8.4.9.1 for
Mac OS X 10.3 and later only). When I tried to load the main.tcl script
for pgaccess I got the following error:

"Error: dyld:
/Library/Frameworks/Tk.framework/Versions/8.4/Resources/Wish
Shell.app/Contents/MacOS/Wish Shell can't open library libpgtcl.dylib
(No such file or directory, errno = 2)"

With the following details:

dyld: /Library/Frameworks/Tk.framework/Versions/8.4/Resources/Wish
Shell.app/Contents/MacOS/Wish Shell can't open library: libpgtcl.dylib
(No such file or directory, errno = 2)

dyld: /Library/Frameworks/Tk.framework/Versions/8.4/Resources/Wish
Shell.app/Contents/MacOS/Wish Shell can't open library: libpgtcl.dylib
(No such file or directory, errno = 2)

while executing
"load libpgtcl[info sharedlibextension]"
(procedure "main" line 3)
invoked from within"

I have a feeling that this is something to do with the User, I should
be logged in as postgres.

Any help will be appreciated... as I have to learn PostgreSQL for work,
which I start in two weeks time.

Thanks again.

Daniel Lewis

bs

unread,
May 26, 2005, 2:49:13 PM5/26/05
to
I have no clue about Mac, but in a typical unix environment, the error
message you got from your first problem is due to the application not
being able to find a display to use. Usually, this happens when you are
in a console as a different user than what was logged in as. You can
try:

export DISPLAY=:0.0

you might have to give permissions as well using "xhost"

As far as your second problem, is there a reason you are using the
(very) old version of pgaccess? For the last few years, the web page
has been www.pgaccess.org, and you can download more recent versions
from http://sourceforge.net/projects/pgaccess

hth,

--brett

Kevin Walzer

unread,
May 26, 2005, 9:02:55 PM5/26/05
to
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

You may also want to see this page:

http://www.wordtech-software.com/pgaccess.html

I've packaged an Aqua-native verison of PGAccess.


- --
Cheers,

Kevin Walzer, PhD
WordTech Software--Open Source Applications and Packages for OS X
http://www.wordtech-software.com
http://www.smallbizmac.com
http://www.kevin-walzer.com
mailto:s...@wordtech-software.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFClnG+JmdQs+6YVcoRAs/QAJ9DrpzgeLrxadDuRLsLmLZZa7z1IQCbB07B
PuI0FBf04TYfJtXj1yUN2xA=
=E2IO
-----END PGP SIGNATURE-----

daniellewis

unread,
May 28, 2005, 7:32:28 PM5/28/05
to
Thanks,

I have had an email from someone about PgEdit ( http://www.pgedit.com/
) and I shall also have a look at PgAccessOSX (
http://www.wordtech-software.com/pgaccess.html ).

Daniel Lewis

------------------------------------------------------------------------------------------
Daniel Lewis
* Software Engineering Student @ Oxford Brookes University
* Analyst Programmer
* Fuzzy Theorist
* Brookes Computing Society President
* ACM Student Member
------------------------------------------------------------------------------------------
e: 0310...@brookes.ac.uk OR danie...@acm.org
w: http://www.brookescomputingsociety.org/

Marc Dellinger

unread,
Jun 4, 2005, 4:39:46 AM6/4/05
to
Le Thu, 26 May 2005 12:15:15 -0700, daniellewis a écrit :

> Hello,
>
> I'm quite new to postgreSQL, pgaccess and TCL/TK... Here is my
> scenario:
>
>
> PROBLEM 1:
> I'm running X11R6 on Apple X11 (on OS X 10.3.8), I want to run pgaccess
> (which I have version 0.98.7 from http://ns.flex.ro/pgaccess/ ). I have
> PostgreSQL (Version 8.0.1). I installed from fink; tcl/tk 8.4.1-12, and
> changed the pgaccess bash script to read wish8.4. I tried to run this
> and I go the following error:
>
> Application initialization failed: no display name and no $DISPLAY
> environment variable

seems like you mix Terminal.app and X11

You don't need X11 to run pgaccess. You should have a file named vtcl
which should be like this:

#!/bin/sh

PATH_TO_WISH=/usr/bin/wish
VTCL_HOME=/usr/local/vtcl-1.5.2
export PATH_TO_WISH
export VTCL_HOME
exec ${PATH_TO_WISH} ${VTCL_HOME}/vtcl.tcl $*

Then you can run it either from Terminal.app or Terminal in X11 (i.e.
xterm). If you want to use Tcl/Tk from Fink, then you have to set
PATH_TO_WISH accordingly (then use xterm in X11).
Hope this help
Marc

Marc Dellinger

unread,
Jun 4, 2005, 5:02:04 AM6/4/05
to daniellewis

Sorry, but I mixed vtcl and pgaccess. But it is the same thing. To run
pgaccess from Apple's Terminal, use the following

let say you make a file named pgaccess (in your pgaccess folder) like this

#!/bin/sh
PATH_TO_WISH=/usr/bin/wish
PGACCESS_HOME=/usr/local/pgaccess
export PATH_TO_WISH
export PGACCESS_HOME
exec ${PATH_TO_WISH} ${PGACCESS_HOME}/pgaccess.tcl $*

Then it should work
Marc

0 new messages