
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Ankith Reddy has Published 996 Articles

Ankith Reddy
1K+ Views
You can use ROUND() function.The syntax is as followsSELECT ROUND(yourColumnName, yourPrecisionIntegerValue) from yourTableName;To understand the concept, let us create a table. The query to create a table is as followsmysql> create table givenPrecisionDemo -> ( -> Amount float -> ); Query ... Read More

Ankith Reddy
172 Views
You need to use $exists operator to determine whether a field exists in MongoDB. Let us first create a collection with documents> db.determineFieldExistsDemo.insertOne({"ClientName":"John"}); { "acknowledged" : true, "insertedId" : ObjectId("5c9eb245d628fa4220163b75") } > db.determineFieldExistsDemo.insertOne({"ClientName":"Larry", "ClientAge":23}); { "acknowledged" : true, "insertedId" : ObjectId("5c9eb25cd628fa4220163b76") } > db.determineFieldExistsDemo.insertOne({"ClientName":"Mike", "ClientCountryName":"UK"}); { ... Read More

Ankith Reddy
119 Views
Use the contains() method to search for a value in the KeyValue tuple. Let us first see what we need to work with JavaTuples. To work with KeyValue class in JavaTuples, you need to import the following package.import org.javatuples.KeyValue;Note Download JavaTuples Jar library to run JavaTuples program. If you are ... Read More

Ankith Reddy
4K+ Views
When you are done with a user's session data, you have several options −Remove a particular attribute − You can call the public void removeAttribute(String name) method to delete the value associated with the particular key.Delete the whole session − You can call the public void invalidate() method to discard ... Read More

Ankith Reddy
206 Views
Let us first create a collection and add some documents to it> db.twoRandomDocumentDemo.insertOne({"StudentId":10}); { "acknowledged" : true, "insertedId" : ObjectId("5c9ec9aad628fa4220163b87") } > db.twoRandomDocumentDemo.insertOne({"StudentId":100}); { "acknowledged" : true, "insertedId" : ObjectId("5c9ec9add628fa4220163b88") } > db.twoRandomDocumentDemo.insertOne({"StudentId":45}); { "acknowledged" : true, "insertedId" : ObjectId("5c9ec9b0d628fa4220163b89") } > db.twoRandomDocumentDemo.insertOne({"StudentId":55}); { ... Read More

Ankith Reddy
506 Views
In order to terminate a MongoDB shell script earlier, you need to use quit. Following is the syntaxquit() quit(1)Let us create a script and try to write quit() or quit(1) in shell. At first, we will create the following collection with documents> db.flightInformation.insertOne({"FlightName":"Flight-1", "ArrivalTime":new ISODate("2019-03-12")}); { "acknowledged" : true, ... Read More

Ankith Reddy
810 Views
In this program we will see how to add two 8-bit numbers which are in different segments.Problem StatementWrite 8086 Assembly language program to add content of memory location 2000:500 and 3000:600, and store the final result at 5000:700.DiscussionHere we are initializing the CX register with the base address of first ... Read More

Ankith Reddy
254 Views
You can use LEFT JOIN to find minimum unused value in a MySQL table. Let us first create a tablemysql> create table FindValue -> ( -> SequenceNumber int -> ); Query OK, 0 rows affected (0.56 sec)Insert some records in the table using insert command. The query ... Read More

Ankith Reddy
106 Views
The contains() method is used to search for a value in the Decade Tuple. Let us first see what we need to work with JavaTuples. To work with Decade class in JavaTuples, you need to import the following packageimport org.javatuples.Decade;Note Download JavaTuples Jar library to run JavaTuples program. If you ... Read More