You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by S G <sg...@gmail.com> on 2017/03/24 21:48:59 UTC

Weird error: InvalidQueryException: unconfigured table table2

Hi,

I have a keyspace with two tables.

I run a different query for each table:

Table 1:
  Select * from table1 where id = ?

Table 2:
  Select * from table2 where id1 = ? and id = ?


My code using datastax fires above two queries one after the other.
While it never fails for table 1, it never succeeds for table 2
And gives an error:


com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured
table table2
at com.datastax.driver.core.Responses$Error.asException(Responses.java:136)
at
com.datastax.driver.core.DefaultResultSetFuture.onSet(DefaultResultSetFuture.java:179)
at
com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:177)
at
com.datastax.driver.core.RequestHandler.access$2500(RequestHandler.java:46)
at
com.datastax.driver.core.RequestHandler$SpeculativeExecution.setFinalResult(RequestHandler.java:799)
at
com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:633)
at
com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1070)
at
com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:993)
at
io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
at
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
at
io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
at
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
at
io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
at
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
at
io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293)
at
io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
at
io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
at
io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1280)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
at
io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
at
io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:890)
at
io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131)
at
io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:564)
at
io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:505)
at
io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:419)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391)

Any idea what might be wrong?

I have confirmed that all table-names and columns names are lowercase.
Datastax java version tried : 3.1.2  and 3.1.4
Cassandra version: 3.10


Thanks
SG

Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by Arvydas Jonusonis <ar...@gmail.com>.
Prefixing with the ks is best practice, since it allows you to use a single
session for multiple keyspaces. Otherwise you'd have to have a desicated
session and set the keyspace by calling cluster.connect(ks)
On Sun, Mar 26, 2017 at 19:39 S G <sg...@gmail.com> wrote:

> Thanks, got it working now :)
>
> Just wish that an error like:
>    "Table x not found in keyspace y"
> would have been much better than:
>    "Table x not configured".
>
>
> On Sat, Mar 25, 2017 at 6:13 AM, Arvydas Jonusonis <
> arvydas.jonusonis@gmail.com> wrote:
>
> Make sure to prefix the table with the keyspace.
> On Sat, Mar 25, 2017 at 13:28 Anuj Wadehra <an...@yahoo.co.in> wrote:
>
> Ensure that all the nodes are on same schema version such that table2
> schema is replicated properly on all the nodes.
>
> Thanks
> Anuj
>
> Sent from Yahoo Mail on Android
> <https://overview.mail.yahoo.com/mobile/?.src=Android>
>
> On Sat, Mar 25, 2017 at 3:19 AM, S G
> <sg...@gmail.com> wrote:
> Hi,
>
> I have a keyspace with two tables.
>
> I run a different query for each table:
>
> Table 1:
>   Select * from table1 where id = ?
>
> Table 2:
>   Select * from table2 where id1 = ? and id = ?
>
>
> My code using datastax fires above two queries one after the other.
> While it never fails for table 1, it never succeeds for table 2
> And gives an error:
>
>
> com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured
> table table2
> at
> com.datastax.driver.core.Responses$Error.asException(Responses.java:136)
> at
> com.datastax.driver.core.DefaultResultSetFuture.onSet(DefaultResultSetFuture.java:179)
> at
> com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:177)
> at
> com.datastax.driver.core.RequestHandler.access$2500(RequestHandler.java:46)
> at
> com.datastax.driver.core.RequestHandler$SpeculativeExecution.setFinalResult(RequestHandler.java:799)
> at
> com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:633)
> at
> com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1070)
> at
> com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:993)
> at
> io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293)
> at
> io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1280)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:890)
> at
> io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131)
> at
> io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:564)
> at
> io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:505)
> at
> io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:419)
> at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391)
>
> Any idea what might be wrong?
>
> I have confirmed that all table-names and columns names are lowercase.
> Datastax java version tried : 3.1.2  and 3.1.4
> Cassandra version: 3.10
>
>
> Thanks
> SG
>
>
>
>

Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by Vladimir Yudovin <vl...@winguzone.com>.
&gt;Just wish that an error like:   "Table x not found in keyspace y"

You are welcome to open JIRA with type Improvement.





Best regards, Vladimir Yudovin, 

Winguzone - Cloud Cassandra Hosting






---- On Sun, 26 Mar 2017 13:31:33 -0400 S G &lt;sg.online.email@gmail.com&gt; wrote ----




Thanks, got it working now :)



Just wish that an error like:

   "Table x not found in keyspace y"

would have been much better than:

   "Table x not configured".







On Sat, Mar 25, 2017 at 6:13 AM, Arvydas Jonusonis &lt;arvydas.jonusonis@gmail.com&gt; wrote:






Make sure to prefix the table with the keyspace. 

