All Questions

Filter by
Sorted by
Tagged with
0
votes
1answer
14 views

How can I determine what's a better configuration for my app? [closed]

I'm currently using Postgres 12 on AWS RDS and am using their default configuration for the database. I use a gem called PgHero that advises me to use PGTune to improve the efficiency of the database. ...
1
vote
0answers
39 views

High CPU on Unloaded Server — Performance Monitor

We recently upgraded a very lightly used SQL server (running < 5% CPU 99% of the time) from 2012 to 2016. In conjunction, we moved the server from an AWS t2 to a t3 instance and installed the new ...
0
votes
0answers
19 views

Schema design of a document-oriented database

I'm designing the database schema for a e-learning website and I'm working with a document-based database (Firestore), so I ran into a problem of design the way of structure the data in order to not ...
0
votes
1answer
23 views

Cannot restart or repair mongodb database after the crash (***aborting after invariant() failure) [closed]

After an unexpected crash, I can't restart or --repair the mongodb database anymore. While restarting the server with systemctl restart mongodb I am getting the following: 2020-09-16T20:25:23.835+...
-1
votes
1answer
25 views

Trying to find a way to get total tracks played on an album using time from another table

I have 2 tables. One has the total time an album was played in seconds. The other has the Album list with numbered tracks and song lengths in seconds. I need to show only the tracks that were played ...
0
votes
0answers
28 views

How can I update query to use GROUP BY instead of DISTINCT while still preserving ORDER BY?

