Question
SQL Query to show individuals Birth Date
- Newbie67
-
Topic Author
- Offline
- New Member
-
Less
More
1 month 4 weeks ago #1
by Newbie67
www.onsverleden.eu | Running on webtrees 2.1.22 and making use of the great modules Vesta and MagicSunday on top of the JustLight theme
SQL Query to show individuals Birth Date was created by Newbie67
Does anyone knows the SQL Statement to show the birthdate of an individual ?
SELECT * FROM `wt_individuals` i shows the i_gedcom info, but how to extract the date of birth from that whole textblock into a single column ?
Any help is appreciated
SELECT * FROM `wt_individuals` i shows the i_gedcom info, but how to extract the date of birth from that whole textblock into a single column ?
Any help is appreciated
www.onsverleden.eu | Running on webtrees 2.1.22 and making use of the great modules Vesta and MagicSunday on top of the JustLight theme
Please Log in or Create an account to join the conversation.
- bertkoor
-
- Offline
- Platinum Member
-
- Greetings from Utrecht, Holland
1 month 4 weeks ago #2
by bertkoor
stamboom.BertKoor.nl runs on webtrees v2.2.1
Replied by bertkoor on topic SQL Query to show individuals Birth Date
Extracting it from wt_individuals is indeed near impossible.
There is another table `wt_dates` which is used for quick access. This contains all dates, so take int account there can be a baptism or christening. You could select the smallest per individual (select min(..) group by ...) and assume it's the date of birth.
NB: query only! Any update should be done with the regular webtrees GUI, otherwise you can easily get data corruption.
There is another table `wt_dates` which is used for quick access. This contains all dates, so take int account there can be a baptism or christening. You could select the smallest per individual (select min(..) group by ...) and assume it's the date of birth.
NB: query only! Any update should be done with the regular webtrees GUI, otherwise you can easily get data corruption.
stamboom.BertKoor.nl runs on webtrees v2.2.1
Please Log in or Create an account to join the conversation.