On Sat, Mar 25, 2017 at 13:28 Anuj Wadehra &lt;anujw_2003@yahoo.co.in&gt; wrote:

Ensure that all the nodes are on same schema version such that table2 schema is replicated properly on all the nodes.



Thanks

Anuj



Sent from Yahoo Mail on Android






On Sat, Mar 25, 2017 at 3:19 AM, S G

&lt;sg.online.email@gmail.com&gt; wrote:



Hi,



I have a keyspace with two tables.



I run a different query for each table:



Table 1:

  Select * from table1 where id = ?



Table 2:

  Select * from table2 where id1 = ? and id = ?





My code using datastax fires above two queries one after the other.

While it never fails for table 1, it never succeeds for table 2

And gives an error:





com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured table table2

at com.datastax.driver.core.Responses$Error.asException(Responses.java:136) 

at com.datastax.driver.core.DefaultResultSetFuture.onSet(DefaultResultSetFuture.java:179) 

at com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:177) 

at com.datastax.driver.core.RequestHandler.access$2500(RequestHandler.java:46) 

at com.datastax.driver.core.RequestHandler$SpeculativeExecution.setFinalResult(RequestHandler.java:799) 

at com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:633) 

at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1070) 

at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:993) 

at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293) 

at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1280) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:890) 

at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131) 

at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:564) 

at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:505) 

at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:419) 

at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391) 




Any idea what might be wrong?



I have confirmed that all table-names and columns names are lowercase.

Datastax java version tried : 3.1.2  and 3.1.4

Cassandra version: 3.10





Thanks

SG

















Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by S G <sg...@gmail.com>.
Thanks, got it working now :)

Just wish that an error like:
   "Table x not found in keyspace y"
would have been much better than:
   "Table x not configured".


On Sat, Mar 25, 2017 at 6:13 AM, Arvydas Jonusonis <
arvydas.jonusonis@gmail.com> wrote:

> Make sure to prefix the table with the keyspace.
> On Sat, Mar 25, 2017 at 13:28 Anuj Wadehra <an...@yahoo.co.in> wrote:
>
>> Ensure that all the nodes are on same schema version such that table2
>> schema is replicated properly on all the nodes.
>>
>> Thanks
>> Anuj
>>
>> Sent from Yahoo Mail on Android
>> <https://overview.mail.yahoo.com/mobile/?.src=Android>
>>
>> On Sat, Mar 25, 2017 at 3:19 AM, S G
>> <sg...@gmail.com> wrote:
>> Hi,
>>
>> I have a keyspace with two tables.
>>
>> I run a different query for each table:
>>
>> Table 1:
>>   Select * from table1 where id = ?
>>
>> Table 2:
>>   Select * from table2 where id1 = ? and id = ?
>>
>>
>> My code using datastax fires above two queries one after the other.
>> While it never fails for table 1, it never succeeds for table 2
>> And gives an error:
>>
>>
>> com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured
>> table table2
>> at com.datastax.driver.core.Responses$Error.asException(
>> Responses.java:136)
>> at com.datastax.driver.core.DefaultResultSetFuture.onSet(
>> DefaultResultSetFuture.java:179)
>> at com.datastax.driver.core.RequestHandler.setFinalResult(
>> RequestHandler.java:177)
>> at com.datastax.driver.core.RequestHandler.access$2500(
>> RequestHandler.java:46)
>> at com.datastax.driver.core.RequestHandler$SpeculativeExecution.
>> setFinalResult(RequestHandler.java:799)
>> at com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(
>> RequestHandler.java:633)
>> at com.datastax.driver.core.Connection$Dispatcher.
>> channelRead0(Connection.java:1070)
>> at com.datastax.driver.core.Connection$Dispatcher.
>> channelRead0(Connection.java:993)
>> at io.netty.channel.SimpleChannelInboundHandler.channelRead(
>> SimpleChannelInboundHandler.java:105)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:342)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:328)
>> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
>> AbstractChannelHandlerContext.java:321)
>> at io.netty.handler.timeout.IdleStateHandler.channelRead(
>> IdleStateHandler.java:266)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:342)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:328)
>> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
>> AbstractChannelHandlerContext.java:321)
>> at io.netty.handler.codec.MessageToMessageDecoder.channelRead(
>> MessageToMessageDecoder.java:102)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:342)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:328)
>> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
>> AbstractChannelHandlerContext.java:321)
>> at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(
>> ByteToMessageDecoder.java:293)
>> at io.netty.handler.codec.ByteToMessageDecoder.channelRead(
>> ByteToMessageDecoder.java:267)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:342)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:328)
>> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
>> AbstractChannelHandlerContext.java:321)
>> at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(
>> DefaultChannelPipeline.java:1280)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:342)
>> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
>> AbstractChannelHandlerContext.java:328)
>> at io.netty.channel.DefaultChannelPipeline.fireChannelRead(
>> DefaultChannelPipeline.java:890)
>> at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(
>> AbstractNioByteChannel.java:131)
>> at io.netty.channel.nio.NioEventLoop.processSelectedKey(
>> NioEventLoop.java:564)
>> at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(
>> NioEventLoop.java:505)
>> at io.netty.channel.nio.NioEventLoop.processSelectedKeys(
>> NioEventLoop.java:419)
>> at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391)
>>
>> Any idea what might be wrong?
>>
>> I have confirmed that all table-names and columns names are lowercase.
>> Datastax java version tried : 3.1.2  and 3.1.4
>> Cassandra version: 3.10
>>
>>
>> Thanks
>> SG
>>
>>
>>

Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by Arvydas Jonusonis <ar...@gmail.com>.
Make sure to prefix the table with the keyspace.
On Sat, Mar 25, 2017 at 13:28 Anuj Wadehra <an...@yahoo.co.in> wrote:

