Introduction
Often, when working with databases (particularly relational databases), a visual model of the database is not available, but is necessary for formulating queries. This is a more common problem in practice then one would imagine.
Errata
None collected yet. Let us know.
LS0tCnRpdGxlOiAiUmV2ZXJzZSBFbmdpbmVlcmluZyBWaXN1YWwgTW9kZWxzIGZyb20gUmVsYXRpb25hbCBEYXRhYmFzZXMiCnBhcmFtczoKICBjYXRlZ29yeTogMzAKICBzdGFja3M6ICIwLDAiCiAgbnVtYmVyOiAxNDAKICB0aW1lOiA0NQogIGxldmVsOiBiZWdpbm5lcgogIHRhZ3M6IEx1Y2lkQ2hhcnQsVU1MLEVSRCxWaXN1YWwgTW9kZWxpbmcsUmV2ZXJzZSBFbmdpbmVlcmluZwogIGRlc2NyaXB0aW9uOiAiUmV2ZXJzZSBlbmdpbmVlcmluZyBFUkQgYW5kIFVNTCBtb2RlbHMgZnJvbSBhIHJlbGF0aW9uYWwgZGF0YWJhc2UuIgpkYXRlOiAiPHNtYWxsPmByIFN5cy5EYXRlKClgPC9zbWFsbD4iCmF1dGhvcjogIjxzbWFsbD5NYXJ0aW4gU2NoZWRsYmF1ZXI8L3NtYWxsPiIKZW1haWw6ICJtLnNjaGVkbGJhdWVyQG5ldS5lZHUiCmFmZmlsaXRhdGlvbjogIk5vcnRoZWFzdGVybiBVbml2ZXJzaXR5IgpvdXRwdXQ6IAogIGJvb2tkb3duOjpodG1sX2RvY3VtZW50MjoKICAgIHRvYzogdHJ1ZQogICAgdG9jX2Zsb2F0OiB0cnVlCiAgICBjb2xsYXBzZWQ6IGZhbHNlCiAgICBudW1iZXJfc2VjdGlvbnM6IGZhbHNlCiAgICBjb2RlX2Rvd25sb2FkOiB0cnVlCiAgICB0aGVtZTogc3BhY2VsYWIKICAgIGhpZ2hsaWdodDogdGFuZ28KLS0tCgotLS0KdGl0bGU6ICI8c21hbGw+YHIgcGFyYW1zJGNhdGVnb3J5YC5gciBwYXJhbXMkbnVtYmVyYDwvc21hbGw+PGJyLz48c3BhbiBzdHlsZT0nY29sb3I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