jcfiala: (Default)

This is a blog post copied from John's Website - please feel free to join him there and post comments. He has set up openid, so you can post there with your livejournal account using your openid, which is the same as your journal url minus the http://. You can find this entry at http://www.jcfiala.net/blog/2014/08/29/using-doctrine-migrations-part-2-adding-data-migration.

(If you missed it, my previous post on this topic was Using Doctrine Migrations Without the ORM.)

So my previous blog post laid down a good start on how to use Doctrine to move changes to the database, but soon I ran into a new problem - what about when you have data to change in addition to changing the structure of the database? For instance, my first try at this was putting a default row of data into a new table, or maybe putting initial data into a new column?

My first try was simple, but unfortunately not quite right, I used the addSql() command:

<?php
class Version20140828145153 extends AbstractMigration
{
    public function
up(Schema $schema) {
    <
code that creates a new table>
   
$this->addSql("INSERT INTO <table> (this, that, theother) VALUES (...)");
    }
...
?>

Read more... )
jcfiala: (Default)

This is a blog post copied from John's Website - please feel free to join him there and post comments. He has set up openid, so you can post there with your livejournal account using your openid, which is the same as your journal url minus the http://. You can find this entry at http://www.jcfiala.net/blog/2014/08/21/using-doctrine-migrations-without-orm.

Recently I was handed a PHP project at work which already existed but the owner wanted a variety of tweaks and improvements added to it. The project wasn't built with any framework I could name, and although it has a sort of MVC feel to it, is not strictly an MVC project.

Read more... )
jcfiala: (Default)

This is a blog post copied from John's Website - please feel free to join him there and post comments. He has set up openid, so you can post there with your livejournal account using your openid, which is the same as your journal url minus the http://. You can find this entry at http://www.jcfiala.net/blog/2012/12/02/beginning-magento.

A month and a half ago I switched to a new job at SpireMedia as the 'Director of PHP Development', which so far has largely meant 'Drupal Guru', a position that I'm quite enjoying.

However, an interesting addition to Drupal is that we're starting up on Magento projects, starting with a website for a company that sells items with legal restrictions on how items are sold and shipped, and which already has a computer system for fulfillment of orders. This means that we need to not only set up a Magento site, but we need to add new rules for these legal restrictions and we're going to need to be able to talk to the existing system to pass data back and forth.

Read more... )
jcfiala: (Default)
Hey! I'm in Boston!

I'm here for the Drupalcon, which is here in Boston for this week, and at which I'll be happily hanging around at.

Still settling in after my trip, more later.

July 2017

S M T W T F S
      1
2345678
91011 12131415
16171819202122
23242526272829
3031     

Syndicate

RSS Atom

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Aug. 18th, 2017 01:04 am
Powered by Dreamwidth Studios