com.datastax.driver.core.exceptions.SyntaxError: line 1:8 no viable alternative at input 'FROM' (SELECT [FROM]...)

Stack Overflow | taylorcressy | 2 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    spark-cassandra-connector per partition limit

    Stack Overflow | 3 months ago | Brent Dorsey
    com.datastax.driver.core.exceptions.SyntaxError: line 1:154 no viable alternative at input 'PARTITION' (...("item_uuid") <= ? AND [PER] PARTITION...)
  2. 0

    Not allowed to query with all of partition Keys(cassandra) with Equals

    GitHub | 1 year ago | venkatesh-rudraraju
    java.io.IOException: Exception during preparation of _**SELECT "dtid", "created", "deleted" FROM "metricsdb"."device_counts_by_hour" WHERE token("period") > ? AND token("period") <= ? AND period = 2016033123 ALLOW FILTERING**_: period cannot be restricted by more than one relation if it includes an Equal
  3. 0

    {code} 19:30:49 com.datastax.driver.core.exceptions.InvalidQueryException: Invalid null value for partition key part key 19:30:49 at com.datastax.driver.core.exceptions.InvalidQueryException.copy(InvalidQueryException.java:35) 19:30:49 at com.datastax.driver.core.DefaultResultSetFuture.extractCauseFromExecutionException(DefaultResultSetFuture.java:289) 19:30:49 at com.datastax.driver.core.DefaultResultSetFuture.getUninterruptibly(DefaultResultSetFuture.java:205) 19:30:49 at com.datastax.driver.core.AbstractSession.execute(AbstractSession.java:52) 19:30:49 at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source) 19:30:49 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 19:30:49 at java.lang.reflect.Method.invoke(Method.java:606) 19:30:49 at com.datastax.spark.connector.cql.SessionProxy.invoke(SessionProxy.scala:33) 19:30:49 at com.sun.proxy.$Proxy12.execute(Unknown Source) 19:30:49 at com.datastax.spark.connector.rdd.CassandraJoinRDD$$anonfun$fetchIterator$1.apply(CassandraJoinRDD.scala:233) 19:30:49 at com.datastax.spark.connector.rdd.CassandraJoinRDD$$anonfun$fetchIterator$1.apply(CassandraJoinRDD.scala:231) 19:30:49 at scala.collection.Iterator$$anon$12.hasNext(Iterator.scala:396) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.hasNext(CountingIterator.scala:12) 19:30:49 at scala.collection.Iterator$class.foreach(Iterator.scala:750) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.foreach(CountingIterator.scala:4) 19:30:49 at scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:59) 19:30:49 at scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:104) 19:30:49 at scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:48) 19:30:49 at scala.collection.TraversableOnce$class.to(TraversableOnce.scala:295) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.to(CountingIterator.scala:4) 19:30:49 at scala.collection.TraversableOnce$class.toBuffer(TraversableOnce.scala:287) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.toBuffer(CountingIterator.scala:4) 19:30:49 at scala.collection.TraversableOnce$class.toArray(TraversableOnce.scala:274) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.toArray(CountingIterator.scala:4) 19:30:49 at org.apache.spark.rdd.RDD$$anonfun$collect$1$$anonfun$12.apply(RDD.scala:885) 19:30:49 at org.apache.spark.rdd.RDD$$anonfun$collect$1$$anonfun$12.apply(RDD.scala:885) 19:30:49 at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:1765) 19:30:49 at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:1765) 19:30:49 at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:63) 19:30:49 at org.apache.spark.scheduler.Task.run(Task.scala:70) 19:30:49 at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:213) 19:30:49 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) 19:30:49 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) 19:30:49 at java.lang.Thread.run(Thread.java:744) {code} This came up on jenkins for a doc only change PR. We've also seen jenkins intermittently fail the actor streaming job which uses the same api.

    DataStax JIRA | 2 years ago | Russell Spitzer
    com.datastax.driver.core.exceptions.InvalidQueryException: Invalid null value for partition key part key
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    {code} 19:30:49 com.datastax.driver.core.exceptions.InvalidQueryException: Invalid null value for partition key part key 19:30:49 at com.datastax.driver.core.exceptions.InvalidQueryException.copy(InvalidQueryException.java:35) 19:30:49 at com.datastax.driver.core.DefaultResultSetFuture.extractCauseFromExecutionException(DefaultResultSetFuture.java:289) 19:30:49 at com.datastax.driver.core.DefaultResultSetFuture.getUninterruptibly(DefaultResultSetFuture.java:205) 19:30:49 at com.datastax.driver.core.AbstractSession.execute(AbstractSession.java:52) 19:30:49 at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source) 19:30:49 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) 19:30:49 at java.lang.reflect.Method.invoke(Method.java:606) 19:30:49 at com.datastax.spark.connector.cql.SessionProxy.invoke(SessionProxy.scala:33) 19:30:49 at com.sun.proxy.$Proxy12.execute(Unknown Source) 19:30:49 at com.datastax.spark.connector.rdd.CassandraJoinRDD$$anonfun$fetchIterator$1.apply(CassandraJoinRDD.scala:233) 19:30:49 at com.datastax.spark.connector.rdd.CassandraJoinRDD$$anonfun$fetchIterator$1.apply(CassandraJoinRDD.scala:231) 19:30:49 at scala.collection.Iterator$$anon$12.hasNext(Iterator.scala:396) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.hasNext(CountingIterator.scala:12) 19:30:49 at scala.collection.Iterator$class.foreach(Iterator.scala:750) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.foreach(CountingIterator.scala:4) 19:30:49 at scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:59) 19:30:49 at scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:104) 19:30:49 at scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:48) 19:30:49 at scala.collection.TraversableOnce$class.to(TraversableOnce.scala:295) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.to(CountingIterator.scala:4) 19:30:49 at scala.collection.TraversableOnce$class.toBuffer(TraversableOnce.scala:287) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.toBuffer(CountingIterator.scala:4) 19:30:49 at scala.collection.TraversableOnce$class.toArray(TraversableOnce.scala:274) 19:30:49 at com.datastax.spark.connector.util.CountingIterator.toArray(CountingIterator.scala:4) 19:30:49 at org.apache.spark.rdd.RDD$$anonfun$collect$1$$anonfun$12.apply(RDD.scala:885) 19:30:49 at org.apache.spark.rdd.RDD$$anonfun$collect$1$$anonfun$12.apply(RDD.scala:885) 19:30:49 at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:1765) 19:30:49 at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:1765) 19:30:49 at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:63) 19:30:49 at org.apache.spark.scheduler.Task.run(Task.scala:70) 19:30:49 at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:213) 19:30:49 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) 19:30:49 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) 19:30:49 at java.lang.Thread.run(Thread.java:744) {code} This came up on jenkins for a doc only change PR. We've also seen jenkins intermittently fail the actor streaming job which uses the same api.

    DataStax JIRA | 2 years ago | Russell Spitzer
    com.datastax.driver.core.exceptions.InvalidQueryException: Invalid null value for partition key part key
  6. 0

    GitHub comment 85#49526609

    GitHub | 3 years ago | tobert
    com.datastax.driver.core.exceptions.NoHostAvailableException: All host(s) tried for query failed (no host was tried)

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. com.datastax.driver.core.exceptions.SyntaxError

      line 1:8 no viable alternative at input 'FROM' (SELECT [FROM]...)

      at com.datastax.driver.core.Responses$Error.asException()
    2. DataStax Java Driver for Apache Cassandra - Core
      SessionManager$4.apply
      1. com.datastax.driver.core.Responses$Error.asException(Responses.java:132)
      2. com.datastax.driver.core.SessionManager$4.apply(SessionManager.java:224)
      3. com.datastax.driver.core.SessionManager$4.apply(SessionManager.java:200)
      3 frames
    3. Guava
      Futures$1$1.run
      1. com.google.common.util.concurrent.Futures$ChainingListenableFuture.run(Futures.java:906)
      2. com.google.common.util.concurrent.Futures$1$1.run(Futures.java:635)
      2 frames