Questions tagged [neo4j.rb]

Neo4j.rb is an Active Model compliant Ruby/JRuby wrapper for the Neo4j graph database. It uses the neo4j-core and active_attr gems.

Neo4j.rb is an Active Model compliant Ruby/JRuby wrapper for the Neo4j graph database.

https://github.com/neo4jrb/neo4j

175 questions
0
votes
2 answers

Neo4j.rb How to Subclass ActiveRel relationship?

Newbie Neo4j.rb (v8.2.1) gem user here trying to figure out how to handle subclassing ActiveRel properly... I have one relationship type called HasAccount that I then subclass in others, i.e. OwnsAccount < HasAccount. I have relationships defined in…
Adam Sharp
  • 13
  • 3
0
votes
2 answers

How to neglect connected nodes in Neo4j.rb query

I have one node and one relationship class User include Neo4j::ActiveNode property :first_name end class Connection include Neo4j::ActiveRel include Enumable creates_unique from_class 'User' to_class 'User' type 'connected_to' …
Vishal G
  • 1,521
  • 11
  • 30
0
votes
1 answer

neo4j uuid is not created

class Client include Neo4j::ActiveNode end > client = Client.new => # My expectation is that the…
Satchel
  • 16,414
  • 23
  • 106
  • 192
0
votes
1 answer

neo4j returns a Neo4j::Core::Node in test env and the correct subclassed ActiveNode in development

This code @organization = Organization.find(params[:organization_id]) returns a Neo4j::Core::Node instance in test env and the correct Organization instance in development. I am running two servers with this neo4j.yml: development: type: bolt …
weston
  • 1,972
  • 17
  • 17
0
votes
1 answer

Record Persistence in Neo4j.rb 8.0.x

I am in the process of upgrading to Neo4j.rb version 8. After following the instructions in the upgrade guide, specs that were passing before are now failing. Specifically, count, persisted?, all, last and find seem to have come unhinged from each…
Andy Weiss
  • 405
  • 5
  • 15
0
votes
1 answer

Neo4j.rb WARNING: The constraint option is no longer supported?

How to fix this warning (WARNING: The constraint option is no longer supported (Defined on StayPal for user_id) I am using Neo4j.rb > 8 neo4j > 3 Following http://neo4jrb.readthedocs.io/en/8.0.x/ActiveNode.html using property :user_id, constraint:…
Vishal G
  • 1,521
  • 11
  • 30
0
votes
2 answers

Use two neo4j databases in single rails app

I have two neo4j databases running on two different hosts. I connected my rails app to one of them while generating the app. Now I want to use other database as well with the app. How can I configure the app to connect to both the databases?
penguin2048
  • 1,303
  • 13
  • 25
0
votes
1 answer

Neo4j Cypher: How to fetch nodes with conditional query on reation

I have two Neo4j Nodes and one relation: class StayPal include Neo4j::ActiveNode has_many :in, :places, origin: :owner has_many :in, :shared_places, rel_class: 'HouseMate' end class Place include Neo4j::ActiveNode has_one :out, :owner,…
Vishal G
  • 1,521
  • 11
  • 30
0
votes
1 answer

Neo4j rb inheritance of active node with association causes rspec to fail

I have 3 nodes, B, C and D. I require similar associations between C and B, and D and B To be DRY, rather than putting the 'has_many' individually on C and D, i created a super class A and added the association there, like so: class A include…
Shobhit Verma
  • 2,223
  • 2
  • 10
  • 17
0
votes
1 answer

Rails Neo4j query returning CypherRelationship instead of relationship values

I'm working on a Rails application that tracks transactions between addresses, using Neo4j as the database. When I try to run this query: Neo4j::Session.query("MATCH (sender:Address {address: 'abc123'})-[transaction:SENT_TO]->(receiver:Address)…
btw09
  • 1
  • 1
0
votes
1 answer

Neo4j Help to sort comments list with CYPHER

My application has an object "comments" where users can rate each comment as "positive" and "negative", I want to sort my comments based on a count (number of positive - amount of negative) based on that score I want to sort comments through a…
0
votes
1 answer

Where is the "neo4j-server.properties" file on mac?

I did brew install neo4j, followed by installing the ruby gem for neo4j. When I tried to run it, I got an error: `handle_response_error!': Expected response code 200 Error for request http://localhost:7474/db/data/, 401…
meow
  • 27,476
  • 33
  • 116
  • 177
0
votes
1 answer

(Neo4j.rb) Each call of on properties of a node triggers a query to the database

Here's the problem A query is trigger every time when a node property is called in the view How it looks in the view But even when a query was done to retrieve all the nodes it still sends one query for each property. Is there something that I…
Mohd Vara
  • 19
  • 5
0
votes
1 answer

Neo4j rels.to_other method fails with error

I have an user speaking several languages. I am writing a query to find out if the user speaks english. I want to find out if the user speaks english by searching if a relationship exists between the user node and and the language node. I am doing…
LDB
  • 692
  • 6
  • 18
0
votes
1 answer

Cypher query to exclude results based upon relationship

I'm trying to out how to exclude nodes from a query. My graph consists of users, skills, skill scoring, questions and endo user has skills skill has scorings in relation with questions ((skill)-->(scorings)-->(questions)) endo is a relationship for…
rgaidot
  • 31
  • 1
  • 3