<?php

/**
 * NewsCategoryTable
 * 
 * This class has been auto-generated by the Doctrine ORM Framework
 */
class NewsCategoryTable extends Doctrine_Table
{
    /**
     * Returns an instance of this class.
     *
     * @return object NewsCategoryTable
     */
    public static function getInstance()
    {
        return Doctrine_Core::getTable('NewsCategory');
    }
	
	public function getNewsCat($news_id)
    {
	    $q = Doctrine_Query::create()

            ->from('NewsCategory c')

            ->where('c.news_id=?',$news_id)

            ->fetchOne();

        return $q;
    }
	
	public function getNewsCategory($news_id)
    {
	    $q = Doctrine_Query::create()

            ->from('NewsCategory c')

            ->where('c.news_id=?',$news_id)

            ->execute();

        return $q;
    }
	
}