- 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
Karthikeya Boyini has Published 2383 Articles
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
1K+ Views
In order to convert NumberLong to String in MongoDB, you can use toString() −NumberLong('yourValue').valueOf().toString();To convert NumberLong to String, you can use valueOf() as well −NumberLong('yourValue').valueOf();Let us implement both the above syntaxes.Following is the query to convert NumberLong to String with toString() −> NumberLong('1000').valueOf().toString();This will produce the following output −1000Following is ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
99 Views
The HTML DOM input hidden form property returns the reference of the form that contain the hidden input field in the HTML document.SyntaxFollowing is the syntax −object.formExampleLet us see an example of HTML DOM input hidden form property − Live Demo body{ text-align:center; ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
126 Views
The HTML DOM input image Object represent the element with type=”image” of an HTML document.Let’s see how to create input image object −SyntaxFollowing is the syntax −var imageInput = document.createElement(“INPUT”); imageInput.setAttribute(“type”, ”image”);PropertiesFollowing are the properties of HTML DOM input image Object −PropertyExplanationAltIt returns and modify the value of the ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
87 Views
You can use findOne() for this. Following is the syntax −db.yourCollectionName.findOne({yourFieldName: 'yourValue'});Let us create a collection with documents −> db.checkExistingDemo.insertOne({"StudentName":"John"}); { "acknowledged" : true, "insertedId" : ObjectId("5cbdf90dac184d684e3fa265") } > db.checkExistingDemo.insertOne({"StudentName":"Carol"}); { "acknowledged" : true, "insertedId" : ObjectId("5cbdf912ac184d684e3fa266") } > db.checkExistingDemo.insertOne({"StudentName":"Sam"}); { "acknowledged" : true, ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
88 Views
The HTML DOM input month Object represent the element with type=”month”.Let us create input month object −SyntaxFollowing is the syntax −var monthInput = document.createElement(“INPUT”); monthInput.setAttribute(“type”, ”month”);PropertiesFollowing are the properties of HTML DOM input month Object −PropertyExplanationautocompleteIt returns and alter the value of the autocomplete attribute of month input field.autofocusIt ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
78 Views
The HTML DOM input month name property returns and modify the value of the name attribute of the input field of type=”month” in a HTML document.SyntaxFollowing is the syntax −1. Returning nameobject.name2. Modifying nameobject.name = “text”ExampleLet us see an example of HTML DOM input month name property − Live Demo ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
240 Views
Let us first create a collection with documents −> db.arrayContainOnlySpecificFieldDemo.insertOne( ... { ... "StudentName":"John", ... "StudentAge":21, ... "StudentTechnicalSubject":["C", "Java", "MongoDB"] ... } ... ); { "acknowledged" : true, "insertedId" : ObjectId("5cc4921dac184d684e3fa26a") } > db.arrayContainOnlySpecificFieldDemo.insertOne( { "StudentName":"Carol", "StudentAge":23, ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
57 Views
The HTML DOM input month min property returns and modify the value of the min attribute of the input field of type=”month” in an HTML document.SyntaxFollowing is the syntax −1. Returning minobject.min2. Modifying minobject.min = “YYYY-MM”Here, YYYY represent year and MM represent month like “2019-02”ExampleLet us see an example of ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
73 Views
The HTML DOM input month readOnly property returns and modify whether the input month field is read-only or not in an HTML document.SyntaxFollowing is the syntax −1. Returning readOnlyobject.readOnly2. Modifying readOnlyobject.readOnly = true | falseExample Live DemoLet us see an example of HTML DOM input month readOnly property− ... Read More
![karthikeya Boyini](https://www.tutorialspoint.com/assets/profiles/13518/profile/60_31598-1537784993.jpg)
karthikeya Boyini
1K+ Views
Imagine you’re playing a song and as soon as you press the stop button, the color of the button should turn to red. This is one of the many scenario where you might need to change the color of button when it is clicked.In this tutorial we will see how ... Read More