agrosner / DBFlow

A blazing fast, powerful, and very simple ORM android database library that writes database code for you.
MIT License
4.87k stars 598 forks source link

deleted row from a SQLite table is still there when i open it again #1677

Closed johnj44 closed 5 years ago

johnj44 commented 5 years ago

ISSUE_TEMPLATE

DBFlow Version: SQLite (python)

Bug or Feature Request:

Description: I made a table with four rows and want to delete forth row from the table. every thing is OK because when I check it in the following code it has disappeared but when I open it again by "DB Browser" or by using SELECT operator in another code, it still there and appears again.

import sqlite3 conn = sqlite3.connect('test.db') print ("Opened database successfully") conn.execute("DELETE from COMPANY where ID=4;") conn.commit print ("Total number of rows deleted :", conn.total_changes) cursor = conn.execute("SELECT id, name, address, salary from COMPANY") [print(row) for row in cursor.fetchall()]
print ("Operation done successfully") conn.close()

It's DataBase: test.zip