hi everyone

i have not been here in a while. so here I am practicing building a forensic managment java application but the thing, i am trying to connect to the database, so, like i am importing the codes that would help connect to the database, like I mean the connection, the preparedstatement and the resultset and for some reason am getting errors, is it because that java is not finding the it or wat.

the errors stating that it cannot find the symbol, I am only importing.

Recommended Answers

All 24 Replies

rproffitt
what is wrong with my question, i have seen question asked worst than mine and it was answered and yes I did check to see if there was any questions that may be pertaining to mine but I didnt see any hence the reason for asking if my question wasnt good enough to warrant an answer then sorry

@d, it's incredibly hard to troubleshoot without seeing the code and the error messages from that line of code. Rather than me write at length how to make a better post, I supplied a link to where pritaeas wrote about everything that is needed to get working on a problem.

Add most detail using pritaeas's guide so others can see the code and maybe it's a simple thing.

Hi divinity02
You know me. We have worked together many times. But this time I agree with the previous posts. You haven’t given anywhere near enough information that we could possibly use to help you. Please try again with actual code, error message etc.

JC

hi james and rproffitt

here is the code

package forensic;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import javax.swing.*;

/**
 *
 * @author luana taylor
 */
public class forensic_login extends javax.swing.JFrame {
Connection conn = null;
PreparedStatement pst = null;
ResultSet rs = null;

    /**

the errors that I am getting is that it cannot find symbol

I have now starting to build the login gui page, I want it to hook up to the database, so when there is a login it can say you are login successfully or invalid login

Where is the full error message? You know, the one that says which line number and which symbol??.

hey jc

i have upload the file for you to see where the error, is it called screenshot, all the errors are there and the error message says, it cannot find symbol the red lines underneath
Connection
ResultSet
PreparedStatement

that is the error,

Puzzling! Are you using Java ME?

hi james

yes it is java am using, i have not starting using any other languages, or have learned any other languages as yet

I was referring to JavaME - the micro edition of a Java, because I don’t think that has sql as standard. Apart from that all I can guess is some kind of configuration or installation problem. Do you have any other code in the same IDE that successfully imports any Java.sql files?

yes i have other program that I am currently working on and it doesnt have that problem,

javame is what" is that another software where u can write programs or is it an upgraded version

hi james

if I download the javame edition, seeing that it is the upgrade to the one that I hve which is 2.5.2 which is the old versio, will it over ride that one that I have at present or will it be just be separate

Java micro edition is a cut-down version of Java to run on very small computers. If you are writing for a pc or a server then it’s not relevant. I only mentioned it because it would explain your problem. But no.
Now all I can guess is that it’s a configuration or installation problem of some sort. Sorry I can’t be more helpful.

The netbeans screenshot shows jdk 1.8, so that’s ok

@JamesCherrill. 1.8 wasn't on that list so I wonder if such an old version has support for their imports. I think a conversation I had long ago cut off any support for Java prior to 8.0.

hi james and rprofiitt

there version of netbeans that i am using is version 8.2

Netbeans is the IDE and is 8.2
The JDK (Java Development Kit) version looks to be 1.8. May want to see about fixing that unless there is a reason you are using this such as for some embedded system or legacy reason.

PS. Please answer questions put to you such as "Do you have any other code in the same IDE that successfully imports any Java.sql files?"

yes I have said so before like u didnt read, i have successfully import java sql before and had no problems with importing it

Java 1.8 is perfectly ok, it’s also known as Java 8. It’s the current LTS version.
They changed the version numbers for marketing use after 1.4, but the version numbers in the actual code kept the original numbering scheme.
Netbeans 8.2 is also ok.
This is still a mystery!

See if what still works?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.