Database Administrators Weekly Newsletter
Database Administrators Weekly Newsletter

Top new questions this week:

Constraint to enforce "at least one" or "exactly one" in a database

Say we have users and each user can have multiple email addresses CREATE TABLE emails ( user_id integer, email_address text, is_active boolean ) Some sample rows user_id | ...

postgresql database-design constraint ddl referential-integrity  
asked by Kevin Burke 8 votes
answered by Erwin Brandstetter 6 votes

Windowing offset based on time stamp

I'm writing a query that will be used to page results for a social feed. The concept is the mobile app will request N items, and provide a starting datetime which I have called @CutoffTime below. ...

sql-server azure-sql-database window-functions paging  
asked by Erik 7 votes
answered by Mikael Eriksson 2 votes

NoSQL : What is unstructured data?

we are currently running at the edge of resources with our mssql server based solution. We have now many traditional options regarding the next move to tackle the load: buy faster CPUs and IO ...

sql-server database-design nosql cassandra  
asked by thst 7 votes
answered by Michael Green 3 votes

Entity relationship problem

I think my question is stupid but I just can't figure out how to solve it: I have 4 tables related like this (it's an example): Company: ID Name CNPJ Department: ID Name Code ID_Company ...

database-design constraints  
asked by user73860 6 votes
answered by Todd Everett 5 votes

Azure: Many Failed Login Attempts Logged

I run a SQL Server on an Azure Virtual Machine. I have noticed in the Event Logs of the server lots of failed SQL Login attempts using a ton of different usernames (none of which exist): Login ...

sql-server security logs logins azure-vm  
asked by Tom McClean 6 votes
answered by James Lupolt 6 votes

Implementing versioning system with MySQL

I know this has been asked here and here, but I have the same idea with a different possible implementation and I need some help. Initially I had my blogstories table with this structure: | Column ...

mysql database-design  
asked by Victor 6 votes
answered by MDCCL 7 votes

SQL Server, set of tables grow and shrink by large amounts. How to allocate

I have a SQL Server 2014 database with 100+ tables that have a 5% growth rate over the course of a year. Lots of reading, very little writing. This database is going to expand by another set of 20+ ...

sql-server scalability  
asked by Clinton Pierce 5 votes
answered by Max Vernon 0 votes

Greatest hits from previous weeks:

Import a Oracle DMP file into a Fresh install of oracle

A client sent us a oracle database we need to test against. We don't use oracle or have any oracle expertise in house. We need to setup the database so we can connect to it and debug a problem. I ...

oracle import  
asked by James 15 votes
answered by Andrew 16 votes

Cannot connect to my local instance

When I connect to my local server, I get this message A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not ...

sql-server-2008-r2 connectivity  
asked by zey 2 votes
answered by JP Chauhan 3 votes

Can you answer these?

SQL Server 2008 R2 - Two Files Stuck In Restoring Status

Background: SQL Server 2008 R2 mirrored and clustered. We recently failed over the databases via mirror and everything went smoothly. When it was time to do a differential backup, I got an error so I ...

sql-server-2008-r2 database-mirroring datafile filegroups  
asked by dajonx 2 votes

Any way to ensure that Change Data Capture clean up process does not delete the change data that you haven't processed yet?

I'm using CDC feature to track changes that are being made, since the cleanup period is set to 3 days by default, I have to run jobs to archive this change data from the CDC system tables to my ...

sql-server change-data-capture archive  
asked by Ritesh Bhakre 2 votes

Mysql History Trigger Auto Increment bug or problem

I want to log history of a table, I created a history table and triggers for update,insert and delete operations. I do my test on realtime replication slave. When a record inserted master's main ...

mysql trigger auto-increment  
asked by mrcoder 2 votes
Subscribe to more Stack Exchange newsletters

Unsubscribe from this newsletter or change your email preferences by visiting your subscriptions page on

Questions? Comments? Let us know on our feedback site. If you no longer want to receive mail from Stack Exchange, unsubscribe from all emails.

Stack Exchange, Inc. 110 William St, 28th Floor, NY NY 10038 <3