121
Buggz
7y

I worked on a greenfield project a couple of years ago. The company had an old solution written in Omnis (heard of it? Yeah, me neither) with an SQL database. My team was to create a completely new web based system... on top of the old database, so the customers could keep their existing stuff.

The dba was an intelligent man, one of the nicest people I've met, and over the course of fifteen years he had made a remarkably terrifying monstrosity of a database. Some years before me they wanted to "future proof" the system and make it "easier to switch to new technologies". So they moved the entire business logic into the database...

I used a tool to create a visualization of said database when we started. It had no views, only tables and sprocs. Look at it! Tables and sprocs are rectangles (well, dots) and any connections are drawn in grey lines. There were no foreign keys, so a tables only visualization only yielded a collection of independent rectangles without a single line.

Now, the stored procedures were bloody MASSIVE. A single procedure that only registered a new interested party and attached them to a property had 2500+ lines and over 150 parameters.

Also, this dba added features and fixed bugs by logging into the respective customers production server and writing SQL.

That database is the stupidest thing I've ever seen a developer do.

Comments
  • 35
    OH GOD
    BURN THIS
  • 16
    Looks like a moon crater.
  • 3
    Which tool did you use?
  • 4
    @hypervtechnics One in the Redgate suite, can't remember the exact name.
  • 36
    At first glance I thought this was Antarctica.
    I suppose for a size comparison that's a fair assessment...
  • 16
    On the other hand. Making that program function in bloody sql is quite an achievement too.

    A terrible choice, but quite an achievement
  • 5
  • 3
    I thought our database was cluttered.
  • 2
    Is this a thing for a company? Greenfield Ethanol?
  • 6
    Burn this thing! Exterminate it, before it lay eggs and infect others.
  • 11
    I saw fractals in the thumbnail preview. Was somewhat disappointed. :(

    Nice rant though.
  • 1
    Wow my God 😱
  • 2
    Holy fuck 😱
  • 8
    I have to save this and whenever I stumble a bullshit legacy project of ours I look at this and remember: it could have been worse!
  • 4
    @scroach or you have a new picture too save
  • 8
    This is the worst database architecture I've ever seen.
  • 10
    At first glance, I confused the database structure with a fractal image. Holy cow, I suffer together with these poor servers...
  • 1
    Mother of god..
  • 2
    Lol the picture is cool though
  • 0
    @Tobyvw what would be a better choice and why in this case? - curious SQL user
  • 1
    I won't even ask if there's documentation for that monster, I would just say fuck that shit and good luck with it.
  • 0
    This makes me angry on so many levels....
  • 0
    HOLY SHIT MAN!
  • 0
    @hyperlisk This thing was the data AND business layer of an application for property brokers. And it did both auths too, so the new web application had to perform an sql connection using the supplied credentials to verify.
  • 2
    *grabs his SQL anti-patterns book*
  • 1
    @Shardj the sql to handle the db isn't wrong, but as @Buggz points out in his last comment, you have to put access credentials to the db like everywhere.
  • 3
    @Tobyvw is spot on, @Shardj It was mostly relational data so a relational database is great. One just has to remember that a relational database is, obviously, best at storing relational data. Once you start putting in functionality (or documents) you're doing it wrong and should sit in the corner.
  • 3
    So many lines of SQL just to print a Mandelbrot set? (Somewhere I saw it done in PostgreSQL, was neat,..but then there's probably an APL one liner - yep)
  • 0
    If you look closely, inside each rectangle there is another network of rectangles.
    That thing is really fractal-ed up.
  • 0
    That's the name of each table/sproc inside the rectangles. It's f-ed up enough, no need for another dimension.
  • 1
    @Buggz I'm talking about weather the company he did this for was Greenfield Global or Greenfield Ethanol?
  • 0
    Neither. Green field means starting from scratch making something new. This was a tool for property brokers.
  • 1
    @Buggz okok thanks
  • 0
    Oh

    my

    GOD

    ..

    I wish I didn't see this
  • 0
    Do we really want to know what procedure needs a finger in every pot in the entire system? That one dot scares me.
Add Comment