+ /**
+ * Get the parent row
+ * @see \pq\Gateway\Table::by()
+ * @param mixed $foreign table (name)
+ * @param string $ref
+ * @return \pq\Gateway\Rowset
+ */
+ function ofWhich($foreign, $ref = null) {
+ if (!($foreign instanceof Table)) {
+ $foreign = forward_static_call(
+ [get_class($this->getTable()), "resolve"],
+ $foreign
+ );
+ }
+ return $foreign->by($this, $ref);
+ }
+