All pastes #744457 Raw Edit

Something

public text v1 · immutable
·published 2007-10-21 14:42 UTC
rendered paste body
				// Calculate $transportPrice
				$c = new Criteria();
				$c->add(TownsDistancesPeer::TOWN_A, 1);
				$c->add(TownsDistancesPeer::TOWN_A, 2);
				$row = TownsDistancesPeer::doSelectOne($c);
				
				$transportPrice = $row->getDistance();


this will throw this error:
 [wrapped: Could not execute query [Native Error: Unknown column 'towns_distances.ID' in 'field list'] [User Info: SELECT towns_distances.TOWN_A, towns_distances.TOWN_B, towns_distances.DISTANCE, towns_distances.ID FROM towns_distances WHERE towns_distances.TOWN_A=2 LIMIT 1]]