Text List / Table question


#1

I’m reworking my cattle database for Panorama X. I want to record the calves produced by a cow over her reproductive life. In Panorama 6, I simply recorded the calves as individuals in the database with ‘x’ as their mother. I would search the database for beasts mothered by ‘x’, and then return to my previous selection when I was done.

As Panorama X tends to search more slowly, I was thinking I’d record the calves in the mother’s information, only transferring them to the database themselves if they were kept. I had visions of creating a field in which I stored a preformatted array, which would be added to as subsequent calves were born, and which could automatically be viewed as a table in a form (DOB, M/F, description). Having scoured the help pages and examples, learning about arraycolumns etc, I still haven’t figured out anything remotely looking like working. I’m not sure whether this reflects my lack of programming knowledge, or just that I am imagining an impossibility.

The other way I thought of saving the data was as line items (DOBΩ, M/FΩ, descriptionΩ), but I actually haven’t figured out how to present this in a table either, unless I manually make one of Text Display objects, set out as a table.

Any suggestions on either

  • how to do what I am wanting to do
    or
  • other ways of approaching the task
    would be greatly appreciated.

#2

The best way to display it is either with a text list or a matrix that is updated whenever you look at the mother’s record. Which is better depends on how much you want to show about each calf. Take a look in the Panorama Help under Text List Object and Text List Constructor to get a good idea of how to get started with it.

You won’t have to deal with arraycolumns


#3

Thanks. I don’t think you quite grasped my question there - but I was definitely overthinking that problem - have now sorted out tables for both mothers and fathers.
I still have a question about the “Query” section of the Text List. I am working between 2 databases - the mother/father in one, and the progeny in the other. I want the query to relate to the appropriate progeny, but I couldn’t figure out a way to ask the one database about the other (show data in database 2, where the mother is the selected beast in database 1). I’ve worked around this by using the button to start the process to make a global variable of the mother or father’s identifier, and then using the query dam=global variable. I tried to put the variable allocation into the form procedure, but it performed the procedure after making the list, so it was always the list for the last beast selected, rather than the present one!
It is working as I have it, but just interested to know if there is a neater way of doing it?


#4

I think you have come up with the correct way to do it.