On Thu, Jul 5, 2018 at 9:04 AM, Jeremy Flowers <[email protected]> wrote: > Out of curiosity did you pip install cx_oracle recently too? I am having > issues with cx_oracle on a Amazon instance we stood up/installed today. > Yet my Python code on an older copy of Python 3.6/SqlAlchemy/cx_oracle seem > to work fine. > My error relates to a message: "positional and named binds cannot be > intermixed"
that is known in cx_Oracle 6.4, please block ==6.4 from your requirements (same for 6.3 unfortunately), my reqs look like: cx_oracle>=6.0.2,!=6.3,!=6.4 https://github.com/oracle/python-cx_Oracle/issues/199 > > On Thursday, 5 July 2018 13:09:11 UTC+1, Thinakar Samy wrote: >> >> sqlalchemy+cx_Oracle sql query has an isssue. CAn you help please? >> >> ------------------ code ------- >> from sqlalchemy import create_engine >> from sqlalchemy import MetaData >> from sqlalchemy import Table >> import cx_Oracle >> >> engine = create_engine('oracle+cx_oracle://user:passwd@FTSDBLAB') >> meta = MetaData() >> meta.reflect(bind=engine) >> tbl_mgr_theater = Table('mgr_table', meta, autoload=True, >> autoload_with=engine) >> >> connection = engine.connect() >> result = connection.execute(tbl_mgr_theater.select()) >> >> print(result.rowcount()) >> ---- code ends --- >> >> above print statement gives the following ERROR: >> -------------------------- >> Traceback (most recent call last): >> File "<input>", line 1, in <module> >> TypeError: 'int' object is not callable >> Error closing cursor >> Traceback (most recent call last): >> AttributeError: 'cx_Oracle.Cursor' object has no attribute 'lastrowid' > > -- > SQLAlchemy - > The Python SQL Toolkit and Object Relational Mapper > > http://www.sqlalchemy.org/ > > To post example code, please provide an MCVE: Minimal, Complete, and > Verifiable Example. See http://stackoverflow.com/help/mcve for a full > description. > --- > You received this message because you are subscribed to the Google Groups > "sqlalchemy" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at https://groups.google.com/group/sqlalchemy. > For more options, visit https://groups.google.com/d/optout. -- SQLAlchemy - The Python SQL Toolkit and Object Relational Mapper http://www.sqlalchemy.org/ To post example code, please provide an MCVE: Minimal, Complete, and Verifiable Example. See http://stackoverflow.com/help/mcve for a full description. --- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/sqlalchemy. For more options, visit https://groups.google.com/d/optout.
