nadinemenezes Posted January 5, 2021 Report Share Posted January 5, 2021 Hi all Can anyone please assist me with a report query that will show duplicate couple entries. There is a lot of endogamy in my tree and I would like to identify if the same couple has been entered more than once. Thanks in advance! Quote Link to comment Share on other sites More sharing options...
RickM Posted January 5, 2021 Report Share Posted January 5, 2021 SELECT personID, lastname, firstname, birthdate, living, p.gedcom, et.tag AS Event, et.description, e.info FROM tng_people AS p LEFT JOIN tng_events AS e ON (e.persfamID=p.personID AND e.gedcom=p.gedcom) LEFT JOIN tng_eventtypes AS et ON e.eventtypeID=et.eventtypeID WHERE tag='EVEN' AND description='Spousename' GROUP BY personID, info HAVING COUNT(*)>1 ORDER BY lastname, firstname, birthdatetr; Not sure if this will give you what you want the description is as follows Wifes with duplicate marriage names (check for data plausibility) Vrouwen met een dubbele trouw naam. (Check naar de integriteit van de gegevens) This Query is from one of the reports in the Category:Henny Savenije - Reports on the TNG Wiki Quote Link to comment Share on other sites More sharing options...
nadinemenezes Posted January 5, 2021 Author Report Share Posted January 5, 2021 Not sure what I am doing wrong but it is not working Quote Link to comment Share on other sites More sharing options...
RickM Posted January 5, 2021 Report Share Posted January 5, 2021 Can you provide a screenshot of the error produced please Quote Link to comment Share on other sites More sharing options...
nadinemenezes Posted January 5, 2021 Author Report Share Posted January 5, 2021 No error Just shows no data: http://www.ourfamilyfacts.com/showreport.php?reportID=4 Quote Link to comment Share on other sites More sharing options...
RickM Posted January 5, 2021 Report Share Posted January 5, 2021 Have you made a change to the report?? If I run the report here I get headings 'LIVING' 'TREE' between 'BIRTHDATE' & 'EVENT' May I suggest also that you run the report from the Admin Reports Menu.. That way you can check the Query and if an error is produced get an idea of what that error is.. Quote Link to comment Share on other sites More sharing options...
nadinemenezes Posted January 7, 2021 Author Report Share Posted January 7, 2021 Which parts of the query do I need to amend to suit my tree? I suspect thats why it is not working for me? I also dont know how to run it from admin to check for errors Quote Link to comment Share on other sites More sharing options...
RickM Posted January 8, 2021 Report Share Posted January 8, 2021 You shouldn't 'need' to change the query to suit your 'Tree'. I do recall reading that different php versions treat sql queries slightly differently which meant the need to specify a tree, but cannot recall where I read that.. As for 'Running' a report from the admin screen.. Whilst in the Admin >> Reports screen you will see three boxes on the left of the inner screen.. the left most one is for 'Editing' the middle to 'Delete' and the right is to 'Test' the Report. Click on the Test box for the report you want to 'Run'.. Quote Link to comment Share on other sites More sharing options...
nadinemenezes Posted January 8, 2021 Author Report Share Posted January 8, 2021 Thanks so much Rick, This is what I am seeing (see attached) Appreciate your help with this Quote Link to comment Share on other sites More sharing options...
RickM Posted January 8, 2021 Report Share Posted January 8, 2021 Nadine, Everything seem to be correct in the running of that Query, so perhaps it is not quite the right query you need to show what you are wanting. Do you know of any 'couples'/families that have a duplicate entry and or any individuals that have a duplicate entry?? If so then obviously this query is not right for what you are asking, if not then unless someone else has used this query and had it find duplicate couples/families then I have exhausted the help I can provide.. I found this report here on the TNG WikiCategory:Henny Savenije - Reports You might find something better there. Quote Link to comment Share on other sites More sharing options...
nadinemenezes Posted January 8, 2021 Author Report Share Posted January 8, 2021 Thanks so much for your help, i will have a look there! Quote Link to comment Share on other sites More sharing options...
RickM Posted January 8, 2021 Report Share Posted January 8, 2021 I have no idea about SQL and creating reports, I remain however, at your service.. I will help with anything I can so please ask Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.