We are creating an OMOP CDM system to collect and analyze data from several sites. I installed Atlas using Broadsea. One of the steps listed in CDM Configuration for use with WebAPI is to use WebAPI to create an SQL file. Our OMOP CDM database is SQL Server, so I used this URL:
https://.../WebAPI/ddl/results?dialect=sql%20server&schema=[site name]_Achilles_Results&vocabSchema=[XXX]&tempSchema=[site name]]_Achilles_Temp&initConceptHierarchy=true
The resulting SQL file is some 2800 lines long and has four sections: (1) create tables; (2) queries to load data into Achilles concept_hierarchy; (3) load data into herakles_analysis; (4) and create indexes. The problem is in section 2, which consistently fails with
Msg 1101, Level 17, State 10, Line 630
Could not allocate a new page for database 'TEMPDB' because of insufficient disk space in filegroup 'DEFAULT'. Create the necessary space by dropping objects in the filegroup, adding additional files to the filegroup, or setting autogrowth on for existing files in the filegroup.
TempDB is 60 GB and is empty when I start. For TempDB, both ROWS Data and LOG are allocated with Autogrowth By 64 MB, Maxsize Unlimited.
I've managed to narrow down the problem to two of the concept_hierarchy operations: MEASUREMENT and OBSERVATION. Unsurprisingly, these are the largest tables. Removing those allowed the whole SQL file to run to completion.
In response to a suggestion, I tried putting BEGIN TRANSACTION and COMMIT TRANSACTION pairs around each concept_hierarchy segment, but that had no effect.
Any ideas for how to diagnose or resolve this?