I have a table of users
a table of devices
and a report/view of devices and their data (uses a query combining a data table and devices table)
the user table and the devices table both have a field called "security group"
When someone runs the report / view, i would like to set the security group using the devices table field as pulled from the query.
here is an example of the query for the report/view:
SELECT
`Rdata`.`msgid`,
`Rdata`.`time`,
`Rdata`.`from`,
`Rdata`.`to`,
`Rdata`.`subject`,
`Rdata`.`encoding`,
`Rdata`.`body`,
`Rdata`.`status`,
`Rdata`.`lat`,
`Rdata`.`lon`,
`Rdata`.`dlvrdFailedtime`,
`Rdata`.`deviceName`,
`Rdata`.`reason`,
`Rdata`.`hexstring`,
`Rdata`.`speed`,
`Rdata`.`heading`,
`Rdata`.`extvoltage`,
`Rdata`.`battchargetemp`,
`Rdata`.`ambienttemp`,
`Rdata`.`mapit`,
`Rdata`.`confNum`,
`Rdata`.`batteryvoltage`,
`devices`.`securitygroup`,
`devices`.`carNum`,
`devices`.`carType`
FROM
`Rdata`
Left Outer Join `devices` ON `Rdata`.`deviceName` = `devices`.`CharacterName`
you can see that the securitygroup is showing up here...
however, when i go to security screen in php runner... and click on advanced ... use the dropdown to get my report/view... i see only fields from the Rdata table and not from the devices table... so i am unable to select the security group as the Main Table: OwnerID field.
is there a way to get the security group from a query like this?