The example we will discuss is a database of materials science research data created and populated using DBgen called ESAMP, which stands for "Event-Sourced Architecture for Materials Provenance." To give a sense of the inherent complexity of the problem, in materials science research, a material sample of interest is usually derived from one or many other samples through a series of procedures. Each procedure may produce one or many data files, which may be used in one or many analyses to yield results that are of interest to the researcher. Some analyses depend on other analyses having already been carried out. A query against the database should be able to answer complicated questions like, "show the top 10 best-performing batteries as determined by a specific lifetime test that were derived from anodes that are at least 10% cobalt as determined by X-ray photo-electron spectroscopy (XPS), and exclude any batteries that have the solvent that arrived on May 18th anywhere in their processing history."