TypeError: Unknown data format

Andreas Jung <[email protected]> Mon, 10 May 2010 00:49:26 -0700
Newsgroups gmane.comp.python.sybase
Message-ID <[email protected]>
--===============1669266909034031274==
Content-Type: multipart/alternative; boundary=00c09f7b2c1ee6ead9048638a5ba

--00c09f7b2c1ee6ead9048638a5ba
Content-Type: text/plain; charset=ISO-8859-1

I installed Python 2.4.6 + python-sybase 0.3.9 compiled against FreeTSD
0.8.2 on a standard Linux box.

conn = connect(....)
cursor = conn.cursor()
cursor.execute('select "D_DID" from Dienstangaben')
for row in cursor.fetchall():
      print row

fails badly:

  File "test.py", line 5, in ?
    cursor.execute('select "D_DID" from Dienstangaben')
  File
"/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py",
line 546, in execute
    self._start()
  File
"/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py",
line 695, in _start
    return self._mainloop()
  File
"/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py",
line 728, in _mainloop
    self._row_result()
  File
"/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py",
line 767, in _row_result
    count = self._fetch_rows(self._bufs, logical_result)
  File
"/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py",
line 681, in _fetch_rows
    rows.append(_extract_row(bufs, 0, self.outputmap))
  File
"/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py",
line 289, in _extract_row
    row[col] = _column_value(buf[n], buf.datatype, outputmap)
TypeError: unknown data format

How to proceed?

Andreas

--00c09f7b2c1ee6ead9048638a5ba
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

I installed Python 2.4.6 + python-sybase 0.3.9 compiled against FreeTSD 0.8=
.2 on a standard Linux box.<br><br>conn =3D connect(....)<br>cursor =3D con=
n.cursor()<br>cursor.execute(&#39;select &quot;D_DID&quot; from Dienstangab=
en&#39;)<br>
for row in cursor.fetchall():<br>=A0=A0=A0 =A0 print row<br><br>fails badly=
:<br><br>=A0 File &quot;test.py&quot;, line 5, in ?<br>=A0=A0=A0 cursor.exe=
cute(&#39;select &quot;D_DID&quot; from Dienstangaben&#39;)<br>=A0 File &qu=
ot;/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39-=
py2.4-linux-x86_64.egg/Sybase.py&quot;, line 546, in execute<br>
=A0=A0=A0 self._start()<br>=A0 File &quot;/root/python-sybase-0.39/lib/pyth=
on2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py&quo=
t;, line 695, in _start<br>=A0=A0=A0 return self._mainloop()<br>=A0 File &q=
uot;/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase-0.39=
-py2.4-linux-x86_64.egg/Sybase.py&quot;, line 728, in _mainloop<br>
=A0=A0=A0 self._row_result()<br>=A0 File &quot;/root/python-sybase-0.39/lib=
/python2.4/site-packages/python_sybase-0.39-py2.4-linux-x86_64.egg/Sybase.p=
y&quot;, line 767, in _row_result<br>=A0=A0=A0 count =3D self._fetch_rows(s=
elf._bufs, logical_result)<br>
=A0 File &quot;/root/python-sybase-0.39/lib/python2.4/site-packages/python_=
sybase-0.39-py2.4-linux-x86_64.egg/Sybase.py&quot;, line 681, in _fetch_row=
s<br>=A0=A0=A0 rows.append(_extract_row(bufs, 0, self.outputmap))<br>=A0 Fi=
le &quot;/root/python-sybase-0.39/lib/python2.4/site-packages/python_sybase=
-0.39-py2.4-linux-x86_64.egg/Sybase.py&quot;, line 289, in _extract_row<br>
=A0=A0=A0 row[col] =3D _column_value(buf[n], buf.datatype, outputmap)<br>Ty=
peError: unknown data format<br><br>How to proceed?<br><br>Andreas<br>

--00c09f7b2c1ee6ead9048638a5ba--


--===============1669266909034031274==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------


--===============1669266909034031274==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Python-sybase-misc mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/python-sybase-misc

--===============1669266909034031274==--