Posts Tagged ‘No Schema’

When Worlds Collide! Kapow! Writing and Database Design

Sunday, February 14th, 2016

I continue to marvel at the intersection of my writing life and my tech life. One of my job functions is to architect databases that will hold the information that runs websites or pays bills or, report on the information in the database. It’s remarkably easy to get wrong. Because I’m a data architect and not a software developer, my approach is always, how would I set this up so we meet the users needs and protect the data?

Every software dev is now slapping her/his forehead and groaning.

Dude. We’ll negotiate the joins later, OK?

But no. We’re not doing it your way because your way is fast on the app side and 30 days later we can’t report on the data. Or it’s not actually what the user needs.

So. Authors who write series, often more than one, need a way to show readers the order of the books in the series. Sounds simple, right? Let the author number the books from 1 through a bazillion.

(And now all the authors are now groaning, going, wait! What about prequels, novels and novellas? where I didn’t write them in chronological order or where readers want Novel order interspersed with Novellas … without having to number Book 7 in the series 9th in the order because there are intervening novellas or short stories.)

Readers are doing much the same.

I know, I know. And I’m so sorry.

surprise/not surprised

I’m surprise/not surprised that ALL the book vendors have gotten the design of this wrong. It SOUNDS easy, but it’s not. We all see the huge disconnect between all the vendors who went “Let them number the books IN WHOLE NUBMERS!” and what authors and readers actually need.

A structured database, like SQL Server or Oracle could do this of course. So could a NoSQL db, but either way you still have to understand this isn’t just a numbering problem. NoSQL probably makes this easier to achieve.

But is OBVIOUS no one at the vendors actually talked to enough authors or even publishers about this. If they had, they’d know they were about to design it wrong.

Painful Lessons of Bad Data Architecture

One of the early lessons for any database person is that when the structure doesn’t provide users a way to do what is needed in real life, they will find workarounds that fuck up your data.

Like when there’s no field to hold (easy example) a middle name and someone goes by their middle name. Users will enter the middle name in the first name field OR the last name field, or a field for Company name. And then you are fucked because you have no way easy way to know that Roberta Ellen Smith is in your database as

firstname: Roberta Ellen
LastName: Smith
CompanyName: Acme Widgets

AND/Or
firstname: Roberta
LastName: Ellen Smith
CompanyName: Acme Widgets

AND/OR
firstname: Roberta
LastName: Ellen
CompanyName: Smith/Acme Widgets

Now get me a list of all the people whose last name is Smith.
Oops.

I’m not making this up, except the names. I’ve seen databases like this.

Real World Reading and Writing

In the real world of reading and authoring books, a series can have:
Novels
Novellas
Short stories
Something else we didn’t think of yet.

And the order might go like this:

Book 1
Book 2
Novella 1
Book 3
Short Story 1
Book 4
Novella 2

AND it’s possible the author wrote these stories in this order

Short Story 1
Book 2
Book 3
Book 4
Book 1
Novella 2
Novella 1

So that by the time they’ve written novella 1, which in the chronology of events in the SERIES places Novella 1 chronologically before Book 3, they will need to reorder their books.

How do I know this is possible? Because I’m a data architect and I’ve seen stuff like this before but also because here’s the story series order of my Sinclair Series books:

Books in chronological order according to the World
Mary’s story
Anne’s Story
Lucy’s Story
Emily’s Story

Here’s the order I have written or will write them in:

Anne’s Story
Lucy’s Story
Emily’s Story
Mary story

Why? Because PUBLISHING doesn’t commit to series and sometimes neither do authors. A book that was intended as a stand alone turns out to have characters in it readers are dying to read about, and some of those characters’ stories would be BEFORE the time setting of the book that was published first.

Authors commonly want to number books like this:

Prequel (Book 0)
Book 1
Novella 1.5
Book 2
Book 3
Novella 3.5

Which is a fairly obvious solution from their point of view, but with clear issues on the backend if you only allow the number field to accept whole numbers which everyone except All Romance eBooks does.

That’s the problem with the simplistic notion that Books are ordered 1, 2, 3, 4 . . . . N

Authors and Readers – in the same leaky Boat

Readers might want to read the books, regardless of length or nomenclature (novel, novella etc.) in the order they were written. Or chronologically according to events in the series. Or in some order the author has provided for the series.

So, on the backend, book order is actually considerably more fluid than any vendor currently provides to authors who would like to number their books so readers can figure out which stories they want to read first.

So vendors end up giving us this, which is completely inadequate for authors and readers alike.
Book 1 = Book 1
Book 2 = Book 2
Book 3 = Novella 1
Book 4 = Book 3
Book 5 = Short Story 1
Book 6 = Book 4
Book 7 = Novella 2
Book 8 = Book 5

Because to get the books listed in reading order authors have to say Book 5 is Book 8 when it isn’t book 8.

Obviously, you should allow the author to provide a reading order that does not link reading order to nomenclature.

1 = Book 1
2 = Book 2
3 = Novella 1
4 = Book 3
5 = Short Story 1
6 = Book 4
7 = Novella 2
8 = Book 5

So, you show the end user this:

Vampire Flowers Series – Reading Order

Flowers in My Garden, prequel
Flowers in my Sock drawer, Book 1
The Gnome Attack, Novella 1
Flowers in my mailbox, Book 2
Gnome Attack!!, A short story
Bees Knees, Novella 2

Reading Order, as a numbering concept unrelated to any other order, would also permit a reader to get a list of just the novels, in reading order.

But nobody asked me.

Share