wmjie / ibm-db

Automatically exported from code.google.com/p/ibm-db
0 stars 0 forks source link

ibm_db driver doesn't support Decimal Python type to insert into table #51

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
create = "CREATE TABLE decitable(DECVALUE DECIMAL(10,2))"
result = ibm_db.exec_immediate(conn, create)

insert = "INSERT INTO decitable(DECVALUE) VALUES(?)"
stmt = ibm_db.prepare(conn, insert)
result = ibm_db.execute(stmt, (Decimal("10.2"), ))
print result 

What is the expected output? What do you see instead?
expected output : True

Got: 
Exception: Binding Error:

Please use labels and text to provide additional information.

Original issue reported on code.google.com by rahul.pr...@in.ibm.com on 1 Apr 2010 at 2:48

GoogleCodeExporter commented 9 years ago
Fixed in ibm_db-1.0.3

Original comment by rahul.pr...@in.ibm.com on 9 Aug 2010 at 7:44