Unix Technical Forum

Re: Reg:Connection Object

This is a discussion on Re: Reg:Connection Object within the pgsql Admins forums, part of the PostgreSQL category; --> I hope, U can have a structure that have members as the "user name" and the "Connection object". Whenever ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Admins

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-10-2008, 05:12 AM
Manikandan C
 
Posts: n/a
Default Re: Reg:Connection Object


I hope, U can have a structure that have members as the "user name" and the "Connection object". Whenever a new connection is made, U can create instances of this structure. Based on the user name, you can pass the appropriate instance to the function.

Hope this will help you.
Is this what you want?

Regards,
Mani

-----Original Message-----
From: pgsql-admin-owner@postgresql.org
[mailtogsql-admin-owner@postgresql.org]On Behalf Of Michael Fuhr
Sent: Friday, September 02, 2005 11:29 AM
To: sandhya
Cc: Askar Zaidi; postgre
Subject: Re: [ADMIN] Reg:Connection Object


On Fri, Sep 02, 2005 at 11:19:53AM +0530, sandhya wrote:
> In case of multiple users what will happen?
> Each must have different connection objects right!


That's why global variables are bad. But what's wrong with passing
a PGconn * to various functions? If that's a problem in your
application then please explain why; it's still not clear what
difficulties you're having. Perhaps it would help if you posted a
simple but complete example program that shows what you're trying
to do.

As I mentioned before, this thread is off-topic for pgsql-admin;
it would be more appropriate in pgsql-interfaces or pgsql-general.

--
Michael Fuhr

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 07:09 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com