Java Web Technologies and JDBC Practice Test
Test your knowledge of Java web development including JSP, servlets, Apache Tomcat, JDBC database connectivity, and MySQL integration.
Questions
What is sent to the user via HTTP, invoked using the HTTP protocol on the user's computer, and run on the user's computer as an application?
- A Java application
- A Java applet
- A Java servlet
- None of the above is correct.
Which JDBC driver Type(s) is(are) the JDBC-ODBC bridge?
- Type 1
- Type 2
- Type 3
- Type 4
How many copies of a JSP page can be in memory at a time?
- One
- Two
- Three
- Unlimited
Which JDBC driver Types are for use over communications networks?
- Type 3 only
- Type 4 only
- Both Type 3 and Type 4
- Neither Type 3 nor Type 4
How many JDBC driver types does Sun define?
- One
- Two
- Three
- Four
How does Tomcat execute a JSP?
- As a CGI script
- As an independent process
- By one of Tomcat's threads
- None of the above is correct
JDBC stands for:
- Java Database Connectivity
- Java Database Components
- Java Database Control
- None of the above is correct
Where is metadata stored in MySQL?
- In the MySQL database metadata
- In the MySQL database metasql
- In the MySQL database mysql
- None of the above is correct
Who invented Java?
- Netscape
- Microsoft
- Sun
- None of the above is correct
________ is an open source DBMS product that runs on UNIX, Linux and Windows.
- MySQL
- JSP/SQL
- JDBC/SQL
- Sun ACCESS
A JSP is transformed into a(n):
- Java applet.
- Java servlet.
- Either 1 or 2 above.
- Neither 1 nor 2 above.
What programming language(s) or scripting language(s) does Java Server Pages (JSP) support?
- VBScript only
- Jscript only
- Java only
- All of the above are supported
What is bytecode?
- Machine-specific code
- Java code
- Machine-independent code
- None of the above is correct
Which JDBC driver Type(s) can you use in a three-tier architecture and if the Web server and the DBMS are running on the same machine?
- Type 1 only
- Type 2 only
- Both Type 3 and Type 4
- All of Type 1, Type 2, Type 3 and Type 4
What servlet processor was developed by Apache Foundation and Sun?
- Apache Tomcat
- Apache Web server
- Sun servlet processor
- None of the above is correct
How many copies of a JSP page can be in memory at a time?
- One
- Two
- Three
- Unlimited
What is invoked via HTTP on the Web server computer when it responds to requests from a user's Web browser?
- A Java application
- A Java applet
- A Java servlet
- None of the above is correct
What is not true of a Java bean?
- There are no public instance variables.
- All persistent values are accessed using getxxx and setxxx methods.
- It may have many constructors as necessary.
- All of the above are true of a Java bean.
Which JDBC driver Type(s) is(are) the JDBC-ODBC bridge?
- Type 1
- Type 2
- Type 3
- Type 4
Which JDBC driver Types are for use over communications networks?
- Type 3 only
- Type 4 only
- Both Type 3 and Type 4
- Neither Type 3 nor Type 4
How does Tomcat execute a JSP?
- As a CGI script
- As an independent process
- By one of Tomcat's threads
- None of the above is correct
JDBC stands for:
- Java Database Connectivity
- Java Database Components
- Java Database Control
- None of the above is correct
What is sent to the user via HTTP, invoked using the HTTP protocol on the user's computer, and run on the user's computer as an application?
- A Java application
- A Java applet
- A Java servlet
- None of the above is correct
What MySQL property is used to create a surrogate key in MySQL?
- UNIQUE
- SEQUENCE
- AUTO_INCREMENT
- None of the above -- Surrogate keys are not implemented in MySQL
To run a compiled Java program, the machine must have what loaded and running?
- Java virtual machine
- Java compiler
- Java bytecode
- A Web browser
Which JDBC driver Type(s) can be used in either applet or servlet code?
- Both Type 1 and Type 2
- Both Type 1 and Type 3
- Both Type 3 and Type 4
- Type 4 only