Anvi Jain has Published 629 Articles

How to use unicode () in Android sqlite?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

290 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

How to display some columns (not all) in MySQL?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

195 Views

In order to show some columns, use NOT IN and set those columns which you do not want to display. Let us first create a table. Following is the query −mysql> create table student_Information    -> (    -> StudentId int NOT NULL AUTO_INCREMENT PRIMARY KEY,    -> StudentName varchar(50), ... Read More

How to use update command in Android sqlite?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

2K+ 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

How to query on list field in MongoDB?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

714 Views

To understand the query on list field, and/or, you can create a collection with documents.The query to create a collection with a document is as follows −> db.andOrDemo.insertOne({"StudentName":"Larry", "StudentScore":[33, 40, 50, 60, 70]}); {    "acknowledged" : true,    "insertedId" : ObjectId("5c9522d316f542d757e2b444") } > db.andOrDemo.insertOne({"StudentName":"Larry", "StudentScore":[87, 67, 79, 98, 90]}); ... Read More

How to change current country name in android?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

148 Views

This example demonstrate about How to change current country name in android.Step 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.     In the ... Read More

How to get hour, minutes and seconds in android using offset time API class?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

1K+ Views

This example demonstrate about How to get hour, minutes and seconds in android using offset time API class.Step 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 ... Read More

Configuration file parser in Python (configparser)

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

12K+ Views

The configparser module from Python's standard library defines functionality for reading and writing configuration files as used by Microsoft Windows OS. Such files usually have .INI extension.The INI file consists of sections, each led by a [section] header. Between square brackets, we can put the section’s name. Section is followed ... Read More

How to remove an array element by its index in MongoDB?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

872 Views

You can remove an array element by its index using the following two steps −The first step is as follows −db.yourCollectionName.update({}, {$unset : {"yourArrayFieldName.yourIndexValue" : 1 }});The above syntax will put a null value at the location of ‘yourIndexValue’. After that, you need to pull the null value from array ... Read More

MySQL query to get the max value with numeric values in varchar field?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

377 Views

To get the max value, use the max() function. Let us create a table first −mysql> create table findMaxValueInVarcharField    -> (    -> Id int NOT NULL AUTO_INCREMENT PRIMARY KEY,    -> Value varchar(200)    -> ); Query OK, 0 rows affected (1.09 sec)Following is the query to insert ... Read More

How do I insert a record from one Mongo database into another?

Anvi Jain

Anvi Jain

Updated on 30-Jul-2019 22:30:25

436 Views

You can switch from one database to another using the use command. Here, we are using the collection in the “test” database. Let us insert that collection in another database with the name “sample”.To understand further, let us create a collection with the document. The query to create a collection ... Read More

Advertisements