List:NDB Connectors« Previous MessageNext Message »
From:tarbin jiang Date:February 4 2009 8:31am
Subject:how to delete all records which has same key value in a multi-key
View as plain text  
there is a multi-key table in my mysql cluster, such as :
column name                   column type                is key
column1                           varchar                      true
column2                           smallint                      true
column3                           text                           false
how should I delete all records which has same column1 value with deleteOperation?
bellow is what I did:
        NdbTransaction trans = ndb.startTransaction();        NdbOperation op =
        op.equalString("column1", "100");
        ret = trans.execute(ExecType.Commit, AbortOption.AbortOnError,true);       
it return following error: 
com.mysql.cluster.ndbj.NdbApiPermanentException: Operation was not defined correctly,
probably missing a key
how should I do?

News, entertainment and everything you care about at Get it now!
how to delete all records which has same key value in a multi-keytable?tarbin jiang4 Feb