cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From S Ahmed <>
Subject Pelops 'up and running' post question + WTF is a SuperColumn => really confused.
Date Fri, 02 Jul 2010 16:29:57 GMT

So using the code snipped below, I want to create a json representation of
the CF (super).

 * Write multiple sub-column values to a super column...
 * @param rowKey                    The key of the row to modify
 * @param colFamily                 The name of the super column family to
operate on
 * @param colName                   The name of the super column
 * @param subColumns                A list of the sub-columns to write
mutator. writeSubColumns(
    UuidHelper.newTimeUuidBytes(), // using a UUID value that sorts by time
        mutator.newColumn("category", "videoPhone"),
        mutator.newColumn("reportType", "POOR_PICTURE"),
        mutator.newColumn("capture", jpegBytes),
        mutator.newColumn("comment") ));

Can someone show me what it would look like?

This is what I have so far....

SupportTickets = {

    userId : {

        L1Tickets : { }



But from what I understood, a CF of type super looks like ( :

AddressBook = { // this is a ColumnFamily of type Super
    phatduckk: {    // this is the key to this row inside the Super CF
        // the key here is the name of the owner of the address book

        // now we have an infinite # of super columns in this row
        // the keys inside the row are the names for the SuperColumns
        // each of these SuperColumns is an address book entry
        friend1: {street: "8th street", zip: "90210", city: "Beverley
Hills", state: "CA"},

        // this is the address book entry for John in phatduckk's address
        John: {street: "Howard street", zip: "94404", city: "FC", state:
        Kim: {street: "X street", zip: "87876", city: "Balls", state: "VA"},
        Tod: {street: "Jerry street", zip: "54556", city: "Cartoon", state:
        Bob: {street: "Q Blvd", zip: "24252", city: "Nowhere", state: "MN"},
        // we can have an infinite # of ScuperColumns (aka address book
    }, // end row
    ieure: {     // this is the key to another row in the Super CF
        // all the address book entries for ieure
        joey: {street: "A ave", zip: "55485", city: "Hell", state: "NV"},
        William: {street: "Armpit Dr", zip: "93301", city: "Bakersfield",
state: "CA"},

The Pelop's code snippet seems to be adding an additional inner layer to
this to me, confused!

View raw message