[CONPY-158] Проблема с RETURNING Created: 2021-08-04 Updated: 2021-08-06 Resolved: 2021-08-06 |
|
| Status: | Closed |
| Project: | MariaDB Connector/Python |
| Component/s: | Other |
| Affects Version/s: | 1.0.7 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Critical |
| Reporter: | Zhan | Assignee: | Georg Richter |
| Resolution: | Not a Bug | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Ubuntu 20.04.2 LTS, Python 3.8.10 (default, Jun 2 2021, 10:49:15), mariadb 1.0.7, MariaDB 10.5.11 |
||
| Description |
|
Когда выполняю команду в Python INSERT INTO t (a, b, c) VALUES(1, 4, None), команда cursor.fetchone() возвращает Tuple. При печати объекта, показывает (<NULL>, <NULL>). |
| Comments |
| Comment by Georg Richter [ 2021-08-06 ] |
|
cursor.fetchone() will raise an exception if the previous executed command was an insert statement (and therefore didn't produce an result set). |