ox-it / ords

Automatically exported from code.google.com/p/ords
0 stars 0 forks source link

new relationships defined between tables in the schema builder disappear even though they appear to have saved correctly #744

Closed jajwilson closed 8 years ago

jajwilson commented 8 years ago

Load the sql dump of the Irish Surgeons database into ORDS. Add a relationship between people.id and education.person. Save it. Note that everything appears to save just fine. Exit the schema designer Go back into the schema designer Notice that the relationship you just defined is no longer there.

This issue has been introduced over the last few day, seemingly due to efforts to fix issue #742 (although this may be coincidence).

jajwilson commented 8 years ago

Take a look at 'Irish Surgeons 3' in the 'Standard Test' project on Dev to see this bug in action.

thestoat commented 8 years ago

I have just looked at this database and it seems you have picked the only example where the problem occurs? I tried linking people.id to education.university, for example, and that worked fine. I have a feeling the "person" column has been corrupted somehow. Please upload a new version of the db and try again. If the problem persists, please send me the db

jajwilson commented 8 years ago

Ah, I think you're on to something. I uploaded the same sql dump again and had exactly the same problem, but then I re-ran my Python script that generates the db, dumped that, and when I uploaded the newer version I could make the link and get it to stick.

I'm still not sure what was wrong with the original dump, as I hadn't made any changes to the bit of the script that sets up and populates the two tables in question, but I guess it must have been some sort of underlying problem in the db rather than the ORDS that was causing the problem. Mind you, it's still pretty weird behaviour from the ORDS and we should look out for this issue cropping up again.