From: brian z. <bz...@us...> - 2002-03-29 04:01:06
|
Update of /cvsroot/jython/jython/com/ziclix/python/sql/pipe/db In directory usw-pr-cvs1:/tmp/cvs-serv26901/com/ziclix/python/sql/pipe/db Modified Files: DBSource.java DBSink.java Log Message: cursor is now file-like Index: DBSource.java =================================================================== RCS file: /cvsroot/jython/jython/com/ziclix/python/sql/pipe/db/DBSource.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** DBSource.java 20 Nov 2001 04:55:18 -0000 1.1 --- DBSource.java 29 Mar 2002 04:01:03 -0000 1.2 *************** *** 88,92 **** return this.cursor.fetchone(); } else { ! this.cursor.execute(this.sql, this.params, Py.None, Py.None); PyObject description = this.cursor.__findattr__("description"); --- 88,92 ---- return this.cursor.fetchone(); } else { ! this.cursor.execute(Py.newString(this.sql), this.params, Py.None, Py.None); PyObject description = this.cursor.__findattr__("description"); Index: DBSink.java =================================================================== RCS file: /cvsroot/jython/jython/com/ziclix/python/sql/pipe/db/DBSink.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** DBSink.java 11 Jan 2002 21:46:01 -0000 1.2 --- DBSink.java 29 Mar 2002 04:01:03 -0000 1.3 *************** *** 25,29 **** /** Field sql */ ! protected String sql; /** Field exclude */ --- 25,29 ---- /** Field sql */ ! protected PyObject sql; /** Field exclude */ *************** *** 56,60 **** super(connection, dataHandler, tableName); ! this.sql = null; this.rows = new PyList(); this.bindings = bindings; --- 56,60 ---- super(connection, dataHandler, tableName); ! this.sql = Py.None; this.rows = new PyList(); this.bindings = bindings; *************** *** 154,158 **** } ! this.sql = sb.toString(); } --- 154,158 ---- } ! this.sql = Py.newString(sb.toString()); } *************** *** 162,166 **** public void row(PyObject row) { ! if (this.sql != null) { if (this.batchsize <= 0) { --- 162,166 ---- public void row(PyObject row) { ! if (this.sql != Py.None) { if (this.batchsize <= 0) { |