0
votes
0answers
4 views

Cannot Create Backup Device - SQL Server 2008 R2, Error 1326 (permissions look ok)

Trying to create a backup device for a new db. I'm using management studio and just using the "New Backup Device..." wizard and giving UNC path to the backup directory. There is a pre-existing db on ...
0
votes
0answers
4 views

How could I improve my DB design?

I'm a second year software engineering major looking to create an iOS app that connects to a MySQL database (database not yet created) over the summer. I have a strong understanding of programming and ...
0
votes
0answers
6 views

How to get the script of a sql.zip file?

i had a hosted page on GoDaddy and i exported the database, so i get a .sql.zip file, but i can't import it to mysql server on phpmyadmin, it says it has an error on a PK. How could i get the script ...
0
votes
0answers
5 views

Intermittent “access denied” (1045) message from MySQL

I'm importing a fairly large (100GB+) database from MySQL to PostgreSQL using pgloader. After a seemingly random amount of time the process dies with the following error: An unhandled error condition ...
0
votes
1answer
11 views

Triggers on Insert or Update SQL Server (Spatial)

I am looking at creating a trigger on a live MS SQL spatial table that will update a field when a user either: 1. Creates a new feature 2. Updates the geometry of a feature in a GIS application. ...
0
votes
1answer
12 views

Put Postgres query result in array

How can I put an sql query result in a string array with Postgres? I have some attributes in the column 'zone' of the table 'mytable' and i must put them all in a String[] areas; Thanx, this is my ...
0
votes
0answers
8 views

inserting multiple rows with two input fields with same names

HTML <tr> <td><input type="text" name="description"/></td> <td><input type="text" name="quantity" /></td> <td><input type="text" ...
0
votes
0answers
8 views

source control for SQL Agent Jobs

Our SQL Agent jobs execute different DTSX packages at various steps. e.g \DEVLserver\DTSX\package1.dtsx I want to keep the agent job script in TFS but when I promote it is there any way to change or ...
0
votes
1answer
8 views

Removing locks in Oracle without being admin

