
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
Smita Kapse has Published 498 Articles

Smita Kapse
291 Views
Virtual functions calling from a constructor or destructor is dangerous and should be avoided whenever possible as the virtual function we call is called from the Base class and not from the derived class.The reason is that in C++ Super-classes are constructed before derived classes. So, in the following example, ... Read More

Smita Kapse
6K+ Views
You can use NOT IN operator for the rows you do not want to delete. Following is the syntax −delete from yourTableName where yourColumnName NOT IN(‘yourValue1’, ‘yourValue2’, ‘yourValue3’, .........N);Let us first create a table −mysql> create table deleteAllRowsWithCondition -> ( -> Id int NOT NULL AUTO_INCREMENT PRIMARY KEY, ... Read More

Smita Kapse
248 Views
Before getting into example, we should know what sqlite data base in android is. SQLite is an open source SQL database that stores data to a text file on a device. Android comes in with built in SQLite database implementation. SQLite supports all the relational database features. In order to ... Read More

Smita Kapse
117 Views
To write on console, you need to use print() method. The syntax is as follows −print(“yourString”);To display objects, you can use printjson(). The syntax is as follows −printjson(yourObjectName);Let us implement both the functions. The first query is as follows to display something −> print("Welcome to MongoDB Console");The following is the ... Read More

Smita Kapse
160 Views
To sort more than one column at a time, you can use ORDER BY clause. Following is the syntax −select yourColumnName1, yourColumnName2, yourColumnName3 from yourTableName order by yourColumnName2, yourColumnName3;Let us first create a table −mysql> create table doubleSortDemo -> ( -> StudentId int NOT NULL AUTO_INCREMENT PRIMARY KEY, ... Read More

Smita Kapse
1K+ Views
You can use ensureIndex() to boost the performance of count() method in MongoDB. To understand the concept, let us create a collection with the document. The query to create a collection with a document is as follows −> db.countPerformanceDemo.insertOne({"StudentName":"John", "StudentCountryName":"US"}); { "acknowledged" : true, "insertedId" : ObjectId("5c8ebcf82f684a30fbdfd55f") } ... Read More

Smita Kapse
8K+ Views
This error occurs if let’s say you used var_char instead of varchar type. To remove this type of error, use, for example, varchar(100) instead of var_char(100).Let us now see how this error occurs −mysql> create table removeErrorDemo -> ( -> StudentId int, -> StudentName var_char(50) -> ... Read More

Smita Kapse
1K+ Views
To get and set the stack size of thread attribute in C, we use the following thread attributes:pthread_attr_getstacksize()Use for get threads stack size. The stacksize attribute gives the minimum stack size allocated to threads stack. In case of a successful run, then it gives 0 otherwise gives any value.It takes ... Read More

Smita Kapse
403 Views
To select only duplicate records from database and display the count, use HAVING along with aggregate function count(). Let us first create a table −mysql> create table duplicateRecords -> ( -> ClientId int NOT NULL AUTO_INCREMENT PRIMARY KEY, -> ClientName varchar(20) -> ); Query OK, 0 ... Read More

Smita Kapse
110 Views
This example demonstrate about How to remove data from Linked hashset in AndroidStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml. ... Read More