U4. ORM Hibernate

U4. ORM Hibernate

University

34 Qs

quiz-placeholder

Similar activities

Seatwork 15 -CC102

Seatwork 15 -CC102

University

35 Qs

Database Questions

Database Questions

KG - Professional Development

31 Qs

Database

Database

KG - University

35 Qs

UAS PBO Lanjut

UAS PBO Lanjut

University

35 Qs

Pemrograman Web Lanjut

Pemrograman Web Lanjut

University

30 Qs

Information Management (LEC)

Information Management (LEC)

University

30 Qs

Final Exam Review (CA)

Final Exam Review (CA)

KG - University

38 Qs

Microsoft Access

Microsoft Access

University

30 Qs

U4. ORM Hibernate

U4. ORM Hibernate

Assessment

Quiz

Computers

University

Easy

Created by

Héctor L

Used 29+ times

FREE Resource

34 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the main advantage of using Hibernate over JDBC?

Direct manipulation of SQL queries

Abstracting database operations using Java objects

Faster execution speed compared to raw SQL

No need for database configuration

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In Hibernate, which method is used to begin a transaction?

session.startTransaction()

session.begin()

session.beginTransaction()

session.newTransaction()

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following statements about HQL (Hibernate Query Language) is true?

HQL works directly with database tables

HQL is case-sensitive for class names and properties

HQL allows using * as a wildcard for selecting all columns

HQL does not support aggregate functions

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will happen if a getReference() method is called with a non-existent entity ID?

It returns null

It throws an EntityNotFoundException

It retrieves an empty proxy object

It automatically creates a new entity in the database

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the SessionFactory class in Hibernate?

To perform CRUD operations

To manage database transactions

To create and manage Session objects

To execute HQL queries

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In Hibernate, what is the default fetching strategy for @OneToMany relationships?

Eager loading

Lazy loading

Immediate loading

Explicit loading

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following methods is used to persist an object in Hibernate?

session.insert()

session.persist()

session.saveObject()

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?