All Questions

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

2D array vs SQLite for WinForms C#

In my WinForms C# application, I have data of 100 rows X 20 columns. Each having String data of range: 4-150 characters in length. Average size is 40 characters. Should I use 2D array or SQLite to ...
2
votes
0answers
18 views

How can I rerun a statement from server logs without manual editing?

I have some statements in my logs like this: SELECT to_char("version_downloads"."date", $1), SUM(version_downloads.downloads) FROM "version_downloads" WHERE "version_downloads"."version_id" IN ($2, $...
0
votes
0answers
11 views

INSERT EXEC statement cannot be nested

I have a stored proc spGetSites that returns three columns for SiteName, SiteId and UnitCount. The stored proc runs perfectly fine. I'm trying to store the results of the stored proc to a temp table @...
0
votes
0answers
26 views

What preventive measures can be taken to get over this scenario with minimal data loss

I am SQL server dba and came across weird scenario our cluster which had 10 nodes 5 primary 5 secondary each nodes had SQL role.... example Ams1pd11 to Ams1pd15 are primary.. and Ams3 side from pd11 ...
0
votes
0answers
24 views

SSRS Tries to Upgrade Itself every morning at 2 am

I have a Windows 2019 Server running both SQL Server 2017 Enterprise (14.0.3238.1) and SQL Reporting Services 2017 (14.0.600.1109). In noticed in the RSManagement logs (located here: C:\Program Files\...
0
votes
0answers
24 views

SQL Server 2016 Install Error 2337 Could Not Close File

I am trying to install SQL Server 2016 on a fresh install of Windows Server 2016. Every time I run the install I encounter the same error message pasted below. Crawling the internet has brought me no ...
0
votes
1answer
27 views

How to write a query to identify common combinations of parameters used to call a stored proc?

recently I deployed a change into our production environment that ALTER'd an existing stored proc and essentially all the addition did was INSERT into a table I created the parameters passed in by the ...
2
votes
1answer
31 views

Update row if it has a certain set of values, add new row if it returns to initial value

I'm having some trouble importing data into a table that I'm not sure how to describe succintly enough that can I can properly search for it (not that I haven't tried). I have a table with three ...
0
votes
0answers
9 views

Importing a single large table in Azure

I have an existing DB called MyDb in Azure SQL Server. I have a bacpac of another DB with several tables in it. I'm interested in importing one single table (that table has no FK, it makes things ...
-2
votes
1answer
24 views

Working with NULL Date Fields

I have a derived VARCHAR date field that I need to use for deriving another field, based off of whether or not the date field has a value. The derived date field is called "AmortDate" and I'm ...
0
votes
1answer
5 views

How to delete all rows in a Greenplum row oriented table

In Greenplum, what is the best practice to delete all rows from a table? DELETE FROM TABLE or TRUNCATE TABLE? I dont have any child tables or foreign key constraints.
1
vote
1answer
14 views

Need an Audit Log. Should I create an Audit Log Table or Audit Fields in each table?

By no means am I a DB expert, but I do have experience with creating DBs. Not sure about the following though. I want everything that happens in the system to be trackable. My client is dealing with ...
0
votes
0answers
22 views

Database design for airline ticket reservation site

I'm just a beginner seeking some answers. I'm creating a very simple database system for an airline ticket reservation site, just for learning purposes. i have two problems : i had a Passenger table ...
0
votes
0answers
19 views

Error while deploying package to catalog

I am getting below error while deploying package to SSIS catalog on the last step, I am sysadmin and have access to the below views. Can someone help please. Let me know if you need more info. Any ...
0
votes
0answers
21 views

This is a question about hash index. I'm not sure about the correct answer

I think the answer of the first question is 2^(n-na) and the second question's answer is p*2^(n-na) + (1-p)*2^na. is it correct? But what about the third question?
1
vote
1answer
23 views

Need to create batches of 2000 records within a subset of records

I have a table with 200,000 records. One of the columns is a location ID. I need to break down the entire table in batches of 2000 but group them by the LocationID column. I have about 200 locations ...
-1
votes
0answers
11 views

Is hardware limiting My MongoDB write speed?

I am attempting to use multiple processing machines to submit large amounts (~1TB/day) of data frequently to a mongodb (version 3.4.3) replica set. This data replaces existing data, which can be ...
2
votes
1answer
91 views

SQL Deadlocks - Same Stored Procedure Called Concurrently

I am working with a relatively complex system, where static tables are updated from multiple data sources as they are needed, because dynamically loading the data takes 4-5 seconds and we prefer to ...
-1
votes
1answer
18 views

Postgres. Can't disable nested loop during explain

postgres 9.6/redhat. execution plan of complex query built with using of nested loop. I tried to SET LOCAL enable_nestloop = OFF; EXPLAIN SELECT bla-lba; but there are nested loop anyway Nested ...
0
votes
1answer
12 views

Postgres EXPLAIN ANALYZE is super slow

there is Postgres 9.6 on Redhat I want to EXPLAIN ANALYZE slow query (quite complex one) and it takes too much time. My session with EXPLAIN ANALYZE consume 100% of one CPU and doesn't finish even ...
0
votes
0answers
2 views

SSL Configuration throws a warning MySQL 8.0

Hi I am trying to set up a MySQL server 8.0.16 on RHEL 7.5. The configuration I am willing to include for this server contains SSL related options. The MySQL server is initialized but with a warning ...
0
votes
0answers
5 views

AWS RDS Mariadb Federated/Connect

I believe this is a firewall rule problem. Therefore, I believe that the issue is finding out what the public IP address of the RDS is. I don't see that anywhere on the RDS interface. I have two AWS ...
-1
votes
0answers
15 views

How to connect server in MySQL workbench [closed]

I'm tried any method. Even ash still failed to login server. My server is installed Ubuntu with mysql. Still need additional configuration? I tried to config my.cnf put 0.0.0.0 in IP bind but forbid ...
-1
votes
2answers
43 views

Sql Server Standard 2014: Reindex job locked by other transactions

On a customer of ours we have Microsoft SQL Server 2014 - 12.0.4100.1 (X64) installed. It's a heavy transactions schema (especially during nights) and we have a scheduled REINDEX maintenance job that ...
0
votes
1answer
26 views

Postgres: foreign key constraint for components of a composite type?

In Postgres, is it possible to set up a foreign key contraint involving components of a composite type, in a situation like the following one? Suppose I have CREATE TABLE main ( -- a and b are ...
0
votes
1answer
51 views

Nasty Lookups in Query plan

I've been trying to get rid of expensive lookups in my query plan but cannot seem to get my head around it. I understand the idea of creating a covering index to eliminate the need for lookups but I ...
1
vote
2answers
23 views

Failing MERGE Statement: How to monitor with XEvents and specifically get parameter values for a prepared statement?

My problem I am running SQL Server 2017 and would like to investigate an error with a MERGE statement like the following MERGE INTO table USING (SELECT ? AS Search_Col) AS SRC ON table....
1
vote
0answers
15 views

MongoDB Chunk Migration fails with “error 'aborted'”

I have a simple setup: 2 Mongos 3 Shards, deployed as a Replica Set 3 Config Servers, deployed as a Replica Set Each replica set consists of 1 Primary, 1 Secondary and 1 Arbiter. (Except the Config ...
0
votes
1answer
28 views

SQLCMD external editor

I have set the environment variable SQLCMDEDITOR=gvim to invoke an vim with the ED command of SQLCMD. From my old Windows 7 computer, it used to work. I have now a new laptop (windows 10) and, when ...
0
votes
1answer
11 views

How to issue a DML with WHERE clause comparing a value which is trigger generated in table?

Suppose I have a table with CREATE, CREATE TABLE TEST ( year int, month int, date int, hr int, min int, sec int, timestamp timestamp, value double ); CREATE ...
0
votes
0answers
26 views

Executing 'GRANT SELECT' in a trigger possible?

Trying to grant select privilege on table USER1.AAA to USER2 when table USER1.AAA is created, using system trigger. The trigger below seems to be processed when table AAA is created but it receives ...
0
votes
1answer
22 views

MySQL- Performance implications of changing a column collation from latin1_swedish_ci to latin1_bin

I am a developer so was hoping someone with DBA experience could help me out here. I am using a MySQL database (MYSQL 5.6). I came across a situation where a particular column stores Ids generated ...
-1
votes
1answer
27 views

sql counting with nested sub query

I have a collection of tables in a relational database `student_attendences`(`id`, `student_session_id`, `date`, `attendence_type_id`, `remark`, `is_active`, `created_at`, `updated_at`) `...
0
votes
1answer
13 views

Odoo 10 is not backing up DB in PostgreSQL 9.5. Shows “SQL state: 22008. Timestamp out of range on account_bank_statement_line.” [closed]

At our company, we had a DB crash a few days ago due to hardware reasons. We recovered from that but since then we're having this following error every time we try to back up our DB. pg_dump: ERROR: ...
0
votes
0answers
5 views

Decision on the shard key in MongoDB 3.4

I have _id column in the following format "date-machineNumber-eventgroup eventid-date-Timestamp-0" Can this key be used as shard key? shard key: { "_id" : 1 } unique: false ...
-1
votes
0answers
10 views

MySQL REDO log path permission [closed]

Im not sure if there is a duplicate question but What is the right permission for path directory for redo log on MySQL coz i got this error. ERROR 3847 (HY000): Cannot create redo log archive file ...
0
votes
1answer
29 views

Verify if the client is connecting to the Oracle database using native network encryption

My environment is as below - Server: Oracle 12C 12.1.0.2.v17 ( AWS RDS Service) Client: Windows 2012 machine with Oracle 19C 64 bit full client Tools : SQL Developer and Toad on the client machine ...
0
votes
2answers
28 views

Copying MySQL table to another table with no missing new changes

I would like to recreate/copy a MySQL table (a actual new ibd file) - and most of the suggestions recommends the following : CREATE TABLE mytbcopy LIKE mytb; INSERT INTO mytbcopy SELECT * FROM mytb; ...
0
votes
1answer
28 views

Database design for large amount of sensors at very fast intervals

I've been tasked with designing a backup solution to store sensor data from about 1500 sensors at 10 second intervals. In the event that the primary transmission method of the sensors goes down, my ...
0
votes
1answer
24 views

Oracle database backup and restore options

We have one requirement that export data from two different source Oracle DBs and restore the data to another two different target Oracle DBs to do data comparison. We care about the datafiles in ...
-1
votes
0answers
20 views

How could we bring all database vendors to offer free developer licenses? [closed]

If you're like me and develop multi-platform database tools, you understand how frustrating it is to still find database vendors with no free dev or at least "express" editions that do not expire in ...
1
vote
0answers
25 views

Database - limit of reading a table with a lot of concurrent batch read and writes

We have this table. It contains data which will be picked up by an hourly batch job for processing. Five times a day, there are also multiple batch ETL jobs which get data from other source table and ...
0
votes
0answers
11 views

Is it possible to disable strict mode per user

I have a host that I use for running some data import scripts. These are pretty old / legacy scripts that aren't important to anything and aren't sensitive. The host recently upgraded mariaDB and now ...
0
votes
1answer
8 views

Json append results in error of - “No operator matches the given name and argument types”

clusters_v2=# UPDATE cluster SET "clusterCALogs" = "clusterCALogs" || '["test"]'::jsonb WHERE "clusterId" = 9; ERROR: operator does not exist: json || jsonb LINE 1: ...ATE cluster SET "clusterCALogs" ...
0
votes
2answers
29 views

How to get (format) a Firebird v3 DATEDIFF() to the number of years, months and days all together?

In Firebird v3 I can use DATEDIFF() with either YEAR, MONTH or DAY to get the number of years, months OR days respectively. I need a way to get all-in-one years, months AND days. For example: 412 ...
1
vote
1answer
57 views

How to optimize this Select MAX() SQL query?

In the following select query, it take almost 1 min to return the result, seems the table has over 2 millions record and growing. There are no index i can use from the table. How do I optimize this ...
1
vote
0answers
15 views

Get durations from time series table where some condition holds consecutively

Given a table where each row has a timestamp and some measurement, how can I get all of the intervals during which the measurement consecutively satisfies some condition? Here's a jsfiddle (not sure ...
0
votes
2answers
19 views

pg_restore fails on foreign key contraints

I need to restore a PostgreSQL DB from a backup that was created using "custom format" so that a single table could be extracted from it later. (Per the documentation individual tables cannot be ...
0
votes
1answer
12 views

Transfer image files from MongoDB to S3

I have a NodeJS app that stores all of its data, even images, to MongoDB. Now I want to use an S3 (DigitalOcean Space) to store my app's files (images, 43gb) and so, I need to transfer there all files ...
1
vote
3answers
60 views

NULL as a @variable within WHERE clasue

I would like to SET 'IS NULL' as a variable and use it in a WHERE clause. I will be unioning many tables together that carry the same WHERE clause and would like flexibility to use a variable for my ...

15 30 50 per page