0
votes
0answers
8 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
11 views

Convert SQL OPENXML to XML Nodes Value

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

How unique key helps to improve sql query performance?

Suppose I have a table with id column and and I am maintaining unique value manually while inserting and updating record instead of creating unique key on that column (ie. using date & time for id ...
0
votes
0answers
7 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
9 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
0answers
9 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
8 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
0answers
8 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
23 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

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
0answers
18 views

Why MySQL SELECT performance depends on table size?

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
19 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
10 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
28 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
18 views

Database Attachment

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.
0
votes
0answers
20 views

How to take backup of rows which are going to be deleted and restore it? (Mysql)

I want to backup the rows which are going to be deleted for that I want to use a trigger that stores those rows somewhere in another temporary table.. For that following things I am going to need ...
0
votes
1answer
19 views

How to Store text of 15 to 20 KB file data in blob or as text? [duplicate]

How to Store text of 15 to 20 KB file data in blob or as varchar in sql Server?
-5
votes
0answers
17 views

sql server query [on hold]

In front end I am selected one number from dropdownlist if database table contains this number then gridview shows the number and some message else grid view shows the number and other message what is ...
0
votes
2answers
30 views

How to minimize log operations in SQL Server to avoid “log full” error

I have a database in production which constantly get log file filled, its a data warehouse and have many jobs/queries running for obvious. Below is the error which I am getting Msg 9002, Level 17, ...
-2
votes
2answers
19 views

how to join one select statement to another pivot select statement

SELECT emp.UserId ,emp.EmployeeId ,emp.FirstName ,emp.MiddleName ,emp.LastName ,emp.MobileNumber ,emp.HomeNumber ,emp.OfficeNumber ,convert(VARCHAR(10), emp.USJoindate, ...
-1
votes
1answer
23 views

Set up MySQL server database [on hold]

I want to set up MySQL server database for my office on my windows 8 pc, but i dont know exactly which products to use. Can anybody help me with it. I want to set the database such as my pc would be ...
2
votes
1answer
16 views

SQL Server Active Directory login groups with limitation

I'm DBA in my organization and use SQL Server 2012 and 2014. I requestd to define multiple group in active directory such as Developer, DBA, supporter and ets... and add my users to this groups. after ...
0
votes
1answer
41 views

Get data faster from databasse

My site having a more than 1.5 million records and my question is the how may i fetch record fast. i am spending so much time to find the way for it finally find out the one way which is to apply the ...
2
votes
1answer
24 views

Create a grouping based on chains of pairs

Say I have two tables: CREATE TABLE datum ( datum_id SERIAL PRIMARY KEY, datum_text TEXT NOT NULL ); CREATE TABLE datum_pair ( datum_id1 INTEGER NOT NULL REFERENCES datum (datum_id), ...
0
votes
1answer
10 views

MariaDB 10 replication strange behaviour

I have following MariaDB 10 replication setup. Server A MariaDB 10 (master), Server B MariaDB 10 (master), Server C MariaDB 10 (slave/master), Server D MariaDB 10 (slave). A and B are getting new ...
0
votes
1answer
19 views

Filling not applicable fields with N/A rather than leaving them empty or Null [duplicate]

I have a database of few million records, many of the fields (call them Ec1 to EcN) have either Null or empty string in them. When I looked at them more closely, I found that for many records, several ...
2
votes
0answers
16 views

Improving performance of a weighted search query in SQLite3

For an intra-site search I have this table in an SQLite3 database, that relates ids to search terms with a certain weight: CREATE TABLE search_index ( id INTEGER(7) REFERENCES other_table, ...
0
votes
2answers
95 views

Calculating values from three related tables, without using join or union

I have a simple basic three tables on SQL Server database: What is needed is to get the quantity available, without using joins or unions which is calculated: Quantity Available = Items Opening ...
0
votes
1answer
35 views

unable to add index to column, duplicate entry

I have a table that collects virtual machines usage metrics, I'm trying to add an index to timestamp column, to speed up queries, when selecting time, this is a sample of the table I have, it has ...
0
votes
1answer
23 views

Tracking Table Structure Changes [on hold]

I'm by no means a full DBA, so I'm kind of shooting in the dark right now, but we'll see how this goes. This is with Microsoft SQL Server 2014 with our applications written in ASP.NET. What we want ...
-2
votes
0answers
12 views

DBF error.The database cannot be open [on hold]

I have a software call Kodak Trophy(database program).This program stores patient data with x-rays. Now it is giving an error saying that the database cannot be open. When I try to reindex a ...
4
votes
1answer
60 views

Move live SQL Server database to a new server

I have a production server running SQL Server 2008 Web Edition, and it has to keep running 24x7 with almost no down time, and it's the time for us to move to a more advanced server hardware, also it's ...
-7
votes
0answers
36 views

Vendor query yields poor performance [on hold]

I have a query that the vendor will not change. The query takes 4 hours and of course slows down the entire application. Has anyone run into this? Query Code Here
1
vote
1answer
26 views

Couldn't restore database and couldn't change Single user mode to Multi user mode

I am unable to restore a database. The database is stuck in single user mode. I cannot change to multi-user mode. I was restoring the SQL Server database from Prod to Dev as I have done many times ...
0
votes
0answers
15 views

How to identify a client application whose host_process_id points to sqlserver.exe

I am in the process of trying to identify a client application which uses one of the SQL Servers I support (2008 R2). Periodic queries against sys.dm_exec_sessions regularly return sessions whose ...
1
vote
0answers
29 views

Overwhelmed with Sensor Data - Excel to SQL fails

I'm managing a lot of sensor data and need to do charting, smoothing, stats over time on the data. Currently I import the data from flat files using VBA to do ETL into Excel. The format of the data ...
0
votes
0answers
15 views

Innodb index doesn't fit in Memory

I am using innodb tables in my database and total index_size is 250 GB and my data size is 500 GB. Server has 128 GB RAM, and innodb_buffer_pool_size is set to 64 GB. Data size is increasing every day ...
0
votes
0answers
16 views

Log Shipping Fails to create backup after Server reboot

We made a change last week to point our log shipping backup jobs to a new Windows File Share. For three days everything was running successfully. On Saturday night we performed our monthly ...
0
votes
0answers
23 views

ASP.NET Session Database - what user to create?

I am migrating a .Net 3.5 website with SQL Server 2005 Enterprise databases to SQL Server 2012 Enterprise (website still .Net 3.5). It uses ASP.NET session state database of type "t" Temporary. ...
2
votes
0answers
48 views

bug in sp_rename

I've searched high and low, but I cannot find anyone mentioning that when you run sp_rename, then you should mark the objects for recompilation too. As in EXECUTE sp_rename 'fct.MyTable', ...
2
votes
3answers
95 views

Unknown returned type in PostgreSQL query

The following query works: SELECT a, b FROM unnest(ARRAY[(1,2), (3,4)]) AS t(a integer, b integer); a b _ _ 1 2 3 2 However, I wasn't able to use a different column type such as varchar(255): ...
3
votes
1answer
27 views

Circular dependency in schema or boolean with CHECK?

Let's say I have the following tables: create table repositories ( id serial primary key, name varchar(255) not null ); create table remotes ( id serial primary key, url varchar(255) ...
1
vote
1answer
34 views

Tune Performance by putting large tables into the KEEP Pool

We currently have a database with 20GB SGA space. SQL has been optimized but has to statisfy its use cases as well and some queries are very, very slow, specifically when large result sets are ...
0
votes
0answers
29 views

Backup Mirror database

I have database mirroring setup between two SQL 2012 servers in two different datacenters. For testing purposes in the "mirrored" datacenter I would like to create a working copy of the database. ...
0
votes
0answers
10 views

Automatic failover in Mysql 5.6 [on hold]

I have to perform the Master-Slave Replication in Mysql5.6 with automatic failover Option.Please help be to achive this. Coming to my setup i have 4 Mysql Instances running on single server.Now i am ...
0
votes
0answers
20 views

Alternative when IN clause is inputed A LOT of values (postgreSQL) [migrated]

I'm using the IN clause to retrieve places that contains certain tags. For that I simply use select .. FROM table WHERE tags IN (...) For now the number of tags I provide in the IN clause is around ...
0
votes
2answers
19 views

Unable to browse to folder on SSRS 2012 through report url

I have installed SSRS 2012 in native mode on windows server 2012 r2 and deployed reports to the server successfully. I am having difficult browsing to any report folder through the report URL. I can ...
2
votes
3answers
50 views

Track entity updates (by who and when)

I need some advice on how to store information about who created/updated an "entity". I keep going back and forth between Option1, 2 and 3 (see below): Background This is a legacy system and there ...
3
votes
0answers
10 views

Remove a shard in MongoDB

I have a MongoDB cluster, I accidentally hosed a shard, I don't have a backup. It's pretty easy to recover the data, but after issuing the removeShard command, it says it's draining. However, the ...
0
votes
3answers
54 views

Adding order by to a query is slowing down the query even after Indexing

While joining columns with huge data even after indexing the column order by is slowing down the query. Without order by query is executing within 2 secs. But with order by query is taking 145 secs. ...

15 30 50 per page