- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
George John has Published 1167 Articles
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
2K+ Views
In this program we will see how to add two 16-bit BCD numbers with carry.Problem StatementWrite 8086 Assembly language program to add two 16-bit BCD numbers stored in memory offset 500H – 501H and 502H – 503H.DiscussionHere we are adding the 16-bit data byte by byte. At first we are ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
599 Views
To get connected clients in MongoDB, use currentOp() with the set value to true and you need to iterate array result set with the help of field client. Let us first implement currentOp> db.currentOp(true)Following is the output. Here the client is 127.0.0.1 since we are using localhost. The output displays ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
227 Views
This example describes how to use the HttpSession object to find out the creation time and the last-accessed time for a session. We would associate a new session with the request if one does not already exist. Session Tracking ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
48 Views
The C++ function std::unordered_multimap::operator=() assigns new contents to the unordered_multimap by replacing old ones and modifies size if necessary.Following is the declaration for std::unordered_multimap::operator=() function form std::unordered_map() header.C++11 (Syntax)unordered_multimap& operator=(const unordered_multimap& umm);Parametersumm - Another unordered_multimap object of same type.Return ValueReturns this pointer.Example Code#include #include using namespace std; int ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
413 Views
To check if field is a number in MongoDB, use the $type operator. Following is the syntaxdb.yourCollectionName.find({youtFieldName: {$type:"number"}}).pretty();Let us first create a collection with documents> db.checkIfFieldIsNumberDemo.insertOne({"StudentName":"John", "StudentAge":23}); { "acknowledged" : true, "insertedId" : ObjectId("5c9ec75dd628fa4220163b83") } >db.checkIfFieldIsNumberDemo.insertOne({"StudentName":"Chris", "StudentMathScore":98, "StudentCountryName":"US"}); { "acknowledged" : true, "insertedId" : ObjectId("5c9ec77cd628fa4220163b84") } ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
328 Views
The application object is direct wrapper around the ServletContext object for the generated Servlet and in reality an instance of a javax.servlet.ServletContext object.This object is a representation of the JSP page through its entire lifecycle. This object is created when the JSP page is initialized and will be removed when ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
7K+ Views
To reset the primary key to 1 after deleting the data, use the following syntaxalter table yourTableName AUTO_INCREMENT=1; truncate table yourTableName;After doing the above two steps, you will get the primary key beginning from 1.To understand the above concept, let us create a table. The query to create a table ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
568 Views
To rename column name in a collection, you can use $rename operator. Following is the syntaxdb.yourCollectionName.update({}, {$rename: {'yourOldColumName': 'yourNewColumnName'}}, false, true);Let us first create a collection with documents:> db.renamingColumnNameDemo.insertOne({"StudentName":"Larry", "Age":23}); { "acknowledged" : true, "insertedId" : ObjectId("5c9ee2c6d628fa4220163b9a") } > db.renamingColumnNameDemo.insertOne({"StudentName":"Sam", "Age":26}); { "acknowledged" : true, "insertedId" ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
229 Views
In this article we will see how to fill the whole memory by writing a simple C++ program. Here the logic is very simple. We shall create new integer variables by using the dynamic memory allocation. If we create some variables again and again, it will fill the entire primary ... Read More
![George John](https://www.tutorialspoint.com/assets/profiles/13511/profile/60_58410-1512537824.png)
George John
667 Views
You can use update command along with forEach() for large collection. Let us first create a collection with documents>db.addingNewPropertyDemo.insertOne({"StudentName":"John", "StudentAge":23, "CountryName":"US"}); { "acknowledged" : true, "insertedId" : ObjectId("5ca1e61866324ffac2a7dc56") } >db.addingNewPropertyDemo.insertOne({"StudentName":"David", "StudentAge":21, "CountryName":"AUS"}); { "acknowledged" : true, "insertedId" : ObjectId("5ca1e62366324ffac2a7dc57") } >db.addingNewPropertyDemo.insertOne({"StudentName":"Bob", "StudentAge":21, "CountryName":"UK"}); { "acknowledged" ... Read More