code: function (id) {
              var pk = this.primaryKey;
              pk = pk.length === 1 ? pk[0] : pk;
              var q = {};
              if (isArray(id) && isArray(pk)) {
                  if (id.length === pk.length) {
                      pk.forEach(function (k, i) {
                          q[k] = id[i];
                      });
                  } else {
                      throw new ModelError("findById : ids length does not equal the primaryKeys length.");
                  }
              } else {
                  q[pk] = id;
              }
              return this.filter(q).one();
          }
docs: Retrieves a record by the primaryKey/s of a table.
  
  @example
  
  var User = patio.getModel("user");
  
  User.findById(1).chain(function(userOne){
  
  });
  
  //assume the primary key is a compostie of first_name and last_name
  User.findById(["greg", "yukon"]).chain(function(userOne){
  
  });
  
  
  @param {*} id the primary key of the record to find.
  
  @return {comb.Promise} called back with the record or null if one is not found.