Questions tagged [sqlite]

SQLite is a software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine.

Filter by
Sorted by
Tagged with
3
votes
2answers
158 views

Displaying 21 spinners to select body parts

I just wanted to ask how can I make my code a bit shorter. As of now, I have way too much code in the class. The program should display about twenty one spinners. I know it's a lot, but in this layout,...
3
votes
0answers
27 views

Login function with python and SQLite

I'm a new programmer who is currently working on a personal project. It is supposed to be a login program which stores user data in a SQLite database. I was wondering if anyone could look at my code ...
3
votes
2answers
53 views

Database Design for representing category relationships

So I am new to Databases.Recently I was asked this question in an interview where they expected me to come with a schema for storing and retrieving categories for an E-commerce website in an RDBMS. ...
7
votes
3answers
7k views

Create SQLite backups

I have this script for creating SQLite backups, and I was wondering whether you'd have any suggestions on how to improve this. I was thinking that maybe it should create the backup ...
2
votes
0answers
26 views

Uploading to DB from Excel with Pandas

I have this python script that uses pandas read an excel sheet then to update a sqlite db it works perfectly just wondering if I can speed it up as I am at about 70k lines ...
0
votes
1answer
26 views

QCombobox Case selection - Pyside2 Index via Sqlite

I have a very simple file where I have a Qcombobox Filter. When you select the filter, I run through a case on the index and output results. So, on selection I trigger: ...
4
votes
1answer
46 views

Interface class for SQLite databases

I am learning the basics about managing an SQLite database by using Python and, mainly for practice purposes, I have then defined an interface class in order to let operations on database as clear as ...
1
vote
1answer
59 views

SQLite and Python: commit once every 10 seconds maximum, and not after every client request

In a Python Bottle server using SQLite, I noticed that doing a DB commit after each INSERT is not efficient: it can use 100ms after each client request. Thus I wanted to improve this in How to commit ...
1
vote
1answer
26 views

Count distinct records in a JOINed SQL query

I have two tables with a 1-many relationship, Device and TestResult. My application has a filter builder front-end that allows a user to retrieve TestResults based on whatever filters they specify. ...
3
votes
1answer
45 views

Gold Price Tracker Web Scraper using Python

Hi I've written a web scraper for tracking gold price. Can someone please review my code and suggest improvements. It gets the price of gold from a specific url then stores the price against date in a ...
4
votes
0answers
56 views

Optimizing hundreds of millions of SQLite database inserts in Python

Some background Feel free to skip this if you're not interested. There is a very popular bioinformatics program called tabix that permits interval-based searches for genetic variants in VCF files. ...
5
votes
3answers
176 views

Simple Python and SQLAlchemy Text Password Manager

Out of boredom, I decided to start my personal project and I've chosen a simple Text Password Manager. Note: For anyone out there, I strongly recommend you NOT to use this for any sensitive storage ...
0
votes
1answer
2k views

Loop to check isNullOrEmpty then setVisibility & setText

My code below is working fine but I know it can be done more efficiently using a loop. I'm checking the VAL (such as description, ingredient2, etc.) which are Strings from my SQL lite Db to see if ...
1
vote
1answer
39 views

Scenario creator database design

I am working on moving a save system from loose files to a (spatial sqlite) database. The user places objects from a library in a 3d simulation. Scenarios are "what-ifs", what if we place 5 wind ...
5
votes
2answers
65 views

Add as newest ID to SQLite Database

At our company we use an SQLite Database to manage our Drawing IDs (CAD Drawings). The code is written in Python and I need to update it. I think the code I have has some problems, but I am quite ...
1
vote
0answers
33 views

Uses SeekBar to adjust the data displayed in UI from my Room database

I wrote code that takes the value of the progress bar in my Android app which influences what is displayed on the UI. If the user's progress bar value is above or below a certain number, data will be ...
2
votes
2answers
100 views

Optimize Multiple Insert SQLite Coming From MySQL

I'm currently developing an app that requires sending and receiving of data from android studio going to MySQL and then data coming from MySQL will be saved from the SQLite. I need advice on how to ...
2
votes
2answers
2k views

Improving SQLITE3 Left Join Performance

I occasional write simple yet long Python scripts using Sqlite3 (I'm not proficient with functional or object oriented programming... yet) Usually my Sqlite3 is blazing fast. I'm used to looping ...
3
votes
1answer
1k views

Android generic SQL database handler

Starting with the fact that creating the classic database handler in Android is really annoying and it usually takes a lot of time since you have to create one handler for each object, I thought at ...
7
votes
1answer
267 views

SQLite In-memory Database That Inserts Data Read From a CSV File

I wrote this program to make a simple in-memory database using SQLite and JDBC. Requirements I was trying to accomplish are below. It should consume a CSV file, parse the data, and insert it into the ...
3
votes
0answers
76 views

Sending push notifications to a user

I have a function whose responsibility is to send a push notification to a user. I call this function from a view in flask framework. I have read multiple articles around refactoring and good designs ...
3
votes
3answers
273 views

RAII wrapper for SQLite transactions

I'm using this nice C++ wrapper to work with SQLite3 in my project. I wanted to handle errors gracefully and automatically rollback if piece of code fails, so wrote this simple helper class: ...
1
vote
0answers
56 views

c++ sqlite3 wrapper

this is a simple wrapper for sqlite3 to make working with databases easier it isn't a professional implementation but it is much better than the raw c interface I saved much time and code using this ...
9
votes
3answers
615 views

School House Points (Python + SQLite)

I am creating a database to store house points for our school running events. I would like to be able to tally all the points for the houses and it is working fine, however, I think it may be a bit ...
2
votes
1answer
99 views

SafeBlockPopulator to ensure neighboring chunks are generated before population

Bukkit/CraftBukkit/Spigot are Minecraft server extenders that allow for creating and using plugins. A particular type of plugin is a generator, which creates the game world. Generators operate chunk-...
4
votes
1answer
90 views

Insert into SQLite3 database

I have a tsv file containing the mapping for two kinds of identifiers. ...
5
votes
2answers
2k views

OOP bank account program in Python 3

Python beginner here. Building an OOP bank account program with SQLite and starting to struggle a bit with its design. From a design standpoint I have a file (bank) which calls ATM. ATM simulates an ...
35
votes
7answers
65k views

Database design for a school system

This system has to manage students, teachers, staff and grading. This is for production and is not a school assignment. As such, please let me know if I can improve on any aspect. :) My main concern ...
2
votes
1answer
67 views

