Cliquez ici pour la version francaise 
Oxy-Gen
Last update of the software :
May 17 2017 : Version 1.39f
The software
  Home
  Download
Documentation
  ChangeLog
  User manual
Users
  Forum
  Greetings
  Help
Links
  Search Engine
  Genealogical web sites
  Sites using Oxy-gen
 

FORUM

Previous message : Family problems

Next message : Application Error

Message

Titre : SQL/Oracle issues
Auteur : shaked
Date :18/10/2009 21:55
Now I can generate meaningful data in SQL/Oracle format, I have found a few minor bugs in the SQL.

1) create_base.sql The commit at the end is superfluous. DML statements such as CREATE TABLE and DROP TABLE do not require a COMMIT command, and in fact they themselves have the effect of committing any uncommitted changes.

2) create_base.sql - CREATE TABLE countries statement - Primary key is defined twice, once inline, and once as a separate constraint clause at the end. The command fails as a result. One of these should be removed.

3) create_base.sql - CREATE TABLE cities statement - This fails because it uses the same constraint name as the statement above it - i.e. pk_zones. The constraint needs to be renamed.

4) family.sql - The construction of this statement won't work. If you use values, it expects static values - it cannot extract a value from a sequence. In order to do this you need to remove the keyword values and use a bracketed SELECT statement from DUAL to follow the insert part of the clause.

5) family.sql - You need NEXTVAL not NEXVAL.

INSERT INTO family VALUES(seq_family.nexval,gedexp.ged'); This fails.

INSERT INTO family(id_family,file_name) (select seq_family.nextval,'gedexp.ged' from dual); This succeeds.

6) lix0.sql - The three final UNKNOWN records. Not enough values. For inserting into CITIES, you need a further 999999 for the ID_COUNTRY column, plus two further nulls at the end. For ZONES and COUNTRIES you also need to add some nulls at the end.

7) Generally it is better to quote the column names in brackets in INSERT statements to make the column assignments explicit rather than relying on Oracle to use the default order. Then INSERT statements don't fail if you have added new nullable fields to tables.

8) Finally this problem is giving me real worries and I would be grateful if you could respond - all entries in the INDIVIDUALS table show SEX= -1 whether they are MALE or FEMALE. In my .ged file the INDI records have either "1 SEX M" or "1 SEX F". Why does Oxy-gen not distinguish the sex in the table. What value should indicate MALE and which FEMALE ?

I hope these were useful and some help with the last one would be appreciated.


Answer(s)


Back to forum

Back to main menu


Post an answer

Author :

Title :

Message :

 

Anti-spam security : please enter the number twelve :


Previous message : Family problems

Next message : Application Error

Copyright (C) 2000-2017