Hi @Anand_Vaidya1 welcome to the community!
I need to only create empty tables without default entries
The resource you’re looking for is probably https://www.mongodb.com/docs/manual/reference/method/db.createCollection/
In short, MongoDB uses a very different concept to SQL in managing your data.
Unlike the typical SQL workflow, MongoDB works very differently. Here, a “collection” is a collection of JSON-like documents. The “schema” here is more like uniformity of keys and values of the documents inside the collection. You don’t define the schema beforehand, the collection will be created automatically when you insert a new document into a non-existing collection, and you can have two documents that look very different from each other inside a single collection. It’s termed “flexible schema” in MongoDB.
This is quite different to SQL’s concept of tables and schemas, where you have to define a schema for every table. Thus, the concept of creating functions of CreateDB(), CreateTable(), WriteTable() etc. don’t have direct equivalents in MongoDB.
If you need specific help on what you need to do, please provide more details. e.g. what’s the WriteTable() function supposed to do? What’s the overall function of your application? And other relevant details.
Best regards
Kevin