Step 1: Select rows where 'year' is between 1995 and 2008.
year |
races |
wins |
poles |
top_5 |
top_10 |
dnf |
finish |
start |
winnings |
season_rank |
team__s_ |
1995 |
2 |
0 |
0 |
0 |
0 |
0 |
24.0 |
37.0 |
5225 |
75th |
stegell motorsports |
1996 |
14 |
0 |
0 |
0 |
0 |
6 |
26.4 |
25.1 |
63865 |
42nd |
stegell motorsports |
1997 |
28 |
0 |
1 |
0 |
1 |
10 |
27.1 |
21.6 |
196656 |
23rd |
stegell motorsports |
1998 |
31 |
0 |
1 |
0 |
3 |
5 |
24.9 |
25.5 |
335163 |
19th |
stegell motorsports |
1999 |
25 |
0 |
0 |
1 |
1 |
9 |
25.8 |
18.2 |
243810 |
24th |
curb - agajanian performance group |
2000 |
2 |
0 |
0 |
0 |
0 |
1 |
35.0 |
28.5 |
15900 |
90th |
alumni motorsports |
2001 |
33 |
0 |
0 |
0 |
0 |
6 |
27.9 |
32.7 |
491977 |
23rd |
hensley racing |
2002 |
24 |
0 |
0 |
0 |
1 |
11 |
27.0 |
33.0 |
288325 |
29th |
hensley racing |
2003 |
5 |
0 |
0 |
0 |
0 |
4 |
35.8 |
25.6 |
68360 |
85th |
jay robinson racing |
2004 |
9 |
0 |
0 |
0 |
0 |
6 |
31.4 |
37.2 |
139685 |
54th |
moy racing / jay robinson racing |
2005 |
7 |
0 |
0 |
0 |
0 |
7 |
40.9 |
32.6 |
108921 |
83rd |
jay robinson racing |
2006 |
9 |
0 |
0 |
0 |
0 |
7 |
38.9 |
39.1 |
151184 |
70th |
jay robinson racing |
2008 |
1 |
0 |
0 |
0 |
0 |
1 |
43.0 |
34.0 |
15674 |
149th |
jay robinson racing |
Step 2: Extract the sum of 'races' column then add column 'total_races' to existing table.
year |
races |
wins |
poles |
top_5 |
top_10 |
dnf |
finish |
start |
winnings |
season_rank |
team__s_ |
1995 |
2 |
0 |
0 |
0 |
0 |
0 |
24.0 |
37.0 |
5225 |
75th |
stegell motorsports |
1996 |
14 |
0 |
0 |
0 |
0 |
6 |
26.4 |
25.1 |
63865 |
42nd |
stegell motorsports |
1997 |
28 |
0 |
1 |
0 |
1 |
10 |
27.1 |
21.6 |
196656 |
23rd |
stegell motorsports |
1998 |
31 |
0 |
1 |
0 |
3 |
5 |
24.9 |
25.5 |
335163 |
19th |
stegell motorsports |
1999 |
25 |
0 |
0 |
1 |
1 |
9 |
25.8 |
18.2 |
243810 |
24th |
curb - agajanian performance group |
2000 |
2 |
0 |
0 |
0 |
0 |
1 |
35.0 |
28.5 |
15900 |
90th |
alumni motorsports |
2001 |
33 |
0 |
0 |
0 |
0 |
6 |
27.9 |
32.7 |
491977 |
23rd |
hensley racing |
2002 |
24 |
0 |
0 |
0 |
1 |
11 |
27.0 |
33.0 |
288325 |
29th |
hensley racing |
2003 |
5 |
0 |
0 |
0 |
0 |
4 |
35.8 |
25.6 |
68360 |
85th |
jay robinson racing |
2004 |
9 |
0 |
0 |
0 |
0 |
6 |
31.4 |
37.2 |
139685 |
54th |
moy racing / jay robinson racing |
2005 |
7 |
0 |
0 |
0 |
0 |
7 |
40.9 |
32.6 |
108921 |
83rd |
jay robinson racing |
2006 |
9 |
0 |
0 |
0 |
0 |
7 |
38.9 |
39.1 |
151184 |
70th |
jay robinson racing |
2008 |
1 |
0 |
0 |
0 |
0 |
1 |
43.0 |
34.0 |
15674 |
149th |
jay robinson racing |
Step 3: Select rows where 'total_races' is equal to 190.
year |
races |
wins |
poles |
top_5 |
top_10 |
dnf |
finish |
start |
winnings |
season_rank |
team__s_ |
total_races |
1995 |
2 |
0 |
0 |
0 |
0 |
0 |
24.0 |
37.0 |
5225 |
75th |
stegell motorsports |
190 |
1996 |
14 |
0 |
0 |
0 |
0 |
6 |
26.4 |
25.1 |
63865 |
42nd |
stegell motorsports |
190 |
1997 |
28 |
0 |
1 |
0 |
1 |
10 |
27.1 |
21.6 |
196656 |
23rd |
stegell motorsports |
190 |
1998 |
31 |
0 |
1 |
0 |
3 |
5 |
24.9 |
25.5 |
335163 |
19th |
stegell motorsports |
190 |
1999 |
25 |
0 |
0 |
1 |
1 |
9 |
25.8 |
18.2 |
243810 |
24th |
curb - agajanian performance group |
190 |
2000 |
2 |
0 |
0 |
0 |
0 |
1 |
35.0 |
28.5 |
15900 |
90th |
alumni motorsports |
190 |
2001 |
33 |
0 |
0 |
0 |
0 |
6 |
27.9 |
32.7 |
491977 |
23rd |
hensley racing |
190 |
2002 |
24 |
0 |
0 |
0 |
1 |
11 |
27.0 |
33.0 |
288325 |
29th |
hensley racing |
190 |
2003 |
5 |
0 |
0 |
0 |
0 |
4 |
35.8 |
25.6 |
68360 |
85th |
jay robinson racing |
190 |
2004 |
9 |
0 |
0 |
0 |
0 |
6 |
31.4 |
37.2 |
139685 |
54th |
moy racing / jay robinson racing |
190 |
2005 |
7 |
0 |
0 |
0 |
0 |
7 |
40.9 |
32.6 |
108921 |
83rd |
jay robinson racing |
190 |
2006 |
9 |
0 |
0 |
0 |
0 |
7 |
38.9 |
39.1 |
151184 |
70th |
jay robinson racing |
190 |
2008 |
1 |
0 |
0 |
0 |
0 |
1 |
43.0 |
34.0 |
15674 |
149th |
jay robinson racing |
190 |
Step 4: Use a `CASE` statement to return TRUE if the number of rows is equal to 1, otherwise return FALSE.
year |
races |
wins |
poles |
top_5 |
top_10 |
dnf |
finish |
start |
winnings |
season_rank |
team__s_ |
total_races |
1995 |
2 |
0 |
0 |
0 |
0 |
0 |
24.0 |
37.0 |
5225 |
75th |
stegell motorsports |
190 |
1996 |
14 |
0 |
0 |
0 |
0 |
6 |
26.4 |
25.1 |
63865 |
42nd |
stegell motorsports |
190 |
1997 |
28 |
0 |
1 |
0 |
1 |
10 |
27.1 |
21.6 |
196656 |
23rd |
stegell motorsports |
190 |
1998 |
31 |
0 |
1 |
0 |
3 |
5 |
24.9 |
25.5 |
335163 |
19th |
stegell motorsports |
190 |
1999 |
25 |
0 |
0 |
1 |
1 |
9 |
25.8 |
18.2 |
243810 |
24th |
curb - agajanian performance group |
190 |
2000 |
2 |
0 |
0 |
0 |
0 |
1 |
35.0 |
28.5 |
15900 |
90th |
alumni motorsports |
190 |
2001 |
33 |
0 |
0 |
0 |
0 |
6 |
27.9 |
32.7 |
491977 |
23rd |
hensley racing |
190 |
2002 |
24 |
0 |
0 |
0 |
1 |
11 |
27.0 |
33.0 |
288325 |
29th |
hensley racing |
190 |
2003 |
5 |
0 |
0 |
0 |
0 |
4 |
35.8 |
25.6 |
68360 |
85th |
jay robinson racing |
190 |
2004 |
9 |
0 |
0 |
0 |
0 |
6 |
31.4 |
37.2 |
139685 |
54th |
moy racing / jay robinson racing |
190 |
2005 |
7 |
0 |
0 |
0 |
0 |
7 |
40.9 |
32.6 |
108921 |
83rd |
jay robinson racing |
190 |
2006 |
9 |
0 |
0 |
0 |
0 |
7 |
38.9 |
39.1 |
151184 |
70th |
jay robinson racing |
190 |
2008 |
1 |
0 |
0 |
0 |
0 |
1 |
43.0 |
34.0 |
15674 |
149th |
jay robinson racing |
190 |
verification_result |
FALSE |