Skip to main content

Questions tagged [database]

A database is any organized collection of data organized to provide efficient retrieval.

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

I’ve built a backend-only wallet service using Laravel 8, and it’s fully containerized with Docker. The project handles two user roles (Players and Backoffice Agents) and provides JWT-based ...
Şirin Berhuş's user avatar
1 vote
1 answer
66 views

I have table called cash_voucher it has some columns. I want to generate voucher number based location id. I mean generates voucher numbers starting from 1 for each location For example location id is ...
Relax's user avatar
  • 141
6 votes
2 answers
200 views

I've written a converter between pydantic models of arbitrary complexity (thus, with submodels, nulls, lists) and neomodel models (library for ...
MaxiMaxi's user avatar
  • 177
4 votes
1 answer
180 views

In Drupal 11 or greater, this code is used to change the node type of a node. How would you improve the code if at all? ...
the_humble_asker's user avatar
1 vote
1 answer
140 views

I created these database tables with the inspiration in NjDevPro github repository. The design uses Closure Table for implementation of hierarchical tagging system in ...
xralf's user avatar
  • 37
5 votes
2 answers
118 views

I am a beginner programmer and have recently started learning python. I wrote this code as a little project to understand dictionaries better and ended up having to learn to use JSON. I am self-taught,...
Nav's user avatar
  • 53
7 votes
4 answers
2k views

In this program I'm defining functions to perform different tasks on a data record book for employees. Here is a summary of the code: Intro() to make the presentation of the home page. create_record()...
Abhisikta Ray's user avatar
5 votes
2 answers
722 views

I am currently working on a wallet system that allows transfers of money between users. I tried creating this as a Stack Overflow question, but it was rejected. I'm not sure if this is the right ...
vinnylinux's user avatar
7 votes
3 answers
785 views

I have been studying intermediate or more advanced data structures in Python, one of which I've decided to try out is the Tree Data Structure. I've been studying the theories as well as the ...
Raphael Irvin's user avatar
3 votes
1 answer
166 views

I have a table that tracks state changes of an entity with timestamps. The schema of the table is as follows: entityid userid originalvalue newvalue changetime 255 101 Draft Submitted 2023-11-28 12:10:...
Fatal Error's user avatar
1 vote
1 answer
65 views

I'm working on a Next.js app and looking at the best way to structure database access. With Next.js and web based apps in general, there are lots of different "server actions", aka, API ...
Will Calderwood's user avatar
2 votes
1 answer
85 views

As a side project, I'm developing a desktop app for project management, especially for students, self-employed, freelancers, etc. as a general purpose productivity tool, not from any business or ...
Prahlad Yeri's user avatar
2 votes
1 answer
87 views

I tried to create a peice of code that helps me remove duplicates from my sql database and reset the ID's as well. I am not sure that it's error proof. ...
Giannis Tsakas's user avatar
7 votes
4 answers
815 views

I'm creating a data bank of MCQ (Multi Choice Questions) and their answers so that an app can be built around it. Regarding the actual storage format, I have two ideas: An array of objects with keys (...
Prahlad Yeri's user avatar
2 votes
0 answers
75 views

I have a small SQL server database and VBA program that is used to automate tasks related to tennis students, programs, practices, performances, and student testing. I'm trying to learn db design and ...
Jason's user avatar
  • 21
12 votes
2 answers
1k views

I'm seeking a code review for the ~2000 lines of code. Makefile and tests are available at https://github.com/torrentg/logdb. I would appreciate feedback on the following aspects: Overall code ...
Gerard Torrent's user avatar
0 votes
1 answer
108 views

I am writing a C# Database connection class and I am trying to adhere to best practices and produce clean code. In the CreateAndOpenDatabaseConnection function ...
BeeFriedman's user avatar
2 votes
1 answer
83 views

This is my first time creating a non-trivial database and I was wondering what I could do better. As the title says this will be used a in toy version control system. Most of my choices feel "...
Doruk's user avatar
  • 423
1 vote
1 answer
87 views

I need to insert about 500k - 1 million data lines from a CSV file. The time of getting the reports list and insert to database by using SqlBulkCopy is very good (...
HaNgocHieu's user avatar
2 votes
3 answers
229 views

I'm trying to learn Django by building an inventory management system, here's my final models.py. I'm looking for feedback! ...
saad.sawash's user avatar
-2 votes
1 answer
68 views

I read a book named Effective SQL and found this interesting part. Enforcing and maintaining business rules and relationships in the data is part of the data model, and the responsibility belongs to ...
bear su's user avatar
10 votes
1 answer
3k views

For a school project I've created a database program in COBOL and now that I'm finished, I have to write a report on the project. As one aspect of the report, we have to discuss whether the product (...
drake14w's user avatar
  • 103
5 votes
2 answers
313 views

I'm a CS undergrad, so I don't have much experience. But while coding vanilla PHP projects, I found that I was repeating myself a lot with the CRUD operations. So overtime, I developed a single file ...
sammy medawar's user avatar
2 votes
0 answers
56 views

I have written a simple app that generates a menu in the form of a list of recipes. It furthermore generates a shopping list, given a menu, consisting of the (unique) ingredients in the recipes that ...
Michele Bolognini's user avatar
1 vote
1 answer
94 views

I am (re)writing a project management CLI and want to put it on a solid foundation concerning the database connections and testing. My focus was to build a DB class which is easy to test and could be ...
Koala's user avatar
  • 113
11 votes
4 answers
2k views

I was recently doing an assignment for a job interview, which asked to create a simple key value database with 4 command line operations: create key value: Adds a key value pair/updates an existing ...
P4PL4's user avatar
  • 111
0 votes
1 answer
103 views

Now i have a fully functional PHP codes for login and registeration i was wondering if anyone could offer improvements to the code The code: Config.php: ...
Bebo's user avatar
  • 47
0 votes
1 answer
213 views

So I've implemented the suggestions in Original question And now my code looks like this: ...
Bebo's user avatar
  • 47
2 votes
1 answer
170 views

The code below is modified slightly from the code in this previous post. I believe the code below could be improved and more secured but i don't know how so someone please show me how an improved ...
Bebo's user avatar
  • 47
0 votes
1 answer
305 views

My code is working however it seems to be using old outdated php version so less secure and I'm still new to programming so I'd be more than thankful if someone shows me how an improved updated and ...
Bebo's user avatar
  • 47
4 votes
0 answers
67 views

Note: The important chunks of code are pasted in the question but the larger representation of the app is available on GitHub. Some time ago I was tasked to create a simple FastAPI app. I did manage ...
nitwit's user avatar
  • 501
6 votes
4 answers
200 views

The code below will go through an excel spread sheet taken from kaggle, is named "SteamGames (71k games)" and the creator is "MEXWELL". inside the ...
Ellie's user avatar
  • 597
4 votes
1 answer
261 views

I want to store some 512x512 icons for my Android app in a Room database. This is so each item in a list can have all the text data along with the image data stored in a single record. The answers to ...
Adam's user avatar
  • 331
2 votes
1 answer
149 views

I wrote a script that uses an uploaded excel file to import data to the database. It checks for the image first if it can be downloaded without any error then insert the rest of the data. With ten or ...
Benjji's user avatar
  • 21
1 vote
1 answer
152 views

So I have the following relationship in my Model: Events Model: ...
Nifty Matrix's user avatar
2 votes
1 answer
93 views

I am making a plugin for Firefox, this is (more or less) my first time working with JavaScript. Is this a reasonable design for working with both values and lists in a database? ...
Emil Holmsten's user avatar
2 votes
1 answer
535 views

I connected to the websocket, and the data response in the callback function handle_message. I wish to insert all the data to influxdb using ...
tung's user avatar
  • 127
4 votes
0 answers
81 views

This might be a slightly long question, but I've recently been doing a bit of R&D on the data processing workflows within the company that I work at and it would be great to see if there are any ...
Adam Johns's user avatar
1 vote
1 answer
202 views

i am looking for an efficient way to read and append texts of .txt files to a dataframe. I currently have 10 folders with 100k documents each. What i specifically need to do is: getting the names of ...
Piergiorgio Di Pasquale's user avatar
2 votes
1 answer
102 views

I designed the following DataBaseBuffer class, to be used by different threads that generate queries and need to send them to the database. It was inspired by ...
Reda's user avatar
  • 41
4 votes
1 answer
234 views

I need to develop a database to handle muting people in an online community. The DB needs to keep track of the currently muted people. When somebody gets unmuted, that entry gets moved to an archive ...
Larry Teischwilly's user avatar
8 votes
2 answers
1k views

I was in two minds as whether to post this question on stackoverflow or dba stackexchange but because I am asking for review, I thought of posting here. I am new to Python and looking for feedback on ...
javanoob's user avatar
  • 183
0 votes
1 answer
212 views

I want to implement a crud movie library system and also some filtering capabilities. Since it is so big, I have added the link to the code. https://github.com/neslihanbozer/Movie-Library. I am aware ...
Nesly's user avatar
  • 17
0 votes
1 answer
92 views

Let's say you have a book. A book can have an author, an editor, a proof reader, or several other credits. Which credits are available should be dynamic (someone might not want to have the "proof ...
TheHvidsten's user avatar
3 votes
1 answer
240 views

My program is working properly but I'm unconfortable with code repetition. ...
Felipe Dourado's user avatar
2 votes
1 answer
150 views

I wrote this function to take database output like from PDO's fetchAll(PDO::FETCH_ASSOC) and turn it into a tree. For small datasets it works well. However, when ...
aswine's user avatar
  • 123
3 votes
1 answer
465 views

I know very little about databases and even less about how to optimize them, but I have a problem which calls for a database so here I am... I created a sqlite3 database using the following script: <...
erip's user avatar
  • 926
5 votes
3 answers
330 views

I have this DB class that extends PDO, that also has useful functions for certain tasks; I was wondering how well it's coded, and if so, what I could maybe improve on. I tried commenting in ...
Crimin4L's user avatar
  • 153
2 votes
1 answer
732 views

I am trying to hide the implementation details of accessing a Postgres database. To do this, I want to create "database" and "transaction" traits for use in a repository struct. ...
haz's user avatar
  • 255
1 vote
0 answers
70 views

Code is posted after explanation. Due to the size of the project, this is being posted in three separate posts. This also ensures each post is more focused. Post 1 of 3, Core: UPDATE 1 on Newspaper ...
eccentricOrange's user avatar

1
2 3 4 5
11