Category "database"

Room database RawQuery() is not work on "IN" and "NOT IN" clause

I have my one table like UserTable. @Entity public class UserTable{ @PrimaryKey(autoGenerate = true) private int userId; private String userName;

Postgres TypeORM - FK to PK that is also FK to another table - constraint error

In my NestJS application with postgres db I have these 3 entities: User, Writer, Book and a class named UserBaseEntity. export class UserBaseEntity { @Prim

DBMS ERD Design

I am planning out an application's database. I have an employee table. I want to store every employee's education degree. Adding an education column to the empl

how to display columns in specific order, according to field value in MS Access

I want to display a query but the column order needs to be sorted according to the value in the column, field with greater value as column 1, then second greate

How to import database from odoo 14 to postgresql?

I am trying to take a backup from Odoo enterprise 14 through query. When I try to export the dump file I get this message Can anyone guide me, how to export all

how to avoid long sql in clickhouse

As ClickHouse can run complex SQL efficiently, we now write hundred-lines-in-one SQL to get the real time analysis results(join lots of source table). And it br

How would YouTube store data of who liked which videos?

If Youtube uses MongoDB as their database, then how would they store the who liked which videos information? Option 1: Store it in the Videos collection with a

Selecting rows with id's from two other tables

Let's call this table service_status: +---------+----------+-------------+------------+ |service_id| output | created_at | updated_at | +---------+--------

SQLite-net-pcl Comparing Dates

As stated in the question I am attempting to do a date comparison for tasks that are done within a specific date range. My model has a boolean called "Done" and

Bug in Weaviate - Update data object instance (Python Client)

I have a Weaviate instance running (ver 1.12.2) I am playing around with the Python client https://weaviate-python-client.readthedocs.io/en/stable/ (ver 3.4.2)

PreparedStatement getMaxRows always returns 0

So i have a problem where i want to see how many rows there are in my database, after i've made an update. Im trying to use "GetMaxRows" but it always returns 0

Wordpress Multisite installation issue on staging website

I am trying to change my website into multisite on my staging server. When I add define('MULTISITE', true); in wp-config.php on my local machine setup, it works

How to delete a record depending on the following record

I have a table with the following columns Car | User | Location | Time | Type The type can be 'OUT' if the user's request to rent the car is accepted

Laravel 8 how to join many to many relationship tables and create a query using DB

I am using Laravel 8 and I want to display list of event by joining tables that have many to many relationship. Here is how my tables look: Users Table | id |

How to store attachment file in an email in a database?

I used this code to store attachment xlsx files from a specific address email in Outlook, but now I would like to store these files in a database in SQL Server,

Sqlite3 recover runs into out of memory error

I'm trying to recover a broken sqlite database using the recover feature of sqlite3.exe: sqlite3.exe borken.db ".recover" | sqlite3 fixed.db The broken databas

Import CSV file (convert to JSON format) into Deta Base (database)

I try to convert the CSV file into JSON format and import it into Deta Base (database). Here is a main.py code I run from a terminal. No error shows up, but Det

Database schema design optimized for scoring rows to sort on

I want a table like this which has scores column, and whenever basket1 or basket2 are added to table I want to update scores of the columns in basket.So say bas

My php code loops and doesn't explore my database [duplicate]

Hello I'm currently trying to create a page based on a database under mysql that would update itself for a client. However what I'm trying to

how to modify already defined composite key in liquibase

I need to alter a table to modify the order of the indexes created from the composite key for the below mentioned changeset. <changeSet author="demo (generat