Click here to Skip to main content
15,434,078 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: Why stick to just one database? Pin
johnsyd19-Jun-13 18:07
Memberjohnsyd19-Jun-13 18:07 
GeneralRe: Why stick to just one database? Pin
PIEBALDconsult19-Jun-13 18:37
professionalPIEBALDconsult19-Jun-13 18:37 
GeneralRe: Why stick to just one database? Pin
vonb19-Jun-13 19:25
Membervonb19-Jun-13 19:25 
GeneralRe: Why stick to just one database? Pin
AlexCode19-Jun-13 20:23
professionalAlexCode19-Jun-13 20:23 
GeneralRe: Why stick to just one database? Pin
Adriaan Davel19-Jun-13 21:55
MemberAdriaan Davel19-Jun-13 21:55 
AnswerRe: Why stick to just one database? Pin
Gaston Verelst19-Jun-13 20:28
MemberGaston Verelst19-Jun-13 20:28 
GeneralRe: Why stick to just one database? Pin
cjb11019-Jun-13 21:15
Membercjb11019-Jun-13 21:15 
GeneralRe: Why stick to just one database? Pin
johnsyd25-Jun-13 15:01
Memberjohnsyd25-Jun-13 15:01 
If the databases are all on the same server instance, there is little performance impact. However if on different server instances, there is a big impact.

It complicates issues like disaster recovery - say if one of the databases fails over but the others don't. You also have to keep all the database permissions in synch which can become quite onerous. If a stored procedure accesses tables on 5 different databases it needs to preserve permissions on all of them. You also need to make sure the database-level settings are consistent. Backups need to be coordinated, so if a restore becomes necessary, you're using backups taken at the same time.

My issue is when you have related tables and someone splits them into multiple databases ... I can't see any benefit in the splitting and there are ongoing maintenance problems you introduce by doing it. You also have multiple points of failure. You may want to keep tables which are often JOIN'ed on different physical disks for performance, but another member mentioned that you can do this within the same database using FILEGROUPs.
GeneralRe: Why stick to just one database? Pin
Adriaan Davel19-Jun-13 21:59
MemberAdriaan Davel19-Jun-13 21:59 
GeneralRe: Why stick to just one database? Pin
Richard Deeming20-Jun-13 1:30
mveRichard Deeming20-Jun-13 1:30 
GeneralRe: Why stick to just one database? Pin
jim lahey20-Jun-13 2:04
Memberjim lahey20-Jun-13 2:04 
GeneralRe: Why stick to just one database? Pin
NeverJustHere20-Jun-13 19:29
MemberNeverJustHere20-Jun-13 19:29 
GeneralRe: Why stick to just one database? Pin
johnsyd25-Jun-13 15:15
Memberjohnsyd25-Jun-13 15:15 
GeneralRe: Why stick to just one database? Pin
johnsyd25-Jun-13 15:10
Memberjohnsyd25-Jun-13 15:10 
GeneralHow To Use Session Variables Pin
AnalogNerd18-Jun-13 3:43
MemberAnalogNerd18-Jun-13 3:43 
GeneralRe: How To Use Session Variables Pin
OriginalGriff18-Jun-13 5:04
mveOriginalGriff18-Jun-13 5:04 
GeneralRe: How To Use Session Variables Pin
imagiro19-Jun-13 7:53
Memberimagiro19-Jun-13 7:53 
GeneralRe: How To Use Session Variables Pin
AnalogNerd19-Jun-13 7:56
MemberAnalogNerd19-Jun-13 7:56 
GeneralRe: How To Use Session Variables Pin
imagiro19-Jun-13 21:55
Memberimagiro19-Jun-13 21:55 
GeneralRe: How To Use Session Variables Pin
ClockMeister20-Jun-13 2:03
professionalClockMeister20-Jun-13 2:03 
GeneralRe: How To Use Session Variables Pin
BrainiacV20-Jun-13 5:44
MemberBrainiacV20-Jun-13 5:44 
GeneralRe: How To Use Session Variables Pin
jcmaida20-Jun-13 6:10
Memberjcmaida20-Jun-13 6:10 
GeneralRe: How To Use Session Variables Pin
Bob100020-Jun-13 4:44
professionalBob100020-Jun-13 4:44 
GeneralRe: How To Use Session Variables Pin
User 483504720-Jun-13 3:25
MemberUser 483504720-Jun-13 3:25 
GeneralRe: How To Use Session Variables Pin
RafagaX20-Jun-13 4:44
professionalRafagaX20-Jun-13 4:44 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.