 
			 
			MCQOPTIONS
 Saved Bookmarks
				This section includes 10 Mcqs, each offering curated multiple-choice questions to sharpen your Technical MCQs knowledge and support exam preparation. Choose a topic below to get started.
| 1. | What is the type of weights parameter in createIndex()? | 
| A. | Boolean | 
| B. | string | 
| C. | integer | 
| D. | document | 
| E. | |
| Answer» E. | |
| 2. | What is the type of sparse parameter in createIndex()? | 
| A. | Boolean | 
| B. | string | 
| C. | integer | 
| D. | document | 
| Answer» B. string | |
| 3. | The maximum value of weights parameter is: | 
| A. | 999 | 
| B. | 9999 | 
| C. | 99999 | 
| D. | 99 | 
| Answer» D. 99 | |
| 4. | Which method returns the description of all the indexes int the collection? | 
| A. | putIndexes() | 
| B. | setIndexes() | 
| C. | getIndexes() | 
| D. | All of the above | 
| Answer» D. All of the above | |
| 5. | Which method deletes multiple (specified) indexes on a collection? | 
| A. | dropIndexes() | 
| B. | dropIndex() | 
| C. | Both A and B can be used | 
| D. | getIndexes() | 
| Answer» B. dropIndex() | |
| 6. | The default value of default_language Parameter is : | 
| A. | Mongo | 
| B. | DB | 
| C. | Mongod | 
| D. | English | 
| Answer» E. | |
| 7. | The default value of background Parameter is : | 
| A. | TRUE | 
| B. | FALSE | 
| C. | 0 | 
| D. | 1 | 
| Answer» C. 0 | |
| 8. | To create index in descending order, the value of key is? | 
| A. | 1 | 
| B. | 0 | 
| C. | -1 | 
| D. | infinite | 
| Answer» D. infinite | |
| 9. | Which of the following iis correct syntax of createindex? | 
| A. | db.COLLECTION_NAME.createIndex({KEY:1}) | 
| B. | COLLECTION_NAME.createIndex({KEY:1}) | 
| C. | db.COLLECTION_NAME.createIndex | 
| D. | db.createIndex({KEY:1}) | 
| Answer» B. COLLECTION_NAME.createIndex({KEY:1}) | |
| 10. | How to create index in mongoDB? | 
| A. | index() | 
| B. | createIndex() | 
| C. | putIndex() | 
| D. | getIndex() | 
| Answer» C. putIndex() | |