Data model
Pubs publishing database
Logical record types and their declared fields.
draftModule version 0.1.0
Registered DataModel
Provenance
draftModule version 0.1.0MIT
- Module
github.com/demo-db/pubs/pubs- Version
0.1.0- Repository
- https://github.com/demo-db/pubs
- Source commit
e99ca33330a043e23b2c5a665356fb8ad8d0b508- MeaningGraph revision
67a8f0ad0135ac5e51785e1899ad9d75761e7adf6bd03ff10afc51f7cd99c449- ModelSpec source
model/pubs.modelspec.hcl- ModelSpec AST
model/pubs.modelspec.json- Archived definition
- Download the exact registered definition
- Archived source files
data-source/LICENSE.txtLICENSEmodel/pubs.modelspec.hclmodel/pubs.modelspec.json
Logical structure
Record types
Record type
authors
Key: au_id
au_idstringRequiredKey fieldau_lnamestringRequiredau_fnamestringRequiredphonestringRequiredaddressstringcitystringstatestringzipstringcontractintRequired
Record type
discounts
No key declared
discounttypestringRequiredstor_idrecord referenceRecord:storeslowqtyinthighqtyintdiscountdecimalRequired
Record type
employee
Key: emp_id
emp_idstringRequiredKey fieldfnamestringRequiredminitstringlnamestringRequiredjob_idrecord referenceRecord:jobsRequiredjob_lvlintpub_idrecord referenceRecord:publishersRequiredhire_datestringRequired
Record type
jobs
Key: job_id
job_idintRequiredKey fieldjob_descstringRequiredmin_lvlintRequiredmax_lvlintRequired
Record type
pub_info
Key: pub_id
pub_idrecord referenceRecord:publishersRequiredKey fieldlogodocumentpr_infostring
Record type
publishers
Key: pub_id
pub_idstringRequiredKey fieldpub_namestringcitystringstatestringcountrystring
Record type
roysched
No key declared
title_idrecord referenceRecord:titleslorangeinthirangeintroyaltyint
Record type
sales
Key: stor_idord_numtitle_id
Record type
stores
Key: stor_id
stor_idstringRequiredKey fieldstor_namestringstor_addressstringcitystringstatestringzipstring
Record type
titleauthor
Key: au_idtitle_id
Record type
titles
Key: title_id
title_idstringRequiredKey fieldtitlestringRequiredtypestringRequiredpub_idrecord referenceRecord:publisherspricedecimaladvancedecimalroyaltyintytd_salesintnotesstringpubdatestringRequired