All Questions

Filter by
Sorted by
Tagged with
0
votes
0answers
4 views

Azure ARM template SQL backup deployment intermediate failure

I am having an intermittent error when trying to deploy a backup solution during provisioning. The error I get sometimes is: Deployment failed. Correlation ID: bb100978-3c7b-46f4-bcca-8b9abb490a98. {...
1
vote
0answers
12 views

Prevent updating table using procedure in different database

This is my scenario: Windows User Gabe has db_owner access of database DB1. Windows User Gabe has db_reader on database DB2. When the user executes UPDATE DB2.dbo.Tbl1 SET X = 1, they get "The ...
0
votes
0answers
5 views

RDS MySql replica db no longer updating. Bonus: AWS Newbie tips?

Hello all and thank you for your help, I'm in quite a pickle here. I've been put on a project to fill in for someone who is swamped for time, so I'm not super familiar with the setup of everything ...
7
votes
1answer
39 views

Hash aggregate bailout

A question that arose in a chat discussion: I know hash join bailout switches internally to a sort of nested loops thing. What does SQL Server do for a hash aggregate bailout (if it can happen at ...
0
votes
0answers
9 views

Best database for indexing

I am using an elastic cluster to store a few hundred GBs of data. Sometimes, I have to make searches on the data in the form of 3rd level indexes. Let's say that I have a table of gender, age, past ...
-1
votes
0answers
11 views

Does anyone have experience with RedGate SQL Provision? [on hold]

My company has about 8 TB worth of "Production" databases (7 differrent databases total) that we would like to be able to restore to lower environments. At the same time we have HIPAA data that needs ...
0
votes
0answers
33 views

Login connection data and time

I wonder if there is a way to query SQL Server to find out dates and times a login has connected to a particular server?
5
votes
3answers
69 views

Using SPID in DB Tables (instead of Table Variable)

Transactional database used for booking things... Our vendor was asked to replace #temptables with @tablevariables (because of heavy compile locks) but instead they replaced with an actual table ...
0
votes
3answers
42 views

Must declare the scalar variable question

That is my first post here, need helps: in a stored procedure I had some following code CREATE PROCEDURE [dbo].[SP_getAvg] ( @projectId INT ,@carrierId INT ,@fetchType VARCHAR(20) ) ...
0
votes
0answers
9 views

Mysqldump is not exporting the full table (phpmyadmin and sqlyog neither)

When I export the table from PhpMyAdmin it downloads a .sql file with just a small part of the database (like 2 or 3% my table is 84M rows) I have tried with SQLYog and mysqldump with a similar result....
0
votes
0answers
46 views

slow join performance SQL Server

I am struggling a bit to improve performance on one of my queries. What i had is basically all of those 4 tables for reporting without any indexes,pks etc. I was thinking that if i copy them (even on ...
1
vote
2answers
22 views

SQL Server - Update with Output not working in Parallel environment

I know that the output parameter does not guarantees parallelism logic. And the logic I want to implement is failing in a multi thread environment. To test this, just open 2 windows and execute them ...
0
votes
0answers
6 views

How to mongodb stitch webhook service with any content-type [migrated]

I have to create the webhook API to get the POST request from the external server. They are sending the details with Content-Type:application/x-www-form-urlencoded. But I dont see any option to change ...
1
vote
0answers
32 views

Group by equidistant integer intervals

I am using TimescaleDB (an extension to PostgreSQL) to store altitude data from a GPS sensor. The table looks like: CREATE TABLE IF NOT EXISTS altitude ( time TIMESTAMPTZ NOT ...
1
vote
2answers
31 views

Virtual Environment for learning [on hold]

I am a new DBA and my friend told me the best way to learn about becoming a DBA is to setup your own server (virtually or physically). I don't have a spare machine laying around so I will need to set ...
-1
votes
1answer
18 views

What is the fastest way to remove a key from a jsonb column of Postgres?

I have a table of 10K rows in projects table. Deleting a key using the following operation never finishes. UPDATE projects SET misc = (misc - 'foo'); Is there anything I can do to make it faster? ...
0
votes
1answer
23 views

Copy Data from Two different databases with FK relation

So the situation is as follow: I have production DB called DB1 which has huge data, around 250 GB. I have Test DB called DB2 on my local machine which has the same schema as the production DB but ...
0
votes
0answers
8 views

How to query Groupy by and count with lookup in Mongodb?

I am trying To use group by in a collection and COUNT in another collection. I have 2 collections. One for customer and other for order_fact. Example Sample data for collection customer. {"Id_Cust":...
0
votes
2answers
29 views

SQL Server: Join all tables from a table listing their names [duplicate]

I have a table that contains a list of metrics and their IDs in the format: L6Metrics | ID | Name | -------------------------- | 734 | L6A_Velocity | | 736 | L6B_Velocity | | 738 ...
0
votes
0answers
12 views

Postgres, use via elasticsearch, in php, how to? [on hold]

What is the simplest way to use elasticsearch for postgresql, for example for searching on the web in php? I browse internet for 2 days, but I still don't understand how is elasticsearch exactly ...
0
votes
1answer
12 views

cron command running postgres at high cpu [on hold]

I can see that a cron command is running under a postgres user and killing the CPU but I have no idea how it's being executed or how to stop it !
2
votes
2answers
23 views

Restore DIfferential backup on azure managed instance?

I am migrating my database from on-premise to Azure managed instance. In order to move the database I'm using the organization weekly full backup, and I am asking them to take a diff after they take ...
0
votes
0answers
51 views

SQL Server Query Timeout with NOT IN clause but IN works fine

So were using SQL Server 2016 Enterprise and suddenly have an issue with a query on the Production server. Works fine on Test and Dev and if we backup and restore the production DB to either of ...
1
vote
0answers
29 views

Which permission is required for OBJECT_ID to return non-null value

Firstly, yes, I know I've tagged this 2008, but unfortunately that is a requirement under this particular project I'm working on. This is a rather complex setup, so please bear with me... there are ...
0
votes
1answer
14 views

Create table in Postgresql locks pg_class forever

Hye, I have a Postgresql cluster with few databases. In one of the DBs, if I try to create a new table, the command is never ended until I kill the the linux proccess. I checked pg_lock and found ...
5
votes
1answer
60 views

pg_ctl hangs over ssh

I am designing a process to test my postgresql 10.8 backups by restoring them to a random point in time in a throwaway virtual machine. I have been unable to fully automate the process though. I am ...
0
votes
0answers
10 views

What it is better to choose for installation of postgresql - debian or ubuntu? On base big loading [on hold]

I have a big Postgres database on Windows the server. 200 GB, are a lot of different requests. I plan migration this base to Ubuntu. What distribution you recommend to use? Ununtu 18.04 or Debian 9/...
0
votes
0answers
14 views

Mysql removing null value rows from column [on hold]

I want to remove null values only from column and not a table because I find suggestions to remove from values from table.
1
vote
1answer
17 views

Does AE certificate include both master and encryption keys together?

After setting up Always Encrypted, I can see a certificate in my Current User when selecting select * from sys.column_master_keys under the key_path I see this location, but there is no location ...
1
vote
0answers
11 views

Aggregation vs Ternary relationship - When to use?

I am reading a book about database systems and in the chapter covering database design using ER, the author aims to explain when to use aggregation versus ternary relationship. In short, each Project ...
0
votes
1answer
28 views

Indexes for combined time and location data

I have a multi-TB table with geolocation data for a certain item id and timestamp. It is partitioned by time with a partition for every month (~500GB), and clustered (including the partitions) on the ...
0
votes
2answers
36 views

Get value from one field, and paste it in to a new column

I'm relatively new to Microsoft Access, and just a beginner with SQL programming. I have a table in MS Access. It is an import from a .txt file. In the first column There is a String with a Number or ...
1
vote
1answer
18 views

Facing permission error while trying to execute a stored procedure published through CLR

I've created a stored procedure using SQL CLR c# stored procedure in Visual Studio 2017 and I've published it in MSSQL Server. Now I can see my stored procedure, but I face this error when I want to ...
0
votes
2answers
19 views

Get matching part from conditional pattern

I'm having a table like this: |id|key |value | ------------------------ | 0|name |Homer | | 1|surname|Simpson | | 2|town |Springfield| I'm running this query: SELECT * FROM ...
0
votes
0answers
13 views

Search for partial and full matches in two tables

I have two tables users and products: 1) users: id | username | ... | ---------------------- 1 | name1cat | ... | 2 | cat | ... | 3 | name4 | ... | 4 | test | ... | 2) ...
-1
votes
2answers
46 views

Expand range of values in SQL [on hold]

I have a table named "codes" where some of the entries will be as shown below. Code Description ----------------------------- 123[10-50]% ABC 433[10-500]% PQR I have to ...
0
votes
0answers
13 views

How to make related functions and procedures into one unit in mysql

I want to make related procedures and functions into single unit like packages in sql and access from that like PackageName. Function() in mysql Is it possible in MySQL if so explain with simple ...
1
vote
0answers
19 views

Oracle Materialized View - Is it Safe to Use Only ROWID as Record Identifier?

this is a question related to Oracle 12c. I'm currently trying to create MVs as data sources for Golden Gate replication. We need fast refresh because We have to replicate 60,000 rows + at one time ...
1
vote
2answers
37 views

How to verify the restored MS SQL DB from Backup matches with the source?

Once you restore the backup, how do you verify that the source and destination are in sync (schema, datatypes, number of records etc)? assuming that the source has not change. Appreciate your insights....
0
votes
0answers
12 views

Nested Sum if statement with DateDiff

Problem: Need to account for delays in review process. The field "EC2WL" is when an employee submitted a case to the Work Leader for review and the field "WL1stReview" is when the Work Leader first ...
1
vote
1answer
57 views

Run a stored procedure only the last 3 days in a month

How can I run a stored procedure only the last 3 days of a month using a T-SQL script?
1
vote
2answers
20 views

Connection pooling - NodeJS or Database products?

Consider the mysql package. The description covers connection pooling thus, Rather than creating and managing connections one-by-one, this module also provides built-in connection pooling using ...
0
votes
1answer
26 views

is “create schema” the same way of saying “create database”?

I'm a beginner in DBMS, sorry if my question sounds dumb. I often see some textbooks says: create a schema . does it that mean "create a database"? But isn't that a schema is also a skeleton of a ...
-1
votes
0answers
19 views

Would a database hosting service benefit from compressing its consumer's data? [on hold]

Not sure if this is the stack to ask the question but here it goes. Assuming I'm entering a partnership with a database hosting service which charges me on one criteria: how much space my data takes ...
0
votes
0answers
13 views

ProxySQL and MySQL cluster

This article describes the set-up of MySQL cluster with one cluster node, two data nodes and one MySQL server. This article describes the configuration of ProxySQL where, MySQL servers are added into ...
1
vote
2answers
25 views

What's the problem with PostgreSQL temporary files?

I'm studying PostgreSQL architecture and in almost every book or blog post I read people say that we have to track any increasing of temp_files numbers and find the best work_mem size to avoid new ...
0
votes
1answer
16 views

Multi Master replication vs Single-Master performance

I'm trying to wrap my head around a hypothetical scenario. Imagine we have a very write-heavy distributed database and sharding is not an option. I wonder if / how is multi-leader replication (...
0
votes
1answer
16 views

three tables relation order is correct but values are false

i have those tables table1 | id | name | | 1 | axe | | 2 | bow | | 3 | car | | 4 | dart | table2 table3 | t1_id | ...
0
votes
1answer
29 views

Database from EXTREMELY disorganized Excel Sheet [on hold]

First of all, I would like to say that I am familiar with Databases but all of my knowledge has come from undergraduate coursework, and am by no means an expert. I have been tasked with creating a ...
1
vote
2answers
18 views

MySQL5.7 Find_In_Set alternative

I have a table that contains User information from different countries. Information like - Name, Country, LastLoginDate, IsUpdated, Certification. This table has 1.5 million rows. Now to filter this, ...

15 30 50 per page