On Tue, May 13, 2008 at 11:17 PM, [EMAIL PROTECTED] <[EMAIL PROTECTED]>
wrote:
> On Tue, May 13, 2008 at 11:12 PM, [EMAIL PROTECTED] <[EMAIL PROTECTED]>
> wrote:
>
>> On Tue, May 13, 2008 at 10:16 PM, Anand Chitipothu <[EMAIL PROTECTED]>
>> wrote:
>>
>>>
>>> >>>> import web
>>> >>>> db=web.database(dbn='postgres', user='XX', pw='YY', db='ZZ',
>>> host='HH')
>>> >>>> db._ctx
>>> > <Storage {}>
>>> >>>> db._db_cursor()
>>> > Aborted
>>>
>>> try setting
>>>
>>> web.config._hasPooling = False
>>
>>
>
> >>> import web
> >>> web.config._hasPooling=False
> >>> db=web.database(**DB_CONFIG) # DB_CONFIG has db settings
> >>> db.hasPooling
> False
> >>> db._db_cursor()
> Aborted
>
psycopg2 works alone by itself... problem comes when using with web.db...
>>> c=psycopg2.connect("dbname='XX' user='XX' host='XX' password='XX'")
>>> cur=c.cursor()
>>> cur.execute('select * from users limit 1')
>>> rows=cur.fetchall()
>>> rows
[(713351, None, None, None, None, None, None, None, None, None,
datetime.datetime(2008, 1, 20, 2, 56, 55, 603511), None, None, None, None,
None, None, None, None, None, None, None, 0, 0, 0, 0, None, None, 0L, True,
0, None, 1, 0, 0, 0, 0, 0.77629595901817094, 0, 0, 567715174, 0, 0, 0, None,
None, 0, 0, 0, None, '2c62c3a30aa838b2b395b1a6-567715174', 0, 0, None,
'Bonnie Rose Buchart', True, None, None, False, True, False)]
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web.py" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---