Fatal error on creating child record

I cannot save a child record and receive a fatal error. The PHP log gives the following:

[29-Dec-2020 22:50:24 America/New_York] PHP Fatal error: Uncaught Error: Call to undefined method ca_occurrences::typeCodeForID() in C:\wamp64\www\ca\app\lib\ResultContext.php:528
Stack trace:

0 C:\wamp64\www\ca\app\lib\ResultContext.php(506): ResultContext->setTypeRestriction('121')

1 C:\wamp64\www\ca\app\lib\BaseFindController.php(87): ResultContext->getTypeRestriction(false)

2 C:\wamp64\www\ca\app\lib\BaseRefineableSearchController.php(46): BaseFindController->__construct(Object(RequestHTTP), Object(ResponseHTTP), 'C:/wamp64/www/c...')

3 C:\wamp64\www\ca\app\controllers\find\SearchOccurrencesController.php(58): BaseRefineableSearchController->__construct(Object(RequestHTTP), Object(ResponseHTTP), 'C:/wamp64/www/c...')

4 C:\wamp64\www\ca\app\lib\AppNavigation.php(517): SearchOccurrencesController->__construct(Object(RequestHTTP), Object(ResponseHTTP), 'C:/wamp64/www/c...')

5 C:\wamp64\www\ca\app\lib\AppNavigation.php(607): AppNavigation->getDynamicSubmenu(Array)

6 C:\wamp64\www\ca\app\lib\AppNavigation.php(330): AppNavigation->_genMenu(Array, 'find', 'New/ in C:\wamp64\www\ca\app\lib\ResultContext.php on line 528

Can someone help me with this?
Many thanks.


  • What version are you running?

  • 1.7.9c3. Upgraded to 1.7.9c4, and problem does not replicate. However, I can't see any of the child records that I create. I apparently fail to understand how to get collection hierarchical (nested) records to show on screen. Can you help me understand what I am missing? Appreciate the help. I've been an archivist for 35 years, and a systems architect/computer programmer for 25, and CA appears to be over my head.

  • Ok so, the original problem on this thread is solved?

    In terms of hierarchical records, your system needs to be set up for that. This is a museum collections management application that can be set up to support archival hierarchies, but it's not centered around the concept of a collection hierarchy. So my first question (probably of many...) is: what installation profile are you using?

  • Yes, the upgrade to 1.7.9c4 solved the initial question here.

    I installed the default profile, Visual Resources Collection. I am helping a new architectural archives bootstrap their internal cataloging and reference website, and they wanted to use Collective Access. Their almost completely unprocessed collections will require hierarchical finding aids (e.g. Architectural Records, , , or ; Manuscripts, , , etc., before attaching tens of thousands of object records). Reading the CA website information gave me the sense this hierarchical support was built in. Can you recommend a better profile? Just to give scope, a single architectural project might have as many as 500 drawings, many dozens of assorted paper documents, and hundreds of photographs.

    Thank you much for your time, expertise, and generosity in helping.

  • edited December 2020

    The tools to implement hierarchical collections are built into the software, but it has to be set up. There are many different takes on how an archive should work, standards be damned, especially when the archive is interrelated with a museum and/or library collection (Museum/archive/library combos are a common use case for CA). The plus side of all this is that you can make it work the way you want; the down side is that assembly is required.

    For an archive you might try the ISAD_G or "[DACS] Heritage Muse" profile as a starting point. You may also try the artist foundation profile attached here, which is archives centered. To use the attached profile drop it into the install/profiles/xml/ directory in your installation.

    You'll probably need to modify any of these profiles to suit your project. The installation profile is just a preset for the initial state of a system. Once the installer has completed setting up a new system using the selected profile, the role of the profile is done. From there you can make modifications to the set using the web-based configuration tools. It's possible to export a profile with the definition of your running system for re-use elsewhere.

    You can also modify an existing profile and then reload it with the installer to implement your changes. Note that when you use the installer it will create a new system, erasing all setup and data. You'd obviously not want to do this on a system with actual data in it.

    When we develop configurations for projects the process generally looks like this:

    1. Pick an existing profile best suited to the project and modify.
    2. Install a test system with the modified profile.
    3. Identify issues and modify profile as needed.
    4. Reload profile and test, repeating steps 3 and 4 until done.

    Web-based configuration modifications are generally done in running systems (ie. systems with lots of data and actual users) when the changes are relatively straightforward. For larger changes to running systems there are other techniques, which I won't get into here.

    You can read more about profiles and the syntax here: https://manual.collectiveaccess.org/dataModelling/Profiles.html

    I hope this helps


  • Thank you again. This does help a great deal. I appreciate it.

Sign In or Register to comment.