3 wild sessions each got a row exclusive lock in the same table: SELECT * FROM DBA_DML_LOCKS; How can I remove the lock without being admin? if I was admin I would list (SID, SERIAL#) of the ...
1
vote
0answers
10 views

Which major database platforms support TTL?

I need to store some data in a database that will be hosted on Amazon Web Services, and I have complete freedom over choosing which database platform to install, based on what I think will best suit ...
0
votes
0answers
7 views

Is it possible to set a timer for autovacuum in psql

I am running psql 9.4.1 on my localhost. I am currently cleaning up data, which requires me to run expensive queries. It seems like my tables get "locked" up every day at the same time in the pm. My ...
0
votes
2answers
24 views

SQL Server user cannot select from a table it just created?

I'm having trouble understanding permissions in SQL Server (in this case SQL Server 2012, but not sure how version-dependent this issue is). I can create a database, create a login/user on master, ...
0
votes
0answers
6 views

Overload resolution failed

I am using reporting services to generate a list of families in my database. After the first family member in the list, I want to put the family's address: family, First 123 la la lane Somewhere, Ca ...
0
votes
0answers
8 views

Mysql is not starting while using xampp.

Mysql is not working when I try to view my site on locahost. I keep getting 'Error: MySQL shutdown unexpectedly.' The Mysql log says: 2015-05-06 19:39:13 5268 [Note] Plugin 'FEDERATED' is disabled. ...
0
votes
0answers
21 views

Smallest unique string among multiple columns

Somewhat similar to the Largest Common Substring (http://en.wikipedia.org/wiki/Longest_common_substring_problem) I'm trying to find the smallest unique string from a table. In some tables, its just ...
0
votes
0answers
6 views

connecting to database on ec2 Virtual Machine from sql developer

I am using Oracle SQL Developer 4 to connect to databases . We are running an Oracle 11g on Amazon EC2 Virtual Machine (not RDS) and I can’t connect remotely. inside the Virtual Machine as local ...
1
vote
0answers
7 views

postgresql pg_dump no matching schemas

I have a local postgres 9.4 installation with pg_dump. I am trying to do a remote pg_dump where I'm looking to dump only the schema DDL with NO data. I am getting the error: pg_dump: No matching ...
0
votes
1answer
19 views

Getting the count of same value in consecutive rows that are ordered by different field

I have a table with the following structure finals(ID, name, result) CREATE TABLE `finals` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `name` varchar(10) DEFAULT NULL, `result` char(4) ...
1
vote
0answers
11 views

Listener.ora problem when I copy OVA

I deployed a new VM Oracle machine using a copy of my existing Oracle VM. As a result, the new VM inherited the same host name. This is redhat linux 6.5, Oracle11g. I changed hostname everywhere as ...
1
vote
1answer
24 views

Moving a date between tables is causing error ORA-01841 [on hold]

Here's my script: INSERT INTO BRAND_RECORD SELECT STRENGTH, GENERIC_NAME, TO_DATE(a1.FIRST_CLAIM_DATE) as INTERCHANGEABILITY_DATE FROM DRUG_INFO INNER JOIN ( SELECT ...
2
votes
1answer
22 views

xp_cmdshell in a transaction

I need to run multiple scripts in a certain folder in a transaction and rollback if there are any errors. At this point I'm just trying to get the rollback to work without a try catch. Currently when ...
1
vote
1answer
19 views

How to atomically replace table data in PostgreSQL

I want to replace the entire contents of a table, without affecting any incoming SELECT statements during the process. The use case is to have a table which stores mailbox information that is ...
7
votes
1answer
62 views

How to optimize a query so that it seeks on one index first, and then another index after that

I have two sets of earth measurements from satellite data, each with time fields (mjd for mean julian date) and geography positions (GeoPoint, spacial) and I'm looking for coincidences between the two ...
0
votes
0answers
10 views

postgres fetch record from partitions without the check constraints

I am using postgres 9.4, I have a messages table that has 100M records, so I decided to partition the tables by posted_at. Table "public.messages" Column | Type ...
0
votes
0answers
12 views

Issuing Inserts/Updates to Progress OpenEdge via ODBC

I'm attempting to build some ETL to integrate our SQL Server environment with a remotely hosted 3rd party app running Progress OpenEdge. I have a linked server to it set up in SQL Server 2014. ...
0
votes
1answer
37 views

Restore user db from UNC

I need to create a job that restores all user databases from UNC to my SQL Server. All the backups, for 3 days, are located in the same folder and I need to restore the last modified backup. What is ...
0
votes
1answer
19 views

improve database design for monitoring application

I need assistance with my DB design, I have a monitoring script that produce the following data every minute , and produce stats about virtual machine performance. Array ( [timestamp] => ...
0
votes
1answer
27 views

Updating across row and column in SQL

Bit of a strange question. Entries in this table have three relevant columns; drug, date_1, date_2, seq_id I am trying to make it such that every drug with the lowest seq_id has a date_2 equal to the ...
0
votes
0answers
20 views

Any GUI tools for Progress? [on hold]

What GUI tools I can use for Progress databases? Something similar like MySQL Workbench or Navicat for Progress?
0
votes
0answers
12 views

What's the greatest value for postgres maintenance_work_mem?

I set 1960MB successfully for maintenance_work_mem, and got about 30% performance improvement on my COPY batch inserts. So I'm trying to run the import with even more mem (my machine has 32GB). ...
0
votes
1answer
32 views

Replacing a Cursor with a single Query possible?

I have this challenge where I'm trying to figure out if I can write something in a single query rather than using a cursor. The problem is I need to get items from a batch table based on a list of ...
0
votes
1answer
26 views

OR Operation in JOINS SQL(MYSQL)

I am using MYSQL SELECT m.proposalId, m.title, n.stageNumber, n.committeeId, n.modifiedDate, o.msNumber , o.description,o.ics,o.edition FROM mystands_Proposal m INNER join ...
0
votes
2answers
20 views

How to access to DB Instance from another DB Instance with Windows Authentication

i have two database servers DB_INSTANCE1 DB_INSTANCE2 is it possible to access from DB_INSTANCE1\DB1 SQL script to DB_INSTANCE2\DB2 tables without using SQL Logins ? (not every database servers are ...
0
votes
1answer
32 views

Index cleanup/usage help

My question is this: When running sp_blitz, I get a lot of these 2 warnings/suggestions: Index Hoarder: Unused NC index and Feature-Phobic Indexes: Potential filtered index (based on column ...
0
votes
1answer
43 views

How to exclude weekends and holidays in a query

I have been tasked with creating a flat file. One of the fields that I need is a date field. I need the disco date to be LAST_EVENT_PROC_DT + 12 unless that date falls on a weekend or holiday,if so ...
0
votes
0answers
33 views

How to confirm if the backups are going to tape in SQL server 2005 and 2008R2

We have many of our SQL servers where we take the backup locally on the server as well as over the network to other server in case of disaster. Also, we have a process set that server support team ...
0
votes
0answers
15 views

Convert SQL OPENXML to XML Nodes Value [migrated]

Can anyone help with converting the following from OPENXML to Node protected virtual void ApplySqlXmlSetupSql() { if (!this.query.HasFilterBySectionList && this.query.IgnorePermissions ...
2
votes
3answers
494 views

How does unique key help to improve SQL query performance?

Suppose I have a table with an id column and and I am maintaining unique values manually while inserting and updating records instead of creating a unique key on that column (e.g. by using a date ...
0
votes
0answers
18 views

How to run pg_bulkload on windows?

Is it possible somehow to run the postgres batch tool pg_bulkload on windows? I could not find any documentation on this, only for linux. Though it should be possible as the docs state: If you ...
0
votes
0answers
14 views

Return both Result set AND a warning from a stored procedure

In Data Studio when you call SYSPROC.ADMIN_CMD() directly and it returns a warning, the results panel shows both the warning and the result set: CALL SYSPROC.ADMIN_CMD('EXPORT TO ...
0
votes
1answer
19 views

Scale MySQL trigger for thousands of inserts per seconds

We are using MYSQL database for an Analytics app. I have two table token and token-big (for overview of actual data) both have id(int) unix_starttime(int) unix_endtime(int) details(varchar 256) A row ...
-2
votes
0answers
12 views

Mysql and php query is not working [on hold]

$servername = "localhost"; $username = "root"; $password = ""; $dbname = "BBAHOTEL"; // Create connection $conn = new mysqli($servername, $username, $password, $dbname); // Check connection if ...
1
vote
1answer
17 views

Repeating rows of date intervals based on another table in Oracle

I have a table of maintenance plans with date intervals between each required maintenance period. Fiddle: http://sqlfiddle.com/#!4/af742 create table maint_sched (maint_id number, start_date date, ...
0
votes
1answer
32 views

Creating database with a relative path

I am supposed to be testing a piece of software that uses mssql express as the backend for data storage. When it is creating its databases, it tries to create them in my home directory that is on a ...
0
votes
0answers
8 views

Changing Numbers from standard form without clicking every cell- Excel [migrated]

I have imported a csv file from MySQL, documenting part numbers and descriptions. Some of these part numbers have values like 1234567890987654321, which is then shortened by excel to 1.23e18. Problem ...
1
vote
1answer
39 views

Why MySQL SELECT performance depends on table size? [on hold]

I've got two identical tables with the following structure: CREATE TABLE words ( id bigint(20) NOT NULL, `text` int(11) NOT NULL, w1 int(11) NOT NULL, w2 int(11) NOT NULL, w3 int(11) NOT ...
0
votes
1answer
22 views

Postgresql unique history

I am running several commands, some repeatedly, from the postgresql command line tool. In Bash, the history function keeps one command for each set of sequential identical commands, it seems that ...
0
votes
0answers
12 views

Does foreign key and cascade take advantage of filtered index?

I have a table T2 referencing another table T1 The referring column ref_T1 has a nonclustered unique index on it, filtered for value <> 0 When I delete a few rows from T1 and the forein key ...
2
votes
2answers
50 views

Changing an nvarchar column to datetime

I am new to SQL Server and I have a problem. I created a database to store dates in an nvarchar field but now I need to convert that field to datetime. I searched the internet and couldn't find a ...
-2
votes
1answer
20 views

Database Attachment [on hold]

I have tried attaching mdf files to recover a database but I get this error message. I will be glad to have your suggestions to a solutions. Martin.

15 30 50 per page