Rewrite the example shown in Figure 8-5 using VB.NET. import java.sql.*; public class TestJDBC { public static
Question:
Rewrite the example shown in Figure 8-5 using VB.NET.
Transcribed Image Text:
import java.sql.*; public class TestJDBC { public static void main(String[] args) { try { Driverd = (Driver)Class.forName("oracle.jdbc.driver.OracleDriver").newlnstance( ); System.out.println(d); DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver( );L Connection conn = Register the driver to be used. Identify the type of driver to be used. DriverManager.getConnection ("jdbc:oracle:thin:@durga.uits.indiana.edu:1 521:OED1", args[O], args[1]); Open a connection to a database. Create a Statement variable that can Statement st = conn.createStatement( ;< ResultSet rec = st.executeQuery("SELECT * FROM Student"); while(rec.next( )) { System.out.println(rec.getString("name"):) conn.close( );< be used to issue queries against the database Issue a query and get a result. catch (Exception e) { System.out.printin("Error – " + e); Process the result, one row at a time. Close the connection.
Fantastic news! We've Found the answer you've been seeking!
Step by Step Answer:
Answer rating: 70% (17 reviews)
Dim conn As New OracleConnection Dim cmdQuery As String connConnectionString User I...View the full answer
Answered By
Joseph Njoroge
I am a professional tutor with more than six years of experience. I have helped thousands of students to achieve their academic goals. My primary objectives as a tutor is to ensure that students do not have problems while tackling their academic problems.
4.90+
10+ Reviews
27+ Question Solved
Related Book For
Modern Database Management
ISBN: 978-0133544619
12th edition
Authors: Jeff Hoffer, Ramesh Venkataraman, Heikki Topi
Question Posted:
Students also viewed these Computer Sciences questions
-
Rewrite the example shown in Figure 8-4 using Java.
-
Create the tables. (Use the MS Access example shown in Figure P8.1 to see what table names and attributes touse.) Database name: Ch08 SimpleCo Table name: CUSTOMER Table name: INVOICE CUST NUM CUST...
-
Consider the cross-country example shown in Figure 3. 17. How big would the window size have to be for the channel utilization to be greater than 95 percent? Suppose that the size of a packet is...
-
Analyze the residuals from the regression model on the patient satisfaction data from Exercise 4.49. Comment on the adequacy of the regression model. MTB> Stat> Regression > Regression Normal...
-
According to the American Time Use Survey, adult Americans spent 42.6 minutes per day on phone calls and answering or writing email in 2006. (a) Suppose that we want to judge whether the amount of...
-
Assume the same facts as in Problem 54. On the first day of the third tax year, the partnership sold the equipment for $150,000. The gain on the sale is allocated equally to the partners. The...
-
Demonstrate an understanding of the accounting for unrestricted and restricted contributions to not-for-profit colleges and universities. AppendixLO1
-
Schrager Manufacturing Company has two production departments: Cutting and Assembly. July 1 inventories are Raw Materials $4,930, Work in Process-Cutting $3,670, Work in Process-Assembly $11,110, and...
-
pls help and show work step by step thank you. X Requirements 1. Compute the flexible-budget variance, the spending variance, and the efficiency variance for variable manufacturing overhead. 2....
-
You are the auditor in charge of the audit of Steffens Corporation. In the audit of investments, you have just been given the following list of securities held by Steffens Corporation at December 31,...
-
Discuss some of the languages that are associated with Internet application development. Classify these languages according to the functionality they provide for each application. It is not necessary...
-
Consider the example code shown in Figure 8-10. Assume that instead of accessing data from a local server, you are going to access data from a cloud provider that offers the appropriate application...
-
Explain process operations and the way they differ from job order operations
-
2. (40 marks) Solve for y(t) such that y" - 6y' + 15y = 2 sin(3t),
-
6. Determine output class A{ ); } public static void main(String args[]) { int x; x = 10; if (x == 10) { int y = 20; System.out.print ("x and y: y = x*2; + y); } y = 100; } System.out.print ("x and...
-
Anita and Bonita have been roommates for the past two years while they've been in graduate school. Now that they're graduating, they are each planning to move to different cities. Their one joint...
-
To what extent are business ethics assumed, or taken for granted, by people in businesses?
-
Empowered by what he has learned in this class about gender, Brady makes a friendly wager with his girfriend, Marlisa: "I bet I can guess how the men and women at the next table will behave during...
-
What is a composite income tax return?
-
Provide a draft/outline of legal research involving an indigenous Canadian woman charged with assault causing bodily harm under (Sec 267b) of the Criminal Code, where the crown wants a 12-month jail...
-
The following information has been extracted from the financial statements of Rowett: Powell, a factoring company, has offered to take over the debt administration and credit control of Rowett on a...
-
1. List the names of all customers that have a credit limit less than $10,000. 2. List the descriptions of all parts in item class AP and located in warehouse number 3. 3. List the order numbers for...
-
1. List the name of each publisher thats not located in New York. 2. List the title of each book published by Penguin USA. 3. List the title of each book that has the type MYS. 4. List the title of...
-
1. List the owner number, last name, and first name of every boat owner. 2. List the names of all boats that are stored in a slip with a length of less than 30 feet. 3. List the last name, first...
-
A government bond matures in 30 years, makes semi-annual coupon payments of 6.0% ($120 per year) and offers a yield of 3.7% annually compounded. Assume face value is $1,000. Three years later the...
-
Your objective is: 1. Carry out a life insurance needs analysis, for each one of them (show your calculations) [30 Marks] 2. Refer to the case and the insurance plan quotes. Would you recommend...
-
TufStuff, Incorporated, sells a wide range of drums, bins, boxes, and other containers that are used in the chemical industry. One of the company s products is a heavy - duty corrosion - resistant...
Study smarter with the SolutionInn App