#57 ✓ resolved
Psycopg website

Error on processing placeholders with negative integer

Reported by Psycopg website | May 29th, 2011 @ 10:44 PM

Submitted by: nk.0@ya.ru (Konstantin Nikitin)

Here is my error log

import psycopg2 connection = psycopg2.connect("user=konstantin dbname=konstantin") cursor = connection.cursor() cursor.execute("select 1-%s from table", (2, )) cursor.fetchall() [(-1,), (-1,), (-1,), (-1,), (-1,), (-1,), (-1,), (-1,)] cursor.execute("select 1-%s from table", (-1, )) cursor.fetchall() [(1,)] cursor.execute("select 1 - %s from table", (-1, )) cursor.fetchall() [(2,), (2,), (2,), (2,), (2,), (2,), (2,), (2,)]

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Psycopg is the most used PostgreSQL adapter for the Python programming language. At the core it fully implements the Python DB API 2.0 specifications. Several extensions allow access to many of the features offered by PostgreSQL.

Shared Ticket Bins

People watching this ticket