R
ragtopcaddy via AccessMonster.com
I have the following Union query set up as a pass through query:
SELECT Host, "Service_Tier" AS Missing FROM dbo.table WHERE service_tier Is
Null AND created In (SELECT Max([created]) FROM dbo.table)
Union SELECT Host, "capacity_type" FROM dbo.table WHERE capacity_type Is Null
AND created In (SELECT Max([created]) FROM dbo.table)
Union SELECT Host, "city" FROM dbo.table WHERE city Is Null AND created In
(SELECT Max([created]) FROM dbo.table) ORDER BY Host;
It returns the following:
Host Missing
sstm0647pap
sstm0648psy
sstm0692por
sstm1468psy
sstm1833psy
sstm1847psy
sstm2924psy
sstm2978por
sstm3478psy
sstm8155por
sstmc106pn1
sstmc106pn2
xstm0663psy
xstm0664psy
xstm1497psy
xstm2328por
xstm2999por
I was expecting a list of hosts, perhaps 3 rows for each, with either
"service_tier", "capacity_type", or "city" in the missing column. Apparently
the query found records satisfying the criteria, but didn't return any values
for Missing.
SELECT Host, "Service_Tier" AS Missing FROM dbo.table WHERE service_tier Is
Null AND created In (SELECT Max([created]) FROM dbo.table)
Union SELECT Host, "capacity_type" FROM dbo.table WHERE capacity_type Is Null
AND created In (SELECT Max([created]) FROM dbo.table)
Union SELECT Host, "city" FROM dbo.table WHERE city Is Null AND created In
(SELECT Max([created]) FROM dbo.table) ORDER BY Host;
It returns the following:
Host Missing
sstm0647pap
sstm0648psy
sstm0692por
sstm1468psy
sstm1833psy
sstm1847psy
sstm2924psy
sstm2978por
sstm3478psy
sstm8155por
sstmc106pn1
sstmc106pn2
xstm0663psy
xstm0664psy
xstm1497psy
xstm2328por
xstm2999por
I was expecting a list of hosts, perhaps 3 rows for each, with either
"service_tier", "capacity_type", or "city" in the missing column. Apparently
the query found records satisfying the criteria, but didn't return any values
for Missing.