Re: [gnome-db] an application using libgda2



> > hi, I'm searching an application that uses libgda2 and in particular
> > gda_client_open_connection cause I'm trying (unsuccesfully) to connect
> > to PostgreSQL database.
> 	What does it happen?

I make:

gda_config_save_data_source ("postgres", "PostgreSQL",
		"DATABASE=PUB",
		"Database of PUB's Ubiquitous Beer",
		NULL,
		NULL);

gda_init("TestGDA", "0.1", argc, argv);
client = gda_client_new ();

connection = gda_client_open_connection(client, "postgres", NULL, NULL, 0);
if (connection == NULL) {
	fprintf(stderr, "Can't connect via gda\n");
	exit(EXIT_FAILURE);
}

but I get always a NULL connection.

I need an example that works, thank you :)

ciao,
Marco


-- 
.oO ::                  kpanic / muppetslab                     :: Oo.
.oO ::        online on #muppetslab at irc.freenode.net         :: Oo.
.oO :: http://www.muppetslab.org | http://ada2.unipv.it/~kpanic :: Oo.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]