I'm trying to import a csv file in NEO4j db using script :
LOAD CSV FROM "file:///dataframe6.txt" AS line
RETURN count(*)
But I get following error:
Neo.ClientError.Statement.ExternalResourceFailed
Couldn't load the external resource at: file:/home/gaurav/sharing/dataframe6.txt
P.S. : I'm using ubuntu machine
added this line dbms.directories.import=/home/gaurav/sharing/
and dbms.security.allow_csv_import_from_file_urls=true
I had to change folder permission for user NEO4j, it works now
Related
I'm trying to import a MySQL Database via command line (Terminal). The file's path seems to be correct, but I keep getting an error message that is most likely showing that, the path of the SQL file I'm importing is not correct. Below is the sample of the command line I'm using and the error I'm getting...
NOTE: Linux Server, Centos 7 - MariaDB
source C:/Users/localcomputerUser/SQLFileFolder/SQLFile.sql
source C:/Users/localcomputerUser/SQLFileFolder/SQLFile.sql
Failed to open file 'C:/Users/localcomputerUser/SQLFileFolder/SQLFile.sql
', error: 2
Thanks for your support.
I have updated the neo4j.conf file but can't seem to get rid of this error after changing the file and restarting. I am just trying to load a json file through neo4j and have included the line apoc.import.file.enabled=true on the neo4j.conf but doesn't seem to be working for me, I'm still getting the error message:
Failed to invoke procedure 'apoc.load.json' Caused by
java.lang.RuntimeException : Import from files not enabled, please set
apoc.import.file.enabled=true in your neo4j.conf
I am using neo4jCE 3.2.3 and have used the right file path for the json file as it previously worked on my desktop computer (I'm just trying to replicate it on my laptop) and I am using apoc 3.2.0.4 version plugin. The procedure apoc.load.json is also there when I call all procedures directory.
I'm trying to import some extra data to my existing H2 database. The extra data are in a .CSV file and I'm using the simple example SQL statement from H2 tutorial documentation:
SELECT * FROM CSVREAD('test.csv');
So far, I can only get the following exception:
Error: IO Exception: "IOException reading test.csv"; SQL statement:
SELECT * FROM CSVREAD('test.csv') [90028-176]
SQLState: 90028
ErrorCode: 90028
I am using SQuirreL client in Windows 7 to manage a local H2 database and so far, everything is working well. The test.csv is in the same directory as the database file.
Looks like a problem with the test.csv file. Is this on Linux ? Then check for case-sensitive file name and access permissions for the running process.
Could you read the file with FileInputStream from your code ? Is this a remote H2 db ?
In any case, it is the H2 server that needs access to the file. Probably the file is not in the CWD of the H2 process. Try to specify an absolute file name for the H2 server like /my/folder/test.csv or c:\my\folder\test.csv.
Am getting following "permissions" error when trying to import an sqldump
Error Code: 1 - Can't create/write to file
'C:\ProgramData\MySQL\MySQL Server 5.5\Data\dealcrm\accessorieslink.MYI'
(Errcode: 13)
I have renamed the data folder and put it back recently.
Have tried giving full control for user "system" on the data folder - this is user
the mysql service is started with
any help welcome
EDIT**
Have also tried adding a folder C:/ProgramData/MySQL/MySQL Server 5.5/Temp/
and added this line to mysql.ini
tmpdir="C:/ProgramData/MySQL/MySQL Server 5.5/Temp/"
after import there are some files in the folder but still get error 13
As per documentation of the error code, in your particular situation, i.e. on Windows, you're most likely lacking a setting of the right temp directory where MySQL can dump tempfiles. Set it as described in the link above and you should be fine.
I got a problem using MySQL with MonkeyRunner, need a help with MySQL Driver Name. The starting of my script is:
#coding : utf-8
from com.android.monkeyrunner import MonkeyRunner,MonkeyDevice
from com.ziclix.python.sql import zxJDBC
db = zxJDBC.connect('jdbc:mysql://localhost/android','dani','123456','com.mysql.jdbc.Driver')
.
.
etc
Each time I got an error that com.mysql.jdbc.Driver not found even when using org.git.mm.mysql.Driver. I set classpath as following :
export CLASSPATH=$CLASSPATH:/usr/share/java/mysql-connector-java.5.1.10.jar
Any tips or hits?
Regards,,,
You need to include the relevant jar in the correct location. There should be a libs folder where you need to put the jar. It should be in the top level of your project folder, at the same level as the src and res folders.