Can i connect mysql database which is present on another server

I had a doubt that while using apoc.load.jdbc....can i specify any other server ip other than that on which neo4j is running currently.
neo4j is running on 192.168.XXX.XXX
but the mysql database is present at :192.168.YYY.YYY

can i use 192.168.YYY.YYY instead of localhost in the below example
CALL apoc.load.jdbc('jdbc:mysql://localhost:3306/proddb1?user=root&password=football','select title from movies where studio='MGM Studios'') YIELD row

you should be able to use another machine IP address in apoc jdbc url.

Thanks for the heads up..

Actually now the problem is .......I have '^' character in my password so its showing illegal use of character in query.

how can I escape this ^

Just a wild guess from me:
Please try backtick key to store password. eg Pa^^word

Since it is part of URL try url encoded value for it and see if it works.

Thanks but i had tried it already.......that doesn't work either.
Backtick itself becomes a illegal character :grinning:

Actually i didn't get what u said,
did u mean to pass the password as parameter
can u please explain?
Thanks in advance

URL encoding of the password value.

For example the character ^ becomes %5E when you do url encode.

So instead of Pa^^word give Pa%5E%5Eword as the password value and try.

1 Like

Hey anthapu,
Thank u very much for your help......!!!
It worked fine for me...! :raised_hands: :love_you_gesture: