904
Comment:
|
1221
|
Deletions are marked like this. | Additions are marked like this. |
Line 33: | Line 33: |
{{{ cursor = session.sql ("select * from messages") for msgno, lang, text in cursor: print msgno, text |
|
Line 34: | Line 38: |
* session.sql (...) -> Result''''''Set * session.prepare (...) -> Prepared''''''Statement * prepared.execute ([...]) -> Result''''''Set |
insert = session.prepare ("insert into sometable values (?, ?)") print insert.getDescription () insert.execute (["string", 1]) |
Line 38: | Line 42: |
select = session.prepare ("select * from messages where msgno < :msgno") cursor = select.execute ([200]) print cursor.next () print cursor.relative (100) print cursor.absolute (4) print cursor.absolute (-4) }}} |
Masthead
- URL
- licence
- GPL
- platforms
- Linux/i386, Solaris, HP-UX, AIX, Dec, Windows
DB API 2.0 Drivers
sapdbapi
- URL
- licence
- LGPL
- platforms
- see SAP DB
- Python versions
- 1.5.2 - 2.2
Extensions to DB API
Comments
Other Drivers
sapdb
- URL
- licence
- LGPL
- platforms
- see SAP DB
- Python versions
- 1.5.2 - 2.2
Programming Model
cursor = session.sql ("select * from messages") for msgno, lang, text in cursor: print msgno, text insert = session.prepare ("insert into sometable values (?, ?)") print insert.getDescription () insert.execute (["string", 1]) select = session.prepare ("select * from messages where msgno < :msgno") cursor = select.execute ([200]) print cursor.next () print cursor.relative (100) print cursor.absolute (4) print cursor.absolute (-4)
Comments
Supported Python Applications
- a sapdb driver exists for ["PyDO"] (Python Data Objects)
Pros