0
votes
1answer
36 views

Postgres DB user permission

I'm logged in as a user in postgres with PgAdmin tool in Linux connecting remotely but I don't think the user has enough rights. I'm a MySQL experienced user but not so much in PostGres. When I select ...
0
votes
2answers
599 views

Analysis Services not allowing other/remote connections other than localhost

Analysis services not allowing any connections except localhost. Authentication box is disabled and only allow windows authentication. How can I connect to different remote analysis servers using sql ...
3
votes
2answers
147 views

Online index rebuild snapshot location and impact of filling index drive

My understanding of a rebuild index online operation is that the index will have a snapshot taken and the rebuild is started on the snapshot index. My question is where does the snapshot index ...
-1
votes
2answers
77 views

Getting a total value for items obtained in the current quarter

I've been working with MS SQL Server Management Studio and have a problem I can't fix. I am currently able to get the total for a set of values (Volume and Activity) from my SQL Server database. ...
-1
votes
1answer
361 views

Unable to start SQL Server Agent

We are unable to start SQL server Agent and it fails with below error: SQLServerAgent could not be started (reason: SQLServerAgent must be able to connect to SQLServer as SysAdmin, but '(Unknown)...
0
votes
1answer
111 views

SQLite optimizations for possible huge data storage

I want use SQLite database as the storage for possible huge data size, I need some comments about optimization to keep stability (like unexpexted epic fails, BSOD for example) with fast access speed. ...
0
votes
1answer
181 views

Joining two database tables into one

I have a database with two tables. Each table has different structure but they do share few common fields. Simplified example: Table1 field structure: Field1, Field2, Field3, Field4 Table2 field ...
3
votes
1answer
177 views

MySQL Workbench team strategy

I'm considering to use MySQL Workbench at work, mainly because of the modelling tools and to easily sync the development and the production DBs. I work with another developer on the same project, and ...
0
votes
2answers
1k views

Percona xtradb cluster node2 won't start

I have configured Percona Xtradb cluster 5.6. The first node starts fine when bootstrapped, but the second node seems to have an issue with this variable setting: wsrep_provider=/usr/lib/...
1
vote
1answer
186 views

Using the value of a JSON object that is stored in a PostgreSQL JSON array

I have a table that looks like this (simplified): Jobs ------------------------------- ID | Details ------------------------------- 1 | { 'tasks': [] } 2 | { 'tasks': [{'id': '1', 'due_on': '2015-...
0
votes
2answers
82 views

Count of distinct values of a table using sql

name number ============= lin | 8 lin | 8 lin | 8 rob | 8 rob | 8 rob | 8 lin | 8 lin | 41 lin | 41 rob | 41 and I want the result like name | Count of 8 | count of 41 ===...
0
votes
1answer
1k views

Is it possible to change ER diagram style in MySQL Workbench? How?

I am really new to database visualization. I am creating the ER diagram of my databases. I am using MySQL Workbench 6.3 (community version). I am creating the diagram using the default style. The ...
0
votes
0answers
32 views

No data transferred when trying to transfer columns from one database to another [closed]

I'm trying to transfer columns from one database to another using the following: INSERT INTO ykz2d_purchas_integration (name, amount, summary) SELECT user_email, orderpayment_amount, ...
-1
votes
1answer
262 views

mySQL Failed and Recovered

For some reason mySQL keeps failing and recovering through the day. We have increased max database connections from 150 to 200, but that was not the problem and did not solve the issue. Does anyone ...
0
votes
1answer
103 views

How to organize long Query

I have a massive query string that I am trying to pick apart for a project I am working on. I am looking for some guidance on how to take it apart(format it into human readable). Also, what are the ...
1
vote
1answer
363 views

Debug why MySQL/mariadb table is crashing

I have a MyISAM table that keeps crashing. How would I figure out why it is crashing? The error messages say nothing other than that it crashed. Is there a log setting I could activate? This is ...
2
votes
1answer
171 views

What data structure is used for MongoDB 3.x geospatial indexes?

For the MongoDB 3.x geospatial features what structure is used for the indexes? B-tree? R-tree? X-tree? I can't find any information about the structures in their documentation
-1
votes
3answers
504 views

webscalesql vs mysql. Which to use? [closed]

I am confused on what the difference is between webscalesql and mysql. From my understanding webscalesql is a branch of mysql. Does this mean that webscalesql is a subset of mysql, so it is better to ...
2
votes
1answer
267 views

How to select from 3 tables while using count on 1, and sum on another?

I'm stuck on this one query. Here is my setup: table 1 (shows) show_user show_count table 2 (views) view_user view_views table 3 (users) user user_name What I need to is produce results ...
4
votes
1answer
1k views

Truncate log file mirrored database

In SQL Server 2008, I have a mirrored database with a log file that has increased to 80GB, which is not normal and I have serious problem. I would like to decrease the log file size by truncating it. ...
0
votes
1answer
101 views

Login timeout expired

I am using a program that is connected to SQL Server. The program has started giving 'login timeout expired' errors. If I login to SSMS and query the database the program connects and it fails again ...
0
votes
2answers
50 views

When rows of a resultset are generated?

Consider a client which asks MySQL server for 100000 rows, but retrieves rows later one-by-one. Does MySQL server generate the entire resultset before sending to client, or does it generate rows ...
1
vote
2answers
68 views

Is LIMIT processed before or after retrieving data?

MySQL. My heavy query crashed our MySQL server. If I add LIMIT 10 will it make my query more lightweight? (both for indexed and unindexed queries). Which way LIMIT are processed: before the rest of ...
0
votes
0answers
12 views

Truncate log file mirrored database [duplicate]

In SQL Server 2008, I have a mirrored database with a log file that has increased to 80GB, which is not normal and I have serious problem. I would like to decrease the log file size by truncating it. ...
2
votes
1answer
506 views

Exclusively access a table and prevent other queries, even read queries

I'm stuck at setting transaction isolation level. Here's my scenario that happens in the application: Get unprocessed messages (using the IsProcessing flag) Set their IsProcessing to true (in RAM) ...
1
vote
0answers
128 views

SQL Server losts and shows error 26 after random time

I have a Windows Server 2012 as server, which have SQL Server 2008 R2 where our database is stored. We have another 5 PC's installed with Windows 7 64-bit, which are run under domain of above server, ...
1
vote
2answers
1k views

the cache hit rate using pg_statio_user_tables

I read from this blog that a small 20% of the data in your database is getting the vast 80% of reads. That means a small portion of the data in the database is frequented. Hence, you want to ensure ...
1
vote
1answer
190 views

SQL Server 2008 R2 Express Connection

I installed SQL Server 2008 R2 Express Edition. I opened the command prompt and typed sqlcmd -S server1\SQLExpress -U SqlUserAccount -P SqlPassword to connect to SQL Server. However, it ...
0
votes
1answer
1k views

TSQL Copy an existing database

I am learning how to administrate MS Sql server 2012, come cross a question and its suggested solution for copying an existing database for different name. Administer a windows azure sql database ...
0
votes
1answer
81 views

Getting Skewed Results from LEFT OUTER JOIN with 3 TABLES

I have 3 tables, users (user info), mghours (volunteer time), mgtraining (training time). I want a result that lists some user columns, sum of volunteer hours and sum of two types of training: uid ...
3
votes
3answers
461 views

How to prevent a PostgreSQL trigger from being fired by another trigger?

I have 2 triggers on one table; one works for INSERTs : CREATE TRIGGER "get_user_name" AFTER INSERT ON "field_data" FOR EACH ROW EXECUTE PROCEDURE "add_info"(); This updates some values in the ...
1
vote
1answer
235 views

Referral table structure

I need to make a simple referral system and I have a database table set out as follows: mem_id | date | refer_email | accepted And the meaning of such columns is the following: mem_id: The ...
0
votes
0answers
35 views

How mysql order data without order by clause? [duplicate]

Is there any way to order data without order by clause in MYSQL? select * from table table name order by col1 asc.
2
votes
1answer
452 views

Modify LISTAGG query for 10g

below mentioned code for cursor works only in Oracle 11g, as LISTAGG() function introduced starting version 11g. I need to adapt this code for Oracle 10g. Any help would be appreciated. SELECT ...
0
votes
0answers
281 views

How to find cause of SQL-Server Full-Text Index Auto-Population Error?

I have recently added a few full text indices to a database and AUTO populating is not working as I would have expected. Sample Table Definition CREATE TABLE [wrk].[WorkOrder] ( [id] ...
2
votes
1answer
426 views

Have foreign key constraint and index key for the same column(s)

I am creating a composite index key for 2 columns and then adding foreign keys to its appropriate table. Do I need to create a multiple index key reference and then create separate foreign keys? My ...
1
vote
1answer
93 views

MySQL Crashing every few days

Our website hasn't launched yet so we're gaining little to no traffic at the moment. For some strange reason MySQL seems to crash every 2-3 days unexpectedly. Here's the SQL log of the crash 2015-06-...
0
votes
2answers
123 views

Query syntax is checked at java level or Database Level?

If i used normal JDBC Connection for accessing database of Mysql, The syntax of query is checked at java level or Mysql level. Example String Query="Select * fromEMP" above wrong query syntax throw ...
0
votes
0answers
40 views

Get last updated date and group by in mysql

trans_id | item_id | price | last_updated 01 |001 | 100 | 2015-01-01 02 |002 | 200 | 2015-01-02 03 |001 | 150 | 2015-01-03 03 |003 | 200 | 2015-01-...
0
votes
2answers
35 views

MySQL security group view permission query

I have a table of records that are only viewable by users with the correct group permission. The records may be viewable by multiple groups. Users may also be in multiple groups. record +----+-------...
1
vote
1answer
31 views

Completely removing InnoDb tables

To cut a long story short, I deleted several .idb files and then tried to re-import them from a .sql file. I'd imagine there is some relic of the old tables somewhere. Does anyone know what to remove ...
1
vote
2answers
315 views

How to prevent a trigger from running on certain statements?

I'm looking for an answer that satisfies my need on both SQL Server and MySQL. I have a small, custom audit table that I will be writing to through triggers on various tables. There are situations ...
1
vote
0answers
135 views

BDR Replication issue

I am trying to setup 2-node BDR replication and i am getting the following error while running bdr_init_copy. /usr/pgsql-9.4/bin/bdr_init_copy -d "host=10.10.145.111 dbname=apimgtdb port=5432" -...
1
vote
3answers
526 views

Are TEXT fields stored separately from the row in MySQL-ISAM?

We have a "notes" table and some of the queries are getting very slow even though we're not searching on the note contents. We're wondering if moving the note content into a separate table would speed ...
1
vote
1answer
341 views

TempDB Autogrowth - Does SQL need a restart?

I have a case where i'm running into an issue with the tempdb not being large enough. Here is my error: Could not allocate a new page for database 'TEMPDB' because of insufficient disk space in ...
2
votes
1answer
91 views

Why do database servers have different time_source values

I have two SQL 2008 R2 Enterprise SP1 servers that have different values for sys.dm_os_sys_info.time_source. The time_source column of sys.dm_os_sys_info indicates the API that SQL Server is using to ...
2
votes
1answer
135 views

Controlling how tempdb activity is split across drives (tempdb on both solid state and spinning drives)

I'm seeing the following tempdb I/O behavior over a one hour period: There is a fair amount of disk I/O generated by multiple DW workloads executing on the machine, some of which cannot fit in the ~...
0
votes
1answer
317 views

Cannot rename database (the user in --username is the owner)

I connect with psql and list my databases: List of databases Name | Owner | Encoding | Collate | Ctype | Access ...
1
vote
1answer
172 views

MySQL Database Keeps Crashing

Our mysql instance is keep crashing after every 5-10 minutes very frequently. We have around 600 databases on that instance. I think 600 is not a big number of databases given the size of databases ...
0
votes
0answers
30 views

2012 Always on (AG only) Where should the Windows Cluster SIT?

2012 Always On and the Windows Cluster, shouldn't the Windows Cluster be on a separate server like the Domain controller/BackupDomainController? With Windows clustering Services on each node ...

15 30 50 per page