
SQLite CRUD Quiz

Quiz
•
Computers
•
University
•
Hard
Jaydwin Labiano
Used 3+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What does the onCreate(SQLiteDatabase db) method do?
It updates the database to a new version.
It deletes the existing table from the database.
It creates a new table in the database.
It inserts data into the database.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of the onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) method?
It creates a new table in the database.
It fetches data from the database.
It updates the database structure when the database version changes.
It updates the database structure when the database name changes.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What code is used to navigate from MainActivity to MainActivity2.
Intent intent = new Intent(MainActivity.this, MainActivity2.class);
startActivity(intents);
Intent intent = new Intent(MainActivity.this, MainActivity2.class);
startActivity(intent);
Intent intent = new Intent(MainActivity.class, MainActivity2.this);
startActivity(intent);
Intent intent = new Intent(MainActivity.this, MainActivity2.class);
onLoadActivity(intent);
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Line of code that executes a raw SQL query on the SQLite database and returns a Cursor object.
Cursor cursor = sqLiteDatabase.rawQuery("select *from subject".null);
Cursor cursor = sqLiteDatabase.executeQuery("select *from subject", null);
Cursor cursor = sqLiteDatabase.loadQuery("select *from subject", null);
Cursor cursor = sqLiteDatabase.rawQuery("SELECT *from subject", null);
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following code is used to make a toast?
Toast.makeText(MainActivity.this, "Update successfully", Toast.LENGTH_SHORT).alert();
Toast.makeText(MainActivity.this, "Update successfully", Toast.LENGTH_SHORT).show();
Toast.createText(MainActivity.this, "Update successfully", Toast.LENGTH_SHORT).show();
Toast.makeText(MainActivity.class, "Update successfully", Toast.LENGTH_SHORT).show();
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following code is used to create a table with attributes.
String query = "create table " + TABLE + "(id integer primary key, fname text, lname text)";
db.execSQLite(query);
String query = "create table " + TABLE + "(id integer primary key, fname text, lname text)";
db.loadSQL(query);
String query = "create table + TABLE + (id integer primary key, fname text, lname text)";
db.execSQL(query);
String query = "create table " + TABLE + "(id integer primary key, fname text, lname text)";
db.execSQL(query);
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following best describes the SUBMIT button?
<Button
android:id="@+id/submit_btn"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:text="SUBMIT" />
<Button
android:id="@+id/submit_btn"
android:layout_width="wrap_content"
android:layout_height="match_content"
android:layout_weight="1"
android:text="SUBMIT" />
<Button
android:id="@+id/submit_btn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="SUBMIT" />
<Button
android:id="@+id/submit_btn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_size="1"
android:text="SUBMIT" />
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
KUIS DAY 3 STACK

Quiz
•
University
12 questions
ICT450-TOPIC 1

Quiz
•
University
15 questions
7-mavzu. Python va MySQLda ma’lumotlarni tanlash va o‘chirish

Quiz
•
University
10 questions
2C DBMS Theory Quiz 1

Quiz
•
University
15 questions
Ch3_Relational Data Model

Quiz
•
University
15 questions
UAS SI-V Pemrograman Aplikasi Mobile I

Quiz
•
University
10 questions
Executing SQL Commands With Python

Quiz
•
12th Grade - University
10 questions
Express.js

Quiz
•
University
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition

Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12

Lesson
•
11th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
20 questions
Definite and Indefinite Articles in Spanish (Avancemos)

Quiz
•
8th Grade - University
7 questions
Force and Motion

Interactive video
•
4th Grade - University
36 questions
Unit 5 Key Terms

Quiz
•
11th Grade - University
7 questions
Figurative Language: Idioms, Similes, and Metaphors

Interactive video
•
4th Grade - University
15 questions
Properties of Equality

Quiz
•
8th Grade - University
38 questions
WH - Unit 3 Exam Review*

Quiz
•
10th Grade - University
21 questions
Advise vs. Advice

Quiz
•
6th Grade - University
12 questions
Reading a ruler!

Quiz
•
9th Grade - University