2017 © Pedro Peláez
 

library san-db-modelling-with-zend-db

ZF2 Module that utilize example of modelling with Zend\Db

image

san/san-db-modelling-with-zend-db

ZF2 Module that utilize example of modelling with Zend\Db

  • Monday, January 19, 2015
  • by samsonasik
  • Repository
  • 1 Watchers
  • 2 Stars
  • 3 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Zend\Db relational example usage

Why Modelling ? Why not Just "join" direclty ?

It show us what property/column comes from., (*1)

  • import these sql ( data are fake :) ) :

DROP TABLE IF EXISTS `album`; CREATE TABLE IF NOT EXISTS `album` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `artist` varchar(255) NOT NULL, `title` varchar(255) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ; -- -- Dumping data for table `album` -- INSERT INTO `album` (`id`, `artist`, `title`) VALUES (1, 'Bruno Mars', 'Go'), (2, 'Syahrini', 'Membahana'), (3, 'Justin Timberlake', 'Love'); -- -------------------------------------------------------- -- -- Table structure for table `track` -- DROP TABLE IF EXISTS `track`; CREATE TABLE IF NOT EXISTS `track` ( `id` bigint(20) NOT NULL AUTO_INCREMENT, `title` varchar(255) DEFAULT NULL, `album_id` bigint(20) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ; -- -- Dumping data for table `track` -- INSERT INTO `track` (`id`, `title`, `album_id`) VALUES (1, 'Sesuatu', 2), (2, 'Aku Tak Biasa', 2), (3, 'Grenade', 1), (4, 'I like it!', 1);
  • go to :
http://yourzf2app/zenddbmodelling

reference : https://gist.github.com/ralphschindler/6910421, (*2)

The Versions

19/01 2015

dev-master

9999999-dev https://github.com/samsonasik/SanAuthWithDbSaveHandler

ZF2 Module that utilize example of modelling with Zend\Db

  Sources   Download

MIT

The Requires

  • php >=5.3.3

 

zf2 db modelling