{
  "tables": {
    "metadata": [
      {
        "name": "schema_meta",
        "columns": ["key", "value"]
      }
    ],

    "taxonomy": [
      {
        "name": "category",
        "columns": [
          "id",
          "parentId",
          "title",
          "level",
          "orderIndex",
          "heShortDesc",
          "heDesc"
        ]
      },
      {
        "name": "category_closure",
        "columns": [
          "ancestorId",
          "descendantId"
        ]
      }
    ],

    "bibliography": [
      { "name": "author", "columns": ["id", "name"] },
      { "name": "topic", "columns": ["id", "name"] },
      { "name": "generation", "columns": ["id", "name"] },
      { "name": "pub_place", "columns": ["id", "name"] },
      { "name": "pub_date", "columns": ["id", "date"] },
      { "name": "source", "columns": ["id", "name"] }
    ],

    "books": [
      {
        "name": "book",
        "columns": [
          "id",
          "categoryId",
          "sourceId",
          "title",
          "heRef",
          "heShortDesc",
          "heDesc",
          "notesContent",
          "orderIndex",
          "totalLines",
          "isBaseBook",
          "hasTargumConnection",
          "hasReferenceConnection",
          "hasSourceConnection",
          "hasCommentaryConnection",
          "hasOtherConnection",
          "hasAltStructures",
          "hasTeamim",
          "hasNekudot",
          "dependenceType",
          "collectiveTitleHe",
          "collectiveTitleEn"
        ]
      }
    ],

    "book_relations": [
      "book_author",
      "book_topic",
      "book_generation",
      "book_pub_place",
      "book_pub_date",
      "book_base_text",
      "book_acronym",
      "default_commentator",
      "default_targum"
    ],

    "text_content": [
      {
        "name": "line",
        "columns": [
          "id",
          "bookId",
          "lineIndex",
          "content",
          "heRef",
          "tocEntryId",
          "charCount"
        ]
      },
      {
        "name": "version_line",
        "columns": [
          "versionId",
          "lineId",
          "content",
          "charCount"
        ]
      }
    ],

    "versions": [
      {
        "name": "book_version",
        "columns": [
          "id",
          "bookId",
          "versionTitle",
          "heVersionTitle",
          "versionSource",
          "priority",
          "license",
          "versionNotes",
          "heVersionNotes",
          "hasContent"
        ]
      }
    ],

    "toc": [
      {
        "name": "tocText",
        "columns": ["id", "text"]
      },
      {
        "name": "tocEntry",
        "columns": [
          "id",
          "bookId",
          "parentId",
          "textId",
          "level",
          "lineId",
          "isLastChild",
          "hasChildren"
        ]
      },
      {
        "name": "line_toc",
        "columns": [
          "lineId",
          "tocEntryId"
        ]
      }
    ],

    "alternate_toc": [
      {
        "name": "alt_toc_structure",
        "columns": [
          "id",
          "bookId",
          "key",
          "title",
          "heTitle"
        ]
      },
      {
        "name": "alt_toc_entry",
        "columns": [
          "id",
          "structureId",
          "parentId",
          "textId",
          "level",
          "lineId",
          "isLastChild",
          "hasChildren"
        ]
      },
      {
        "name": "line_alt_toc",
        "columns": [
          "lineId",
          "structureId",
          "altTocEntryId"
        ]
      }
    ],

    "links": [
      {
        "name": "connection_type",
        "columns": [
          "id",
          "name"
        ]
      },
      {
        "name": "link",
        "columns": [
          "id",
          "sourceBookId",
          "targetBookId",
          "sourceLineId",
          "targetLineId",
          "targetLineIndex",
          "targetBookOrderIndex",
          "connectionTypeId",
          "baseProvenance"
        ]
      },
      {
        "name": "link_anchor",
        "columns": [
          "linkId",
          "side",
          "charStart",
          "charEnd",
          "label"
        ]
      },
      {
        "name": "link_range",
        "columns": [
          "linkId",
          "side",
          "endLineId",
          "endLineIndex"
        ]
      },
      {
        "name": "link_coverage",
        "columns": [
          "lineId",
          "linkId",
          "side"
        ]
      },
      {
        "name": "book_has_links",
        "columns": [
          "bookId",
          "hasSourceLinks",
          "hasTargetLinks"
        ]
      }
    ]
  }
}