Discussion Forum

Query super slow to return

I’m a new user of Grakn/TypeDB and going through the tutorials. Everything runs smoothly until I run one of the queries on the phone_calls example.

match
  $suspect isa person, has city "London", has age > 50;
  $company isa company, has name "Telecom";
  (customer: $suspect, provider: $company) isa contract;
  $pattern-callee isa person, has age < 20;
  (caller: $suspect, callee: $pattern-callee) isa call, has started-at $pattern-call-date;
  $target isa person, has phone-number $phone-number, has is-customer false;
  (caller: $suspect, callee: $target) isa call, has started-at $target-call-date;
  $target-call-date > $pattern-call-date;
get $phone-number;

This either, more often than not, kills the server or takes about 8 minutes to run, which is absolutely not normal given the size of the data. Is there an explanation for this? I’m thinking it might have to do with the JVM memory parameter settings but I’m not sure where I can set this.

Thanks.

Hi - make sure you are using the latest verison of TypeDB, these issues have all been resolved (to do with type inference within the query) :slight_smile:

I did just notice that all the spacing seems to have been stripped for code examples in the CSV/JSON/XML tabs! We will work to fix that!

Thanks Joshua! Updating to the latest version solved this.