incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aaron morton <aa...@thelastpickle.com>
Subject Re: Deletes, null values
Date Sun, 28 Apr 2013 19:58:08 GMT
What's your table definition ? 

>> select '1228#16857','1228#16866','1228#16875','1237#16544','1237#16553'
>> from myCF where key = 'all';

The output looks correct to me. CQL table return values, including null, for all of the selected
columns.

Cheers

-----------------
Aaron Morton
Freelance Cassandra Consultant
New Zealand

@aaronmorton
http://www.thelastpickle.com

On 27/04/2013, at 12:48 AM, Sorin Manolache <sorinm@gmail.com> wrote:

> On 2013-04-26 11:55, Alain RODRIGUEZ wrote:
>> Of course:
>> 
>> From CQL 2 (cqlsh -2):
>> 
>> delete '183#16684','183#16714','183#16717' from myCF where key = 'all';
>> 
>> And selecting this data as follow gives me the result above:
>> 
>> select '1228#16857','1228#16866','1228#16875','1237#16544','1237#16553'
>> from myCF where key = 'all';
>> 
>> From thrift (phpCassa client):
>> 
>> $pool = new
>> ConnectionPool('myKeyspace',array('192.168.100.201'),6,0,30000,30000);
>> $my_cf= new ColumnFamily($pool, 'myCF', true, true,
>> ConsistencyLevel::QUORUM, ConsistencyLevel::QUORUM);
>> $my_cf->remove('all', array('1228#16857','1228#16866','1228#16875'));
>> 
> 
> I see. I'm sorry, I know nothing about phpCassa. I use batch_mutation with deletions
and it works. But I guess phpCassa must use the same thrift primitives.
> 
> Sorin
> 
> 
>> 
>> 
>> 2013/4/25 Sorin Manolache <sorinm@gmail.com <mailto:sorinm@gmail.com>>
>> 
>>    On 2013-04-25 11:48, Alain RODRIGUEZ wrote:
>> 
>>        Hi, I tried to delete some columns using cql2 as well as thrift on
>>        C*1.2.2 and instead of being unreachable, deleted columns have a
>>        null value.
>> 
>>        I am using no value in this CF, the only information I use is the
>>        existence of the column. So when I select all the column for a
>>        given key
>>        I have the following returned:
>> 
>>           1228#16857 | 1228#16866 | 1228#16875 | 1237#16544 | 1237#16553
>>        -------------------+----------__--------+------------------+--__-----------------+------------__------
>>                       null |              null |             null |
>>                  |
>> 
>> 
>>        This is quite annoying since my app thinks that I have 5 columns
>>        there
>>        when I should have 2 only.
>> 
>>        I first thought that this was a visible marker of tombstones but
>>        they
>>        didn't vanish after a major compaction.
>> 
>>        How can I get rid of these null/ghost columns and why does it
>>        happen ?
>> 
>> 
>>    I do something similar but I don't see null values. Could you please
>>    post the code where you delete the columns?
>> 
>>    Sorin
>> 
>> 
> 


Mime
View raw message