> Ensure that all the nodes are on same schema version such that table2
> schema is replicated properly on all the nodes.
>
> Thanks
> Anuj
>
> Sent from Yahoo Mail on Android
> <https://overview.mail.yahoo.com/mobile/?.src=Android>
>
> On Sat, Mar 25, 2017 at 3:19 AM, S G
> <sg...@gmail.com> wrote:
> Hi,
>
> I have a keyspace with two tables.
>
> I run a different query for each table:
>
> Table 1:
>   Select * from table1 where id = ?
>
> Table 2:
>   Select * from table2 where id1 = ? and id = ?
>
>
> My code using datastax fires above two queries one after the other.
> While it never fails for table 1, it never succeeds for table 2
> And gives an error:
>
>
> com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured
> table table2
> at
> com.datastax.driver.core.Responses$Error.asException(Responses.java:136)
> at
> com.datastax.driver.core.DefaultResultSetFuture.onSet(DefaultResultSetFuture.java:179)
> at
> com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:177)
> at
> com.datastax.driver.core.RequestHandler.access$2500(RequestHandler.java:46)
> at
> com.datastax.driver.core.RequestHandler$SpeculativeExecution.setFinalResult(RequestHandler.java:799)
> at
> com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:633)
> at
> com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1070)
> at
> com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:993)
> at
> io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293)
> at
> io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)
> at
> io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1280)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)
> at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)
> at
> io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:890)
> at
> io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131)
> at
> io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:564)
> at
> io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:505)
> at
> io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:419)
> at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391)
>
> Any idea what might be wrong?
>
> I have confirmed that all table-names and columns names are lowercase.
> Datastax java version tried : 3.1.2  and 3.1.4
> Cassandra version: 3.10
>
>
> Thanks
> SG
>
>
>

Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by Anuj Wadehra <an...@yahoo.co.in>.
Ensure that all the nodes are on same schema version such that table2 schema is replicated properly on all the nodes.
ThanksAnuj

Sent from Yahoo Mail on Android 
 
  On Sat, Mar 25, 2017 at 3:19 AM, S G<sg...@gmail.com> wrote:   Hi,
I have a keyspace with two tables.
I run a different query for each table:
Table 1:  Select * from table1 where id = ?
Table 2:  Select * from table2 where id1 = ? and id = ?

My code using datastax fires above two queries one after the other.While it never fails for table 1, it never succeeds for table 2And gives an error:

com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured table table2 at com.datastax.driver.core.Responses$Error.asException(Responses.java:136)  at com.datastax.driver.core.DefaultResultSetFuture.onSet(DefaultResultSetFuture.java:179)  at com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:177)  at com.datastax.driver.core.RequestHandler.access$2500(RequestHandler.java:46)  at com.datastax.driver.core.RequestHandler$SpeculativeExecution.setFinalResult(RequestHandler.java:799)  at com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:633)  at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1070)  at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:993)  at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)  at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)  at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)  at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)  at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)  at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)  at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293)  at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)  at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321)  at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1280)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342)  at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328)  at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:890)  at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131)  at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:564)  at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:505)  at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:419)  at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391) 
Any idea what might be wrong?
I have confirmed that all table-names and columns names are lowercase.Datastax java version tried : 3.1.2  and 3.1.4Cassandra version: 3.10

ThanksSG

  

Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by Vladimir Yudovin <vl...@winguzone.com>.
&gt;Wish the error message a little more helpful.

Actually "unconfigured" means "not existed", "not created".





Best regards, Vladimir Yudovin, 

Winguzone - Cloud Cassandra Hosting






---- On Fri, 24 Mar 2017 21:39:45 -0400 S G &lt;sg.online.email@gmail.com&gt; wrote ----




