public int update(Database database,Shard shard) throws SQLException {
  ArrayList<Column> whereClause=new ArrayList<Column>();
  ArrayList<Column> values=new ArrayList<Column>();
  shardName.setValue(shard.getShardId());
  whereClause.add(shardName);
  shardCritical.setValue(shard.isCritical());
  shardMaster.setValue(shard.getMaster());
  values.add(shardMaster);
  values.add(shardCritical);
  return database.update(shardTable,whereClause,values);
}

public int update ( Database database , Shard shard ) throws SQLException { ArrayList < Column > whereClause = new ArrayList < Column > ( ) ; ArrayList < Column > values = new ArrayList < Column > ( ) ; shardName . setValue ( shard . getShardId ( ) ) ; whereClause . add ( shardName ) ; shardCritical . setValue ( shard . isCritical ( ) ) ; shardMaster . setValue ( shard . getMaster ( ) ) ; values . add ( shardMaster ) ; values . add ( shardCritical ) ; return database . update ( shardTable , whereClause , values ) ; }
update an existing shard definition . the shard must exist .
