java


No suitable driver found for jdbc Neo4j


I already checked the other question about my issue, but none of them solved.
I imported the Neo4j Jar by configuring the build path, but still I get this error.
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
public class TestNeo4j {
public static void main(String[] args) throws SQLException {
Connection c = DriverManager.getConnection("jdbc:neo4j://localhost:7474/", "neo4j", "neo4j");
Statement st = c.createStatement();
String cql = "match (m)-[:IS_ALLERGIC_TO]->(n:Product) where n.name = 'gluten' return m.name";
ResultSet rs = st.executeQuery(cql);
while(rs.next())
System.out.println(rs.getString(1));
c.close();
}
}
This is my code. Can you figure out what the problem is?
As suggested here, use neo4j jar with dependencies (neo4j-jdbc-2.1.4-jar-with-dependencies.jar).
You can grab it from neo4j release repository, here

Related Links

JSP dynamically change include page
Java: How to check if printer status
Javafx updating tableview on object change
Trouble deploying web service on Tomcat 8
Java EE 7 Webapp - Problems with REST-Services(json) after upgrading tika-parsers to 1.11
Eclipse: Java heap space, How to fix it?
How to return error from OFBiz SECA service
my code is not displaying a string stored in a variable [duplicate]
Is it possible to configure a Java web app to run with Apache Wink Server and JAX-RS 2.0?
java, A window with 2 buttons
Add Radio Button in List
iText Output Missing Unicode Characters
Regex optional matching
Android Studio Start Failed: fatal error initializing 'com.intellij.util.net.ssl.certificatemanager'
Output of generating new string array does n't come as expected
Android sqlite database getallRows() checking for null gives error [duplicate]

Categories

HOME
listview
comparison
plot
onedrive
platform-builder
youtube-dl
google-docs
setup-deployment
tizen-web-app
jxls
angular-ui-bootstrap
ravendb
basic
gnupg
user-input
spring-xd
quickbooks
google-cloud-spanner
phaser
tostring
transformation
apache-metamodel
pythonanywhere
lcd
vision
socialengine
google-rich-snippets
winrt-xaml-toolkit
textmate
picasso
web-mining
retina-display
mixture-model
streamreader
user-controls
logfiles
revapi
promela
pnotify
dandelion
domain-model
rdfs
yii2-extension
carrot
android-cursor
dtexec
sybase-asa
linode
arrow-keys
imanage
elements
home-directory
qpid
react-native-listview
iad
kendonumerictextbox
tmuxinator
truevault
javafx-webengine
castle
google-reader
wp-query
floating-point-precision
ms-project-server-2010
access-rights
odata4j
eclipse-memory-analyzer
pygit2
enterprisedb
e4x
hamiltonian-cycle
broken-links
runas
propertyeditor
multipage
netbeans-6.9
semantic-diff
nsdatecomponents
netbeans-7.1
ecl
winbugs14
oncheckedchanged
locate
blitz++
adrotator
project-hosting
thread-local-storage
multiple-languages
uiq3

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App