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

learn more… | top users | synonyms (1)

1
vote
0answers
13 views

OOP PHP & PDO: Separate model from DB mapper (entity manager)

I've read that it is good to separate model from DB mapper (entity manager) (but at the end, it is perhaps personal - just a matter of opinion). Anyway, if I understood correctly, I should not have ...
3
votes
0answers
54 views

Constructing NewsArticle objects from a database table

This class seems to be able to represent the data stored in any possible database table: ...
2
votes
3answers
207 views

DataGrid Filter Method Very Slow

I'm having a lot of trouble in my Database program with trying to implement an effective DataGrid filtering method. After taking advice from a previous code review I'm trying to implement a DataModel ...
0
votes
0answers
14 views

SQLite app for local storage

When I make an app using SQLite for local storage I've settled into a nice routine; create a contract class and a extended BaseColumns class to hold column names ...
2
votes
1answer
62 views

Database Connection Program

Earlier today I asked a question as a guest (whoops) regarding my Database program. I could not comment nor post again asking for further advice from the people that answered my question. I have ...
3
votes
2answers
100 views

Database Connection Program With HR Functionality

I've started writing a fully functional Database program in C# that allows a user to access a HR system (with more systems planned in the future). I have come over to C# from Java around two weeks ...
2
votes
1answer
82 views

Customize data types in a generated model with hibernate

I have a Spring/Hibernate application with the following domain class (irrelevant code stripped for brevity): ...
1
vote
3answers
123 views

Checking user access to servers

I have pasted a method I wrote, which is too slow to my liking (easily takes 60+ seconds to execute). The method loops through 12 different servers, checks if userX has access to any of the databases ...
1
vote
1answer
61 views

Key Value Store for Android on top of Sqlite3

I wrote this simple key-value interface on top of Sqlite3 to use in my Android app. I am using this to persist Java objects as strings converted using Gson. The public API has 3 methods. ...
5
votes
1answer
68 views

Use PreparedStatement to insert into H2 database

This question is related to my question on Stack Overflow earlier today. After getting suggestions on using the PreparedStatement from Java I changed my code a ...
2
votes
1answer
36 views

Importing Excel file to a database just once

How should I rewrite an if-return-else condition in the middle of this function? ...
1
vote
1answer
72 views

PHP script to connect to MySQL database using PDO

Introduction I am preparing to use a basic script to cover how you can connect to a MySQL database using PDO. This script is meant for educational purposes (introductory class on PHP/MySQL) and does ...
2
votes
3answers
129 views

Music collection with lyric songs and instrumental pieces

I have problems with dealing with derived classes that inherit from the same base class. I have 2 types of songs: Songs with lyrics that have: Title, Tags (sad, happy etc.), lyrics (one line), ...
3
votes
3answers
63 views

Grabbing hashed password from a database

I have just discovered the beauty of prepared statements in PHP and how they protect against SQL injection. In my first time using them, I am attempting to grab a hashed password from a database and ...
3
votes
0answers
93 views

Combining pagination and non query grouping in Slick 3.0

I have the following tables: val postTable = TableQuery[Posts] val postTagTable = TableQuery[PostTags] val tagTable = TableQuery[Tags] One post can have multiple ...
10
votes
5answers
1k views

Marijuana information program

I made a simple marijuana information program in which I give the user a list of strains and give the user information about it, like: effects, medical, negatives, and its cannabis type ...
4
votes
2answers
36 views

Multiple DB record creation after a successful operation

I am working on a payment process. Upon a successful payment process, I have to create multiple records. For that, I have made this class: ...
3
votes
1answer
91 views

Versioning documents in Couchbase

I've just converted a class for versioning Couchbase documents from Java to C#, but I'm not 100% familiar with the Couchbase API so would like some feedback. The original class can be found here. ...
3
votes
1answer
31 views

Updating multiple membership plan expiration dates at once

I have model action in RequestAdmin like this: ...
3
votes
0answers
48 views

C++ PostgreSQL database driver wrapper

I am writing my own wrapper for PostgreSQL (but it can be used for other engines too). I am using this desgin: ...
3
votes
1answer
66 views

Forms - Ordered fields vs. dynamic iterations

I've made about 2 forms that have a server side action using PHP. For the first one, I made a variable for every form field and mapped it to $_POST["name"]. For ...
2
votes
1answer
51 views

Framework for comparing database objects

This code allows me to compare two complex objects, which are stored in a relational database, to see what has been removed from the objects. These objects have a unique integer primary key. They ...
4
votes
1answer
58 views

Database classes for job offers

I've recently started using PHP OOP, and I'm now working on an application where different company representatives can create job offers that candidates can look at. I have a variety of objects for ...
6
votes
5answers
688 views

Creating Original Database Algorithm--Login System

For fun, I have been making a very basic login system in Python. I was going to look up an algorithm or something for user info storage and transfer, but then decided it would be more fun to come up ...
2
votes
0answers
40 views

