Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top
$ $ source .profile
> bash: :/usr/java/connectors/mysql-connector-java-5.1.23-bin.jar: No such file or directory
$ /usr/java/connectors/mysql-connector-java-5.1.23-bin.jar 
> no main manifest attribute, in /usr/java/connectors/mysql-connector-java-5.1.23-bin.jar

What I'm having trouble understanding is, when I run it from $CLASSPATH (to see if it has been set) why it's not being detected. Shouldn't it be the same if I type it in? I'm getting two different results.

the connector is 0777 with owner root:root.

share|improve this question

migrated from Mar 5 '13 at 9:14

This question came from our site for professional and enthusiast programmers.

What does '$' and '>' at the beginning of the line mean? – Mikhail Vladimirov Mar 5 '13 at 6:06
$ means "this is something I'm typing as my user (not root)" > means "this is something the console has returned" – James Bone Mar 5 '13 at 6:12
So you typed $CLASSPATH, then you typed .profile, then you typed CLASSPATH (without $) and got error message? So that is CLASSPATH command? – Mikhail Vladimirov Mar 5 '13 at 8:24
sorry the third line has $CLASSPATH, it's an environment variable I set in profile... that should also be "$ source profile" I'll edit now. – James Bone Mar 5 '13 at 11:43
Are you exporting the CLASSPATH environment variable? Either in your script or on the command line you need: export CLASSPATH – Paul Bone Mar 6 '13 at 5:59

While it doesn't solve the problem as I'd like I have found a solution.

In this instance I'm trying to add a JDBC connector so I can use it in my Java programming. In Eclipse I've been able to go configure build path -> add variable -> configure, then define CLASSPATH as the .jar file.

If anyone still has an answer for the posted question I would be very interested to know.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .