Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3277496
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:22:31+00:00 2026-05-17T19:22:31+00:00

I am having a little play with an ORM but I am struggling to

  • 0

I am having a little play with an ORM but I am struggling to get off the starting blocks. I am familiar with Zend_Db and was hoping Doctrine would work in a similar way but with more flexibility.

I’ve followed the various tutorials, to integrate Doctrine with Zend Framework, which are available. All these tutorials more or less say the same thing.

I have made some base Doctrine_Record Classes and as far as I can gather you use Doctrine_Table in the same way you would use Zend_Db_Table_Abstract.

I haven’t figured out yet how you would tie a Record object to a Table object, but that’s another story.

The problem I have is when I try and fetch a table instance using…

    $role = Doctrine_Core::getTable('Admin_Model_RoleTable');

I get a series of fatal errors…

    Catchable fatal error: Argument 2 passed to Doctrine_Table::__construct() 
    must be an instance of Doctrine_Connection, none given

    Catchable fatal error: Argument 1 passed to Doctrine_Configurable::setParent()
    must be an instance of Doctrine_Configurable, null given

    Call to a member function addTable() on a non-object

I don’t know whether it has anything to do with the autoloaders, but as the table models are in the scope of the Module’s resources I wouldn’t think that would be a problem.

I should add that in my bootstrap I have added a connection that hijacks Zend_Db’s PDO just for this test.

    $manager = Doctrine_Manager::getInstance();
    $manager->connection($this->getResource('db')
            ->getConnection(), 'db'); 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T19:22:32+00:00Added an answer on May 17, 2026 at 7:22 pm

    I have discovered what I was doing wrong. I was trying to reference an instance of Doctrine_Table when I should have been referencing an instance of Doctrine_Record.

    The method name Doctrine_Core::getTable() was misleading

    These leaves me with more questions on how to structure the models?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having a little trouble getting Jquery to play nice with cakephp and I'm
I'm having a little trouble (more like an annoyance, really) when using the Play
I am having a play around with codeigniter and trying to get my head
still having problems - if I get my code to play the selected audio
I'm trying to get Visual Studio 2010 and StarTeam to play nice but I'm
I'm having little trouble creating a script working with URLs. I'm using urllib.urlopen() to
I m having little trouble finding a relation between the movement at centre and
Having a little difficulty getting a function to call after a .load: $(function(){ $('a.pageFetcher').click(function(){
Im having a little trouble with a php script ive made. you can see
im having a little issue here. I have MediaElement.js set on my project. It

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.