Phoenix Ecto schema for internal mailbox

I am building an application messaging system. I am planning on using channels for real-time notifications but I was wondering if this schema makes sense. I am looking for any constructive criticism ...
1
vote
2answers
116 views

Multi-User Roles in Laravel

I am very new to Laravel. I am building a website where multiple users can have one or more roles. I have a users table and a user_roles table. Each ...
3
votes
1answer
71 views

Transaction.atomic with continuations

I have a view that looks like this: ...
0
votes
1answer
86 views

Synchronizing two SQL Server database tables with the most recent changes to both tables

I'm very new to SQL, but I'm coding a C# program that interacts with a database. There's a master database on my computer, and there's a client database on my tablet. When I re-connect my tablet to ...
5
votes
4answers
556 views

Database adapters

I'm writing adapters for some MS Access database because I really didn't like that automatically generated code that Visual Studio was providing. Right now I just need to get data, not updating ...
5
votes
2answers
490 views

Slim API with 3 layer architecture

I'm new to Slim and the three layered approach I'm using below. So far I have the API, a Presentation layer (leaving out for now), a Business Logic Layer, and a Data Access Layer. The code's working, ...
4
votes
1answer
212 views

Key value flat file system - single header INI replacement

I'm very happy with the performance, but I always try to optimize my code as much as possible. Since I plan on using the code in production, I feel more save posting it here first. I probably missed ...
5
votes
4answers
471 views

Educational website using ASP.NET webforms

Our team is developing an educational website using ASP.NET webforms. We designed DAL & BAL classes and now I have some questions: Are DAL & BAL designed well? Would it be better using ORM ...
4
votes
2answers
158 views

C# Method to determine database status

I have a task that I am trying to complete and would appreciate direction, to know which is the most efficient path to take for future requirements. Use Case: A background process that determines if ...
4
votes
1answer
62 views

Pickling cars with simple management system in Python

This is my first Python program (before that I've been just poking around with the interpreter itself). I took this opportunity to do some user input and play around with ...
6
votes
1answer
341 views

Manage Connection Without 'using' statement

I replace this common statement: ...
2
votes
1answer
104 views

Throwing exceptions in a database wrapper

I hope the extension methods ThrowArgumentNullExceptionIfNullOrEmpty and ThrowNullReferenceExceptionIfNullOrEmpty are ...
4
votes
2answers
302 views

Library Management System

I have created a Library Management system. Can anyone please look at if see if there's any bad practices or if anything could be done better? Main.cpp ...
2
votes
1answer
51 views

Database module for node.js

This will get quite clumsy if I continue down the road with this design, so I'm asking you, enlightened ones, is there a way to make this prettier and easier to understand? Primarily the ...
1
vote
0answers
44 views

Natural join row comparison

The intent of the function is to simply tell me whether or not two vectors contain the same values that have the same column names. At this point of my algorithm I'm just checking the whether or not I ...
2
votes
2answers
103 views

Query using cross join or inner join

Please consider the following three tables that I am playing with in the image below: I want to come up with a SQL Query which shows first_name, last_name, and the total amount of all orders for ...
3
votes
1answer
181 views

CRUD (database layer) for F# with TypeProviders

I am a newbie in F# and I am thinking about use F# in my next project. The project will work the database and I need to store and retrieve instances of objects in the Db. Could you please check my ...
2
votes
1answer
102 views

Performance shifting for SQL Database and Linq memory grouping

I am messing around with shifting between stored procedures and business layer EF getting data rapidly then processing in memory. This works and on a static data range of 3 months I get execution ...
1
vote
0answers
14 views

Extend a rethinkdb query, with `if`s

I have something roughly like this: ...
1
vote
0answers
73 views

Create and access database connection

I'm working on an MVC project and I'm writing the code for get access to the database connection. I have two files: The first (PdodbLib.class.php) extends PDO: ...
2
votes
1answer
96 views

Checking for duplicate values in database with Python

I'm working on a Python application where I read and extract data from an HTML file. The data is stored in a list, and the number of items in a list is, on average, 50,000+. The items from the list ...
0
votes
1answer
109 views

Queue like system to check existence of email

I have a table in my database containing email and email_state amongst other values. Email is the email of the contact, and ...
-3
votes
1answer
100 views

Reducing database access time and connection count [closed]

I have 2 connections. How can I reduce this to one connection? ...
4
votes
1answer
177 views

Lazy Load for multiple entities at a time

We have a system with a non standard database solution. All trips to the DB are rather expensive. We cannot use entity framework. Currently our lazy loading is on an entity by entity basis. So if I ...
15
votes
1answer
256 views

Modeling a Mage character from nWoD, using Django

Goal Design a representation of a mage character from the World of Darkness RPG, as well their associated spells. Here is a visual representation of the schema. You can see it more closely ...
5
votes
2answers
603 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 ...