[Babase] Now I'm stuck in mtd_cycles

kfenn kfenn at princeton.edu
Wed Jan 23 11:50:47 EST 2008


Hi Karl,

I'm now stuck trying to use UPLOAD to get the mtd_cycles in.  I'm 
getting the following error:

ERROR: insert or update on table "cycpoints" violates foreign key 
constraint "Cid on CYCLES" DETAIL: Key (cid)=(26762) is not present in 
table "cycles".

I started with a whole group of cycles for Omos group but now now am 
just trying single cycles.  Each time I try again, the cid number 
changes so this error doesn't seem linked to a specific 
individual...it's like it can't parse the info back into the tables 
correctly from the view, but I really don't want to have to upload into 
the tables themselves.  That was the whole point of having the views. 

I've re-read your email advice from before (below) and read the 
documentations on the mtd_cycles view but I can't figure this out and 
I'm all out of chickens.


Tabby

Karl O. Pinc wrote:
>> Upload cycles sub-table to master CYCLES table (do Upcen) (Bb 2.0 use 
>> UPLOAD program to append to mtd_cycles view?)
>
> Yes.
>
> Note that Babase 2.0 decides on it's own which dates belong to which
> cycle.  Uploading will go faster if the cycle dates for any given
> female are entered in datewise order.  (I think that's the fast way.)
>
> In other words, you could upload into the CYCPOINTS_CYCLES view,
> just the Sname, Date, and Code columns, if that was any easier.
> Or just put Mdates, Ddates, and Tdates into MTD_CYCLES, but have
> only a single Mdate, Ddate, or Tdate in each row, etc.  The system
> should glom them together into cycles.
>
> Regardless of how the data goes in, after the first update it's
> probably worth checking (again!, for the last time?) that the
> system has (re)glommed the dates into cycles like it ought.
>

-- 
Tabby Fenn
Research Assistant

Dept of Ecology and Evolutionary Biology
401 Guyot Hall
Princeton University
Princeton, NJ  08544

609 258-6898 (Ph)
609 258-2712 (Fx)



More information about the Babase mailing list