def METHOD_NAME(db):
    # Populate job status lookup table
    for js in JOB_STATUS:
        baker.make("download.JobStatus", job_status_id=js.id, name=js.name, description=js.desc)
    # Create Awarding Top Agency
    ata1 = baker.make(
        "references.ToptierAgency",
        name="Bureau of Things",
        toptier_code="100",
        website="http://test.com",
        mission="test",
        icon_filename="test",
    )
    ata2 = baker.make(
        "references.ToptierAgency",
        name="Bureau of Stuff",
        toptier_code="101",
        website="http://test.com",
        mission="test",
        icon_filename="test",
    )
    # Create Awarding subs
    baker.make("references.SubtierAgency", name="Bureau of Things")
    # Create Awarding Agencies
    aa1 = baker.make("references.Agency", id=1, toptier_agency=ata1, toptier_flag=False)
    aa2 = baker.make("references.Agency", id=2, toptier_agency=ata2, toptier_flag=False)
    # Create Funding Top Agency
    ata3 = baker.make(
        "references.ToptierAgency",
        name="Bureau of Money",
        toptier_code="102",
        website="http://test.com",
        mission="test",
        icon_filename="test",
    )
    # Create Funding SUB
    baker.make("references.SubtierAgency", name="Bureau of Things")
    # Create Funding Agency
    baker.make("references.Agency", id=3, toptier_agency=ata3, toptier_flag=False)
    # Create Awards
    award1 = baker.make(
        "search.AwardSearch",
        award_id=123,
        piid="tc1piid",
        category="idv",
        type="IDV_A",
        action_date="2018-01-01",
        awarding_agency_id=aa1.id,
        generated_unique_award_id="CONT_IDV_tc1piid_123",
    )
    award2 = baker.make(
        "search.AwardSearch",
        award_id=456,
        piid="tc2piid",
        category="contracts",
        type="A",
        action_date="2018-01-01",
        awarding_agency_id=aa2.id,
        generated_unique_award_id="CONT_AWD_tc2piid_456",
    )
    award3 = baker.make(
        "search.AwardSearch",
        award_id=789,
        fain="ta1fain",
        category="assistance",
        type="02",
        action_date="2018-01-01",
        awarding_agency_id=aa2.id,
        generated_unique_award_id="ASST_NON_ta1fain_456",
    )
    # Create Transactions
    baker.make(
        TransactionSearch,
        transaction_id=1,
        is_fpds=True,
        award=award1,
        action_date="2018-01-01",
        type=random.choice(list(award_type_mapping)),
        modification_number=1,
        awarding_agency_id=aa1.id,
        piid="tc1piid",
    )
    baker.make(
        TransactionSearch,
        transaction_id=2,
        is_fpds=True,
        award=award2,
        action_date="2018-01-01",
        type=random.choice(list(award_type_mapping)),
        modification_number=1,
        awarding_agency_id=aa2.id,
        piid="tc2piid",
    )
    baker.make(
        TransactionSearch,
        transaction_id=3,
        is_fpds=False,
        award=award3,
        action_date="2018-01-01",
        type=random.choice(list(award_type_mapping)),
        modification_number=1,
        awarding_agency_id=aa2.id,
        fain="ta1fain",
    )
    # Set latest_award for each award
    update_awards()