title: Yii 2: virtual fields in ActiveRecords
body: <p>I use MySQL and Yii 2. In database exist <code>table 'Regions' with column 'coordinates'</code>. Type of this column is point.</p>
  
  <p>In SQL I can write:
  <code>"SELECT X(coordinates) as x, Y(coordinates) as y"</code> and <code>"INSERT INTO Regions SET coordinates = PointFromText('POINT(".$x." ".$y.")')"</code>.</p>
  
  <p>But I don't know how make ActiveRecord model. I want this (unchanged the database):</p>
  
  <pre><code>$item = Regions::findOne(1);
  echo $item-&gt;x." ".$item-&gt;y;
  $item-&gt;x = $new_x;
  $item-&gt;y = $new_y;
  $item-&gt;save(); // data saved in 'coordinates' column
  </code></pre>
  
  <p>Methods <code>'set...()'</code> and <code>'get...()'</code> not help me. I want to avoid additional queries to the database.</p>
  
  <p>Please help me to do it.</p>