Cassandra select query in C#
<p>first of all, I'm new to Cassandra and I did read manuals and did some (basic) tutorials about how to set it up and communicate with it with C#. </p>

<p>I got a select query behind a button click event. When I execute the query I get the following error:</p>

<pre><code>An unhandled exception of type 'System.ArgumentOutOfRangeException' occurred in Cassandra.dll 
Additional information: Value to add was out of range.
</code></pre>

<p>the code:</p>

<pre><code>    private void bt_select_Click(object sender, EventArgs e)
    {
        Connect();
        Row result = session.Execute("select * from meters where id = 1 AND ConnectionMeterID = 2 ALLOW FILTERING").First();
        CloseConnection();
    }
</code></pre>

<p>Note* There actually exists a row with id 1 and ConnectionMeterID 2. </p>

<p>And this is the database:</p>

<pre><code>Create table meters (
ID       int,
ConnectionMeterID    int,
ConnectionMeterRevision     int,
PeriodStart  timestamp,
PeriodEnd    timestamp,
Volume1      float,Volume2       float,Volume3       float,
Volume4      float,Volume5       float,Volume6       float,
Volume7      float,Volume8       float,
DataTypeID   int,
FileID       int,
Remarks      text,
QualityScore  decimal,
LocationID   int,
Removed      int,
PRIMARY KEY (ID, ConnectionMeterID));
</code></pre>

<p>Why does that error occur? </p>

<p>EDIT: Stacktrace </p>

<pre><code>&lt;code&gt; 'PloosCassandra.vshost.exe' (CLR v4.0.30319:  PloosCassandra.vshost.exe): Loaded  'C:\WINDOWS\Microsoft.Net\assembly\GAC_MSIL\System.Numerics\v4.0_4.0.0.0__b77a5c5 61934e089\System.Numerics.dll'. Cannot find or open the PDB file.
A first chance exception of type 'System.ArgumentOutOfRangeException'   occurred in Cassandra.dll
System.ArgumentOutOfRangeException: Value to add was out of range.
Parameter name: value
   at System.DateTime.Add(Double value, Int32 scale)
   at System.DateTimeOffset.AddMilliseconds(Double milliseconds)
   at     Cassandra.Serialization.Primitive.DateTimeOffsetSerializer.Deserialize(Byte[]    buffer, Int32 offset)
   at   Cassandra.Serialization.Primitive.DateTimeOffsetSerializer.Deserialize(UInt16   protocolVersion, Byte[] buffer, Int32 offset, Int32 length, IColumnInfo typeInfo)
   at Cassandra.Serialization.TypeSerializer   1.Cassandra.Serialization.ITypeSerializer.Deserialize(UInt16 protocolVersion,   Byte[] buffer, Int32 offset, Int32 length, IColumnInfo typeInfo)
   at Cassandra.Serialization.Serializer.Deserialize(Byte[] buffer, Int32   offset, Int32 length, ColumnTypeCode typeCode, IColumnInfo typeInfo)
   at Cassandra.FrameReader.ReadFromBytes(Byte[] buffer, Int32 offset, Int32   length, ColumnTypeCode typeCode, IColumnInfo typeInfo)
   at Cassandra.OutputRows.ProcessRowItem(FrameReader reader)
   at Cassandra.OutputRows.ProcessRows(RowSet rs, FrameReader reader)
   at Cassandra.OutputRows..ctor(FrameReader reader, Nullable 1 traceId)
   at Cassandra.Responses.ResultResponse..ctor(Frame frame)
   at Cassandra.Responses.ResultResponse.Create(Frame frame)
   at Cassandra.FrameParser.Parse(Frame frame)
   at Cassandra.Connection.&lt;&gt;c__DisplayClasse.  &lt;CreateResponseAction&gt;b__d(MemoryStream stream)
   at Cassandra.Tasks.TaskHelper.WaitToComplete(Task task, Int32 timeout)
   at Cassandra.Tasks.TaskHelper.WaitToComplete[T](Task 1 task, Int32 timeout)
   at Cassandra.Session.Execute(IStatement statement)
   at Cassandra.Session.Execute(String cqlQuery)
   at PloosCassandra.Form1.bt_select_Click(Object sender, EventArgs e) in    c:\Users\rudi\Documents\Visual Studio     2013\Projects\PloosCassandra\PloosCassandra\Form1.cs:line 58
</code></pre>