Questions tagged as 'sqlite3'

5
answers

How to manage a SQLite connection between multiple concurrent threads?

So I'm having some problems with my connection to SQLite, where I'm not finding a workaround. Scenery My scenario is as follows: I synchronize the data of my application with a legacy system through a WebService; Synchronization is...
asked by 20.02.2014 / 14:35
2
answers

How to ignore accents in an SQL query?

How could I perform a query by ignoring words with letters that contain accents? Word Example: Olá, é, Lógica, Pão I tried to use the collate noaccents command as follows: select c.* from Curso c where c.Descricao like '%Logica%'...
asked by 25.07.2018 / 06:02
2
answers

Prevent DROP TABLE

I would like to prevent deletions in a table in SQLite. CREATE TRIGGER nao_deletar_tabela BEFORE DELETE ON tabela BEGIN SELECT RAISE(IGNORE); END; It worked! Whenever a DELETE is executed, nothing happens. The problem and...
asked by 31.10.2014 / 12:39
2
answers

How to fix error "TypeError: must be unicode, not str" in Python?

When backing up my database in Sqlite3 , the Python interpreter returns the following message:    TypeError: must be unicode, not str on line f.write("%s\n" % linha) , I could not find a solution for this error. Follow the code:...
asked by 25.08.2015 / 19:30
4
answers

How to list all tables in a SQLite database?

In MySQL, when I run the command SHOW TABLES I can see all the tables present in a particular database. What about SQLite? How can I do this?     
asked by 15.12.2016 / 15:52
2
answers

Database in does not reflect changes in the same activity

I'm trying to update the database in my application. Trying to simulate a possible production error intentionally I give DROP to a table, and then I make a SELECT in the same table and it works. When changing Activity the same pr...
asked by 16.12.2013 / 17:14
2
answers

How can I see the structure of a table in SQLite?

In MySQL, we can use the DESC <table> command to discover the structure of a table. What about SQLite? How could I do that?     
asked by 04.01.2017 / 12:08
2
answers

Suspend Trigger via conditional

I did not find a SQL statenment IF in SQLite and the closest was CASE , which is answering me, however I would like to suspend a trigger with a conditional and I believe it can only be done with IF / p> CREATE TRIGGER... BEG...
asked by 03.04.2018 / 23:08
1
answer

Decimal values being rounded in SQLIte

After migrating my Access database to SQLite 3 in a Windows Forms application, I have been having difficulties with values of type Decimal. If you run a simple select: SELECT * FROM Item WHERE id = 1; The decimal values in the preco_item co...
asked by 18.12.2016 / 19:39
1
answer

How to write accented fields in sqlite3 via Python?

Hi everyone! I am doing a small program in python and using sqlite3 to save the database. The program is inserting, reading and deleting data in the database called "location". I would like to know if there is a way to display accented data when...
asked by 25.06.2016 / 01:55