Im using thrift directly on C# the code that is trying to delete all the columns referencing the row im deleting on the secondary index rows looks like this
Mutation mutation = new Mutation(); mutation.Deletion = new Deletion(); mutation.Deletion.Timestamp = DateTime.Now.ToBinary(); List<byte[]> predicate = new List<byte[]>(); predicate.Add(utf8.GetBytes(columnName)); mutation.Deletion.Predicate = new SlicePredicate() { Column_names = predicate }; mutations.Add(mutation); entry = new Dictionary<string, List<Mutation>>(); entry.Add(cfName, mutations); mutation_map.Add(utf8EncodingInstance.GetBytes(secIndexKey), entry); CassandraClient.batch_mutate(mutation_map, ConsistencyLevel.ONE); now, the code where I inserted the references is exactly the same, but without the deletion part in the mutations Nicolas Santini On Thu, Dec 16, 2010 at 12:55 PM, Tyler Hobbs <ty...@riptano.com> wrote: > What client are you using? If you're not using a client, what does your > deletion code look like? > > - Tyler > > > On Wed, Dec 15, 2010 at 4:58 PM, Nick Santini <nick.sant...@kaseya.com>wrote: > >> thats not exactly what im seeing, is not a row, but columns on a row that >> i was deleting >> >> ie: >> suppose i have a row where the key is sec_index_1 where i have two columns >> with information about other row keys >> sec_index_1 { key1:key1, key2:key2 } >> >> then i add a deletion for the column named key2, run it through batch >> mutate for the key sec_index_1 >> >> then i load the row again to see all my "references" stored in columns, >> and im still getting >> key1, key2 >> >> Nicolas Santini >> >> >> On Thu, Dec 16, 2010 at 11:52 AM, Tyler Hobbs <ty...@riptano.com> wrote: >> >>> There's no problem doing deletions with batch_mutate, but you are >>> probably seeing this: >>> >>> http://wiki.apache.org/cassandra/FAQ#range_ghosts >>> >>> - Tyler >>> >>> >>> On Wed, Dec 15, 2010 at 4:26 PM, Nick Santini >>> <nick.sant...@kaseya.com>wrote: >>> >>>> since the 0.7beta2 version doesnt support indexes for Super CF or for >>>> columns that you might not now the name yet, im supporting them manually by >>>> adding a row on the same CF where the key is the name of the column plus >>>> the >>>> value, and in the columns hold the key to the referenced rows >>>> >>>> this works as in i can actually find my rows using the secondary index >>>> rows >>>> >>>> but when i try to delete the original row i want to update my secondary >>>> indexs, so i create a mutation map in the same way i did it when i saved my >>>> information, but this time it only contains deletions for those secondary >>>> indexs rows and only for the column referencing to the row being deleted. >>>> but this doesnt seem to work, it comes back successfully (no erros), but >>>> im still able to find the references to the deleted row in those secondary >>>> indexes >>>> >>>> is there any issue trying to run a batch_mutate with only deletions? >>>> >>>> thanks >>>> >>>> Nicolas Santini >>>> >>>> >>> >> >