1
vote
1answer
9 views

What happens on the primary when log cannot be restored on the secondary on Log Shipping

I would like to setup a log shipping but I have a concern as to what would happen if the restore operation on the secondary would fail for some reason. I want the primary database keep working no ...
0
votes
0answers
15 views

How to export an image column to files in SQL Server?

I will migrate from a database. There is one column of type image that I would like to export to binary files on the file system. One file for each record. How can I do this with SQL Server?
0
votes
0answers
15 views

Optimizing for data that does not fit in memory

We have a database that contains around 235 GB of data (calculcated using pg_total_relation_size for each table) on a server with around 77GB of memory. The server is used for nothing else (aside from ...
2
votes
1answer
16 views

How do you calculate CPU Affinity Bitmap for SQL Server?

I am trying to calculate the bitmap for my 32-core server. I want my instance to use cores 30 and 31. I know that CPU 0 gets assigned a value of 1, CPU 1 gets assigned a value of 2, CPU 3 gets ...
0
votes
0answers
10 views

Oracle PLSQL code recovery

I cannot connect to my database as admin, even using connect descriptor neither via RMAN. I am getting TNS-12514 error. I consider to install new instance. Questions: 1) Can I restore/recover PLSQL ...
0
votes
1answer
10 views

Insert any type of text in a column

How can I insert any type of text into a column of type text? At the moment I am using this: $$description$$ But a lot of my descriptions contain $ and other signs, so the insert will fail. Do I ...
0
votes
0answers
4 views

MySQLfabric — Manage setup problem

MySQL fabric does not get configured , getting these errors : [mysql@dev-dm-gitest101z /root]# mysqlfabric manage setup Error : [INFO] 1413953890.788408 - MainThread - Initializing persister: user ...
0
votes
2answers
14 views

VARCHAR primary key - MySQL

Currently, I have a categories table with 2 columns - category VARCHAR(50) NOT NULL PRIMARY KEY and parent VARCHAR(50). The parent column is a foreign key (FK) to the category column. This seems like ...
0
votes
1answer
31 views

Why the operation is not rolled back?

I have the following code in a trigger (AFTER INSERT, UPDATE): BEGIN IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION; RAISERROR('Does not allow modifications in the past', 16, 1); RETURN; END; ...
0
votes
2answers
13 views

Why Postgresql 9.2 word boundary not working!

In my postgresql version 9.1 this query is working fine: select id,name from flash_card_set where name ~* '\yACT\y' and matching: text ACT txt,ACT tests,tests ACT But in my postgresql version 9.2 ...
0
votes
1answer
12 views

ODBC MS SQL driver on Linux/nginx

Writing here because really can't figure out what to do. I have a site located at ftp server. And now it moves to a new server based on Linux/nginx. And everything is fine except MS SQL ODBC driver. I ...
0
votes
1answer
13 views

How to get all the months from the last paid date in MySql?

I need to get the all the months from the last_payment_Date for the user from that table for processing purposing. As of now i am using this query.. SELECT `Name`, `Acc_No` FROM `user_table_details` ...
1
vote
1answer
14 views

mariadb - EXPLAIN works but ANALYZE throws ERROR 1064 (42000) error in SQL syntax

I want to see the execution plan of a query to find out why it is slow, but ANALYZE does not seem to work, it throws an error on the same query that EXPLAIN accepts. MariaDB [dbx]> explain select ...
1
vote
2answers
22 views

Query where there are only two rows with specific data

I have a table with room which has a data of who are in it. Each room has have 0 to any number of people and each person can be in multiple rooms simultaneously. (simplified below) id name 1 ...
1
vote
1answer
13 views

mysql - sum interval dates

I would like to sum the hours for each name, giving a total interval between START and END activities. It would be simple if I could subtract from each record the end of the beginning. For example, ...
0
votes
0answers
7 views

How to model efficient permission checks for a social network?

The goal is to build a facebook like permission system. So that users can grant other users access on objects based on a direct assignment (allow user X to see posts) or allow users to access them ...
2
votes
0answers
14 views

Find the current task of a long time running indexes reorganize operation

In a scheduled maintenance window, I've manually rebuilt/reorganized some indexes of a SQL Server 2012 database. It was an offline task, since my SQL Server license does not allow online ...
1
vote
1answer
17 views

