From 727db57799cd516db9c3e7b3011fed937c211dba Mon Sep 17 00:00:00 2001 From: Hongze Cheng Date: Tue, 15 Feb 2022 11:50:15 +0000 Subject: [PATCH] more TDB --- source/libs/tdb/src/db/tdb.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/libs/tdb/src/db/tdb.c b/source/libs/tdb/src/db/tdb.c index 9fe15ce156..0059fba191 100644 --- a/source/libs/tdb/src/db/tdb.c +++ b/source/libs/tdb/src/db/tdb.c @@ -104,6 +104,9 @@ int tdbOpen(TDB *pDb, const char *fname, const char *dbname, TENV *pEnv) { } // TODO: open the database (an existing or a new one) + // Search the page file master DB to check if the db exists + // If DB exists, get the root page number + // If DB not exists, create a new DB pDb->pPgFile = pPgFile; tdbEnvRgstDB(pEnv, pDb);