This may be a question that boils down to my not being a coder and thus not getting the ramifications of what I'm doing.
Anyway, I have this query that I'm running in SWQL Studio which is:
SELECT CP.Client, N.Caption, N.IPAddress,
CP.Client_Site, CPS.Status AS SerialNumber,
N.NodeDescription AS Manufacturer, CPA.CustomPollerName,
N.Vendor, N.MachineType, N.IOSVersion, CP.Maintenance_Provider,
CP.Dataroom_Rack, N.Description, N.LastBoot, N.Location, N.Contact,
CP.Circuit_Reference_1, CP.Circuit_Reference_2
FROM Orion.NPM.CustomPollerStatusOnNode AS CPS
JOIN Orion.Nodes N ON CPS.NodeID = N.NodeID
JOIN Orion.NodesCustomProperties CP ON CPS.NodeID = CP.NodeID
JOIN Orion.NPM.CustomPollerAssignmentOnNode CPA ON CPA.NodeID = CP.NodeID
WHERE CP.Client LIKE 'xxxxx%'
-- ensure only relevant vendors includied
AND N.Vendor LIKE '%HPE%'
And it runs just fine, giving me 1000's of results.
If I now add a new line to the bottom: of:
- AND N.Vendor LIKE '%H3C%'
The query runs but gives me 0 rows. If I subsequently reverse the vendors so that it only searches for H3C, it again works. So it's an either/or not both result. The thing is, I have used multiple AND's in my approach before - for example I have another query where I'm excluding vendors I don't want and it runs to 18 AND's on the Vendor field and works just fine (though if I try to add another query it too silently fails with 0 rows)
Is this something to do with my multiple JOINs overloading the DB in some manner, or have I hit some sort of weird bug?