How to Choose an SQL Database for Simple Data Preparation & Analytics

In the interests of not making this a shopping list: please advise on "how" to choose a the right tool, as opposed to which is the best. E.g: Which questions should I be asking myself / client? What ...
0
votes
1answer
17 views

Query to select distinct name based on several factors

I have a table with the following data (simplified here): ID | PolicyName | Setting | State | Value 1 Default DiskUsage Enabled 1 2 Default Memory Enabled 1 3 Default CPU Enabled 0 4 Personal ...
-2
votes
0answers
13 views

Find the salary history of employee ‘Margareta Markovitch’ [on hold]

i want to know how to write the query for this question. Find the salary history of employee ‘Margareta Markovitch’.
0
votes
0answers
24 views

“DISTINCT” JOIN in mySQL

+----+-------------+-----------+---------+ | id | login_ip | hostname | user_id | +----+-------------+-----------+---------+ | 1 | 192.168.0.4 | 'host 1' | 1 | | 2 | 192.168.0.4 | 'host ...
0
votes
0answers
21 views

MySQL Upgrade from 5.5 to 5.6 causes system / table locks

We recently upgraded from MySQL 5.5 to 5.6 on AWS RDS. Before, we had a relatively performant database - definitely had its quirks, but it seemed to be tuned relatively well. After the upgrade, we're ...
0
votes
0answers
5 views

How to diagnose MariaDB crash when changing InnoDB column to AUTO_INCREMENT?

I have this table, and I'm trying to change the first column to AUTO_INCREMENT: +------------+---------------------+------+-----+---------+-------+ | Field | Type | Null | Key | ...
0
votes
0answers
37 views

Delete and merge duplicate records from joined tables?

I am trying to delete duplicate records from the output of the query below. If they also meet certain conditions i.e., 'different address type', then I would merge the records. From the following ...
2
votes
0answers
50 views

Database is happily available even during log growth?

I’ve been creating a process to go through all our databases and analyze the log structure, backup, shrink, and resize appropriately taking operational requirements and VLF sizing/amount into account. ...
0
votes
0answers
15 views

Too many keys specified; max 64 keys allowed org.hibernate.tool.hbm2ddl.SchemaExport

I am using hbm2ddl to create a MySQL 5.6 database. There are reasons why certain tables need to share keys with large numbers of other tables. For example, one table represents a datatype, which ...
1
vote
1answer
9 views

“Wrong affix file formate for flag” while loading dictionaries from LibreOffice in PostgreSQL 9.3

Trying to get good TEXT SEARCH results out of PostgreSQL in English, German and Dutch made that I downloaded proofing tools of LibreOffice (tried of version 4.3 and 3.3) and iSpell. I placed the files ...
3
votes
2answers
33 views

Disabled SSL on SQL Server, now connection fails

I have a customer that is worried about the latest SSL vulnerability POODLE. They have a utility (IIS Crypto 1.4) that disables SSL 2.0-3.0 on the servers they run it on. They have disabled SSL on ...
0
votes
0answers
31 views

Optimizing query - understanding explain

I've got a query (partly generated by django orm, but can be modified). For some reason, It's very slow (between 1.5 -3 seconds, without having lots of data on the system) . I've got an "explain" ...
1
vote
2answers
39 views

Upgrading hardware for MySQL. If we get SSDs, are CPUs likely to become a bottleneck

We are upgrading hardware for a MySQL database server (DB is around 200GB). We're getting 4x Samsung 850 Pro SSDs and are planning to run them in a RAID10 configuration. Also, 128GB of RAM. The ...
0
votes
1answer
46 views

Retrieving month from date field in my database

i have dates stored in database with the function : CURDATE() , when a user makes an order . Now with a form where the admin chooses the month and the year , i want a query to display all the orders ...
0
votes
0answers
10 views

Are there any minimal sqlite extensions for running a server with role based access control?

I need to run an SQL server with role/user based access control in a very resource limited environment. Are there any extensions or open source projects for sqlite to provide this functionality? ...
1
vote
1answer
28 views

Trying to combine one row from one table with mulitple rows from another table but not sure if I'm doing it right?