Trying to make this query more performant (basically I need to have distinct speech_ids from the speech_candidate table while at the same time counting the number of duplicate speech_ids for each of ...
-1
votes
0answers
17 views

Why does PG consider “deadlock detected” an error? How do I make it not bother me with those? [duplicate]

I have now followed every advice in existence about avoiding deadlocks. It is 100% impossible. And, given that I have gone to great lengths to detect and handle such occurrences, as one is supposed to ...
0
votes
0answers
92 views

Increasing CPU count to 64 results in slower SQL Server response time [closed]

I'm running SQL Server 2017 CU 15 on a Windows 2012 R2 Azure VM. Our network admin recently upped our CPU to 64 which I understand was just a matter of enabling them as the box has 64 CPUs but we ...
0
votes
2answers
31 views

oracle - hashing method, excluding DBMS_CRYPTO

BACKGROUND: DBAs have hidden DBMS_CRYPTO package to any role, grantee, and I wonder why. I have to use wrapper instead :( Is there any way to get the same hash for the text field with the same text? ...
1
vote
0answers
57 views

Linked Server throws metadata error

I have a function in SQL Server 2019 that copies data from a local table to an Oracle 11.2.0.4 table via Linked Server, using Oracle 19.3 client. Recently, a new column was added to the Oracle table, ...
0
votes
0answers
16 views

Oracle Filter Full Transportable Backup for Schema

I need to use DBMS_DATAPUMP to make a full and transportable backup from my oracle DB for all objects related to a specific schema. I was looking for something like INCLUDE=SCHEMA:"LIKE 'SCHEMA_1%...
2
votes
1answer
124 views

Why is the ROW keyword needed when constructing a row with one element, but not two?

In PostgreSQL 11, the following expression UPDATE test_table SET ("column_a","column_b") = ('value-a','value-b') WHERE "column_a" = 'value-c' is accepted and performs ...
0
votes
1answer
34 views

ORA-01045 when attempting to connect to PDB. User has CREATE SESSION privilege, but I Oracle says they don't

The user has been granted CREATE SESSION but i can only connect to CDB and not the PDB. Why is this? I'm trying this in SQL developer. I have Oracle 19c.
0
votes
1answer
20 views

“mysqld” vs “server” in my.cnf

I used to see server-related configuration in my.cnf located under [mysqld]. However, I now come across configurations that use [server] instead. It looks like both of them are synonyms, at least on ...
0
votes
0answers
5 views

How To get cube dimension in ssas 2008r2

How To get number of dimensions from each cube in ssas 2008r2 through query?
0
votes
1answer
33 views

How to create database by Ansible with PostgreSQL?

Use this task to create a database on CentOS by Ansible - name: Create mydb database command: createdb -E UNICODE -l en_US.UTF-8 -T template0 mydb -O mydbuser become_user: postgres It will ...
1
vote
1answer
37 views

How to group by items and calculate the quantities after calculation MySQL

I have a set of order items placed in my table. These order items are generated from 2 order types. The sales order and the purchase order. One sales order can have multiple purchase orders to fulfill ...
0
votes
0answers
18 views

Mongodb TTL Index not expiring documents from collection

I have TTL index in collection fct_in_ussd as following db.fct_in_ussd.createIndex( {"xdr_date":1}, { "background": true, "expireAfterSeconds": 259200} ) { &...
0
votes
0answers
9 views

mongo replica is down

I have A mongo replica with 6 nodes, not sure why but 4 of them went down and two entered to recovery state. each time I tried to start the service of one of the down nodes it fails with error there ...
0
votes
0answers
12 views

SQL Server Persisted Computed Columns, Issues during Mass Insert or Update?

I have a database with a computed, persisted column which validates columns, checks if its an integer, and converts. Sometimes streetnumber is alphanumeric, like 5C, other times it's simply an integer....
0
votes
0answers
5 views

Merge two applications using different NoSQL databases

This is a very generic and high level set of queries related NoSQL type of datastores Imagine I have two different applications using NoSQL datastores each hosting its own document collection. ...
0
votes
0answers
40 views

Data mismatch in View2 [SELECT * from View1] with View1, how to fix?

The problem I encounter can be oversimplied as CREATE View#2 AS SELECT * FROM View#1; SELECT * FROM View#2; SELECT * FROM View#1; Then View#1 and View#2 return different results. This challenges ...
0
votes
1answer
12 views

Best practice for MySQL CASE with multiple WHEN conditions vs a single OR condition

Is there a preferred (or more performant) way of writing a CASE with multiple WHEN conditions that generate the same value? For example: SELECT CASE WHEN 1 > 0 AND 2 > 0 THEN 1 WHEN 0 ...
0
votes
2answers
31 views

Postgres group records by consecutive types

I would like to group objects by their consecutive start and end date. +----------+----------------------------+ | Fruit | Time | +----------+----------------------------+ | ...
1
vote
2answers
78 views

SQL Database size incorrect and database file growing while empty

RESOLVED - SOLUTION AT BOTTOM OF POST PROBLEM I have a database data file showing as 200GB on disk, and 200GB allocated space in the database properties. sp_spaceused also shows 200GB allocated. All ...
0
votes
0answers
29 views

Error - he given value of type Decimal from the data source cannot be converted to type bigint of the specified target column

I am very new to T-SQL. I have a query which fetches Some Always-on DB Info. I have created a table in a central server and using PowerShell I will query the AG Servers and load the data into the ...
1
vote
1answer
36 views

update most recent rows only?

I have a database of a garage of rented cars with a table called Cars with the following columns : Type,First_seen_in_garage,Last_seen_in_garage The table initially have the following rows : Ferrari,...
0
votes
1answer
14 views

Not able to restore a database with multiple backup files from Azure blob storage (block blobs)

I was testing the backup with multiple backup files (6) and I was able to successfully take backup for one of my large database (3TB) to my azure storage account by using MAXTRANSFERSIZE, BLOCKSIZE ...
0
votes
1answer
36 views

DateTime conversion fails when the datetime has seconds [closed]

This seems to be most discussed, but I could not arrive at a solution yet. I have a date format and have to add a month to it (DATEADD should not be used as my date is string initially) and finally ...
0
votes
1answer
38 views

Should an update statement query plan ever go parallel?

If an update statement's query plan does go parallel, does it guarantee a communication buffer resource deadlock, or is that determined by whether the parallel plan is using all cores?
0
votes
0answers
21 views

PostgreSQL 10 - create partitions on column that needs to be calculated after importing a csv

I am in the situation where I need to create a table which also has a time column. This table is filled with data taken from a CSV, but the csv has no time column. Only after importing the data inside ...
3
votes
1answer
22 views

Do I need to convert varchar(32) and varcha(64) to update from MySQL 5.7 to 8.0

I am upgrading a database from 5.7 to 8.0 in MySQL and ran across this: How to easily convert utf8 tables to utf8mb4 in MySQL 5.5 I understand converting the schema and tables to utf8mb4 and ...
0
votes
1answer
25 views

Search in JSON by id and name

I have this table: id number name text row for example: id name 1 {"vals":[{"id":123,"name":""}],"additional":"text"} 2 {"vals":[{...
0
votes
0answers
24 views

“any” + comprehension list in pymongo query [migrated]

I would like to write a pymongo snippet to query from a database all documents having a specific field value within a given list (so also a value which is a subset of any element in the given list). ...
0
votes
2answers
32 views

Should I put multiple related items in one field in one record or store them separately?

I'm developing a web app, something like an online dictionary. One expression might have several different meanings, for example, the word "flight" has two different meanings: a plane trip, ...
0
votes
0answers
17 views

Hybrid SQLServer 2019 Availability Group [closed]

does anyone have experience with Hybrid AGs with Azure SQL? I want to have 2 replicas on prem and 1 on Azure. Is there an actual possibility with SQL Server 2019? On that tutorial the will be expanded ...
-1
votes
2answers
24 views

How do I make PostgreSQL not log specific errors?

ERROR: deadlock detected at character 13 My PG log is full of this, but the thing is, I already handle it (after years of frustrations) in my application. I detect them and repeat until they go ...
0
votes
1answer
33 views

Limit has no effect on aggregation

I have 2 tables: users: id ------ 1 permissions: id | action | userId ---|--------|-------- 1 | read | 1 2 | write | 1 When I run the following query (return users with its permissions): ...
0
votes
1answer
20 views

Is it possible to change collation for an existing database with PostgreSQL?

Such as change from C to utf8? I tried this but seems not allowed. postgres=# ALTER DATABASE mydb SET "Collate" To 'en_US.UTF-8'; ERROR: unrecognized configuration parameter "Collate&...
0
votes
0answers
28 views

Postgresql Performance Diagnostic

I am trying to activate Performance Diagnostic on a Postgresql 12 advanced server from PEM on a windows 10 machine. I am trying to install EDB Wait States module by changing the postresql.conf and ...
0
votes
1answer
19 views

Domain of Attributes for an Entity?

I am new to DBMS and was reading about the ER Model and entities-attributes. I found the following line in the book which I was reading: The domain of Composite attributes is the cross product of ...
-2
votes
1answer
47 views

multi-part identifier could not be bound [closed]

I have 3 tables: table_a needs to communicate with table_c, but has to go to table_b first. Or put differently: table_a refers to table_b which then refers to table_c. The relationship between the ...
0
votes
1answer
35 views

Are recent versions of Oracle able to implement a queue with SKIP LOCKED?

My question: what is the very latest status on whether or not recent versions of Oracle actually make it possible to implement a queue in a straightforward way with SKIP LOCKED and limiting to a ...
1
vote
2answers
62 views

Best practices for providing PHI/PII data to users in organization

I am looking for best practices for how to share data from a SQL Server database that contains PHI/PII to individuals that cannot view PHI/PII. In short, we maintain a SQL server database that ...
0
votes
0answers
26 views

Postgres symbol lookup error : undefined symbol: ing

I have a Docker container running PostgreSQL 12, and on container start-up I had a symbol look-up error. Starting the container again failed, but rebooting the host did lead to recovery. I didn't have ...
0
votes
1answer
51 views

Buffer Latch Type 3 and Failed To Generate Checkpoint Errors

I am getting this in the log file: Time-out occurred while waiting for buffer latch type 3 for page (1:4660738) database ID 5 The database is in Full mode & logs are backing up every 15 minutes ...
-1
votes
2answers
57 views

How can Postgresql use more of the total RAM?

I'm trying to undertstand how Postgresql's (v9.1) memory usage relate to the overall Linux memory. When I look at htop, I see that the system is using about 60GB out of a total of 256GB RAM. That ...
1
vote
1answer
33 views

PostgreSQL - trying to speed up query responses from view that has join and group by

I have these two tables: precipitaion: store precipitation data at daily (freq = 'daily') and hourly (freq = 'hourly') frequencies for 7 months so far (I receive regular updates). Column | ...
-1
votes
1answer
33 views

How is the value of row column is estimated in EXPLAIN statement in mysql?

I have the following setup: create table Test(id integer, itemID integer, title varchar(100) ,PRIMARY KEY (id, itemID)); insert into Test(id, itemID, title) values(1,678, "Hello"); insert ...
0
votes
0answers
19 views

Taking InnoDB MySQL/MariaDB cold file backup and restoring on new Omeka DB

I have an unresponsive Omeka MySQL/MariaDB database on a Windows server. It is unresponsive in the sense that it will not start from the XAMPP panel: 10:44:15 AM [mysql] Attempting to start ...

15 30 50 per page
1
4 5
6
7 8
1718