SQLite3 account creator

This program allows users to create and log into their account. The database is created using SQLite3 and the GUI is just simple tkinter boxes. I just want to know how to improve my code, organise it, ...
3
votes
1answer
18k views

Python TKinter data entry window GUI for SQLITE3 table

I would like to offer for review a simple tkinter GUI window in Python 3 to be used for data entry into an SQLite database table. As a noob, this is my first attempt at OOP and my first experience ...
3
votes
1answer
86 views

Sending and receiving of JSON data to and from Android Studio

I'm currently developing an app that requires sending and receiving of data from android studio going to MySQL and then data coming from MySQL will be saved from the SQLite. I need advice on how to ...
5
votes
2answers
491 views

Python update SQLite DB Values

At the moment I try to get used to SQLite and Python. I started with insert, select and so on. But now i want to get a bit further. Now I have a DB with 200 rows for testing and in want to update two ...
2
votes
0answers
47 views

Database code for Python-based URL shortener

I had implemented a URL shortener with Python and a database. Please review the database part of the code. The idea is to create an MD5 hash of the URL in question and then store it in a database. The ...
4
votes
1answer
106 views

Uploading songs from website to database and then to Spotify

My Python program parses songs from a website, corrects song titles and artists with the Last.fm API, searches for the spotify uri using the Spotify API, stores all the information in a SQLite ...
1
vote
1answer
37 views

Database as a config and class structure to call it

I have question regarding best practices. I've decided instead having config inside either app.config or xml file to have my config file inside SQLite file database. This config will contain basic ...
2
votes
0answers
158 views

Python CLI app for tracking budget

I'm making a CLI app for myself for tracking my budget. How can I improve this code? ...
3
votes
2answers
1k views

Simple one time pad cipher

I had this idea not to long ago on creating a secure chat for people who need to be not meddled with when talking (like whistleblowers, hackers, etc) talking to one of my friends about it he said I ...
4
votes
0answers
109 views

Perl PasteBin scraper

I'd like to optimize my code and get a better of understanding of how I can perform the task I am doing better. I've only used Perl threads about 3 or 4 times now. The purpose of my script / code ...
2
votes
0answers
519 views

Simple web API that access sqlite database

This is a very simple web API for a school assignment, as a part of a bigger system. The web API returns a list of courses or a single course as json. I doubt that I will get any feedback on the code ...
3
votes
0answers
2k views

Structure and Implementation of Generic Repository and Unit of Work patterns with Dapper and SqlTransactions

I am attempting to update some legacy code that I work with, but my knowledge of data access is limited to a basic use of Entity Framework and simple Dapper. After some research, I have a loose ...
0
votes
1answer
212 views

Android SQLite database with 3 tables

I want to show you the SQLiteOpenHelper and Contract class for a little quiz app I made for practicing purposes. I have 3 tables ...
2
votes
1answer
80 views

Iterable and .db file searcher that imports data

This Program is a tool that allows me to import data from files that may not be easy to read just by opening; such as .db files which are wayyyyy to hard to understand just by opening the file in ...
3
votes
3answers
7k views

SQLite helper class

I have recently implemented my SQLite helper class that supports SQLite in a memory class to be opened to not to be lost. Please review it and tell me if there is a coding problem and tell me what to ...
5
votes
1answer
3k views

SQLite Database inserting + Unit tests in Java

Genereal Introduction This is my first project which involves a Database which involves testing (especially unit testing) where the quality is really important for me. The long term aim is to ...
3
votes
1answer
138 views

Shell script for reading /etc/passwd into SQLite

I want to read 4 columns, namely UID, GID, username and home directory of specific users from /etc/passwd into an SQLite database. I found this to create many ...
1
vote
0answers
161 views

Extracting data from a used car sales site

I am developing code for extracting data from a used car sales site. There are 4 sites in total. In 3 of them I use requests and beautifulsoup. The time taken to extract data from these sites was ...
7
votes
1answer
466 views

Importing XML dump of Stack Overflow questions and answers into SQLite3

I have a 60gb+ XML file and, as you can see, I am using a Python script to extract the data and execute 'INSERT' statements to update my database. Being that the file is so large, will I run into ...
3
votes
1answer
58 views

SQLiteOpenHelper for multi string tables

I wrote this simple SQLiteOpenHelper in order to use in one database various tables containing String records (each record having a String identifier, and ...
1
vote
1answer
973 views

C++ SQLite insert statement

I insert a value into a SQLite database and return the id of the last inserted value as a result of the method. I asked a question on Stackoverflow and I found this solution to my problem. Now I ...
5
votes
2answers
483 views

Searching for a word in a list of tuple extracted from a db via SQL

Python 3.6 and Sqlite3. I have a database with something like 300K entries, each entry has several fields (date, username, etc) and a "text" one. I have a list of 200 words and for each word i have ...