The Situation I have two tables unit and unit_translations defined as: CREATE TABLE `unit` ( `id` int(11) NOT NULL auto_increment, `title` varchar(255) NOT NULL COMMENT 'Title of unit', ...
2
votes
2answers
123 views

How to detect DBCC ShrinkDatabase completion percentage?

Recently we have archived some of data from one of very large production database and need to shrink all data files to reacquire disk space. Problem is that its taking too much time and we are ...
1
vote
1answer
33 views

Can't start MySQL server because of wrong file permissions?

I'm trying to start the server and then fix the root user by $ mysql -u root mysql $mysql> UPDATE user SET Password=PASSWORD('my_password') where USER='root'; $mysql> FLUSH PRIVILEGES; But ...
0
votes
1answer
16 views

Can't map invalid columns based on column names in a .dtsx-Package

I have the following problem. I currently have to modify a .dtsx-Package which was originally created by a coworker who is not arounf anymore. This package contains some logic but above all it does ...
0
votes
0answers
10 views

Oracle SQL Loader - BULK UPDATES

Can SQL loader be used to do bulk updates? I have a table that holds customer information. The table has a primary key and it has 5 columns pertaining to the customer. Now we created three more new ...
1
vote
1answer
28 views

Measuring DB time of application using SQL Server Profiler

I have an application residing on the same host as a SQL Server database. There is a scenario in which this application is slow and due to co-existence of IIS and SQL Server, I cannot get which one ...
0
votes
1answer
30 views

Database state set to an earlier state before creating new indexes

This is a remote server (SQL Server 2008). We are trying to get benchmarking of some stored procedures. One stored procedure was taking avrg 44 seconds, we have checked this approx 20 times for a ...
0
votes
2answers
59 views

Can I stop a SQL database backup after it has already started?

I am looking to do a full database backup of a SQL database in SQL Server 2008. My questions are: *Can I stop, pause, or cancel the backup after it has started if it is taking too long or slowing ...
0
votes
1answer
29 views

Problem with procedure performance

I'm having problem in Oracle, where I have two procedures that are executed one after the other. Where the first procedure, I have a cursor that does insert into a table. This insert has about 30 ...
1
vote
1answer
19 views

Converting 'False'(string) to False(boolean) During LOAD DATA LOCAL INFILE

In MySQL is there anyway of loading "False" into a boolean column. While loading data in table having boolean column and where data is in "True" or "False", it gives warning of: "Incorrect integer ...
0
votes
0answers
4 views

Choose prefered node for IST in Percona XtraDB Cluster

Percona XtraDB Cluster 5.5. Is it possible to use only selected donor node for IST? Like wsrep_sst_donor option for SST.
0
votes
1answer
34 views

ACID violation in Postgres 9.1?

I am using a postgres DB to implement a scheduling of jobs for a large number of computers/processes. To make the story short, every job has its id, all scheduling is implemented with three tabes: all ...
0
votes
0answers
13 views

Best way to approach building search functionality using PHP on existing mySQL Database

I am looking for advice on how to approach an upcoming project I am due to undertake. The reason I am asking is that I'm just out of college and the company I work for is currently searching for a new ...
3
votes
1answer
67 views

When is mariadb creating tmp tables?

I have found, that copying to tmp table is taking most of the time of a slow query, that I wanted to optimize. I watched the output of 'profiling' in a terminal. This happens on a pics table with 6000 ...
1
vote
3answers
345 views

Which one is better performance and (approach): store as rows or as a varchar column

OptionA: TableA: TableA_ID (PK,int) .. TableB: TableB_ID (PK,int) .. TableC: TableC_ID (PK,int) .. TableD: TableA_ID (FK, int) TableB_ID (FK, int) TableC_ID (FK, int) (Nullable) ...
1
vote
2answers
55 views

Does a database backup reduce size/increase free space of the log file?

Novice question, sorry! Got a SQL Server database and the log file is massive and keeps growing every day. I've archived data from the database and then done a full backup. I was expecting the log ...
0
votes
1answer
21 views

modify a select stmt to give you the definition of a column value [on hold]

I have Select [casenumber], [centercode], [Outcome] the columns centercode and Outcome are numeric contents and their respective Verbatium descriptions are in a child - TblDesc - tables how can I get ...
0
votes
1answer
23 views

How do I select all child table records based on condition [on hold]

I have two tables - demographics and PatSubs. Both tables are linked by CaseNumber filed. PatSubs may have one or many substance entry for the CaseNumber. If I do the following: USE [njpies2013] GO ...

15 30 50 per page