Ah, the keyspace for table2 was somehow getting hardcoded to a wrong keyspace.



Wish the error message a little more helpful.






On Fri, Mar 24, 2017 at 2:48 PM, S G &lt;sg.online.email@gmail.com&gt; wrote:






Hi,



I have a keyspace with two tables.



I run a different query for each table:



Table 1:

  Select * from table1 where id = ?



Table 2:

  Select * from table2 where id1 = ? and id = ?





My code using datastax fires above two queries one after the other.

While it never fails for table 1, it never succeeds for table 2

And gives an error:





com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured table table2

at com.datastax.driver.core.Responses$Error.asException(Responses.java:136) 

at com.datastax.driver.core.DefaultResultSetFuture.onSet(DefaultResultSetFuture.java:179) 

at com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:177) 

at com.datastax.driver.core.RequestHandler.access$2500(RequestHandler.java:46) 

at com.datastax.driver.core.RequestHandler$SpeculativeExecution.setFinalResult(RequestHandler.java:799) 

at com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:633) 

at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1070) 

at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:993) 

at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:266) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:293) 

at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:267) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:321) 

at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1280) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:342) 

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:328) 

at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:890) 

at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:131) 

at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:564) 

at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:505) 

at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:419) 

at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391) 




Any idea what might be wrong?



I have confirmed that all table-names and columns names are lowercase.

Datastax java version tried : 3.1.2  and 3.1.4

Cassandra version: 3.10





Thanks

SG











Re: Weird error: InvalidQueryException: unconfigured table table2

Posted by S G <sg...@gmail.com>.
Ah, the keyspace for table2 was somehow getting hardcoded to a wrong
keyspace.

Wish the error message a little more helpful.


On Fri, Mar 24, 2017 at 2:48 PM, S G <sg...@gmail.com> wrote:

> Hi,
>
> I have a keyspace with two tables.
>
> I run a different query for each table:
>
> Table 1:
>   Select * from table1 where id = ?
>
> Table 2:
>   Select * from table2 where id1 = ? and id = ?
>
>
> My code using datastax fires above two queries one after the other.
> While it never fails for table 1, it never succeeds for table 2
> And gives an error:
>
>
> com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured
> table table2
> at com.datastax.driver.core.Responses$Error.asException(
> Responses.java:136)
> at com.datastax.driver.core.DefaultResultSetFuture.onSet(
> DefaultResultSetFuture.java:179)
> at com.datastax.driver.core.RequestHandler.setFinalResult(
> RequestHandler.java:177)
> at com.datastax.driver.core.RequestHandler.access$2500(
> RequestHandler.java:46)
> at com.datastax.driver.core.RequestHandler$SpeculativeExecution.
> setFinalResult(RequestHandler.java:799)
> at com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(
> RequestHandler.java:633)
> at com.datastax.driver.core.Connection$Dispatcher.
> channelRead0(Connection.java:1070)
> at com.datastax.driver.core.Connection$Dispatcher.
> channelRead0(Connection.java:993)
> at io.netty.channel.SimpleChannelInboundHandler.channelRead(
> SimpleChannelInboundHandler.java:105)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:342)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:328)
> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
> AbstractChannelHandlerContext.java:321)
> at io.netty.handler.timeout.IdleStateHandler.channelRead(
> IdleStateHandler.java:266)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:342)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:328)
> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
> AbstractChannelHandlerContext.java:321)
> at io.netty.handler.codec.MessageToMessageDecoder.channelRead(
> MessageToMessageDecoder.java:102)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:342)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:328)
> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
> AbstractChannelHandlerContext.java:321)
> at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(
> ByteToMessageDecoder.java:293)
> at io.netty.handler.codec.ByteToMessageDecoder.channelRead(
> ByteToMessageDecoder.java:267)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:342)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:328)
> at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(
> AbstractChannelHandlerContext.java:321)
> at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(
> DefaultChannelPipeline.java:1280)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:342)
> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(
> AbstractChannelHandlerContext.java:328)
> at io.netty.channel.DefaultChannelPipeline.fireChannelRead(
> DefaultChannelPipeline.java:890)
> at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(
> AbstractNioByteChannel.java:131)
> at io.netty.channel.nio.NioEventLoop.processSelectedKey(
> NioEventLoop.java:564)
> at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(
> NioEventLoop.java:505)
> at io.netty.channel.nio.NioEventLoop.processSelectedKeys(
> NioEventLoop.java:419)
> at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:391)
>
> Any idea what might be wrong?
>
> I have confirmed that all table-names and columns names are lowercase.
> Datastax java version tried : 3.1.2  and 3.1.4
> Cassandra version: 3.10
>
>
> Thanks
> SG
>
>
>