chiark
/
gitweb
/
~naath
/
familyTree.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
01c562fcd86a40819828e5b0f87ca33597c771b5
[familyTree.git]
/
familyTree
/
spousesRelated.py
1
#!/usr/bin/python
2
3
4
import askQuestion
5
import sys
6
import re
7
8
conn = askQuestion.connect()
9
10
11
s = "select * from marriages;"
12
13
for row in askQuestion.run_query(s,()):
14
ID1=row[0]
15
ID2=row[1]
16
17
back = askQuestion.common_ancestors(ID1,ID2,'\n')
18
if len(back[1])>0:
19
print back[2]
20
21
askQuestion.close(conn)
22
23
24
25