[racktables-users] Re: Another Report Question

That's all the code i have. I run it in a mysql query browser. There is no php wrapper if that's what you're asking for.



On 3 feb 2009, at 18:52 , Paul Seymour wrote:

Do you mind copy/pasting the code?

Paul Seymour
Datacenter Operations
Lore Systems
pseymour@xxxxxxxx
Office – 703-542-2200 x141
Cell – 703-231-1086
P Lore Systems is an industry leader in Green IT & Datacenters.
Please consider the environment before printing this email.

From: racktables-users-bounce@xxxxxxxxxxxxx [mailto:racktables-users-bounce@xxxxxxxxxxxxx ] On Behalf Of Rob Buijs
Sent: Tuesday, February 03, 2009 12:45 PM
To: racktables-users@xxxxxxxxxxxxx
Subject: [racktables-users] Re: Another Report Question

This is what i use for a list of all rackobjects and most of it's objects:

select distinct R.name
, RO.name
, RO.label
, A.attr_name
, CASE A.attr_type
 when "string" then AV.string_value
 when "dict" then D.dict_value
 when "float" then AV.float_value
 else "Stuk"
end Value
from RackObject RO join AttributeValue AV on RO.id = AV.object_id
join Attribute A on A.attr_id = AV.attr_id
left join RackSpace RS on RO.id = RS.object_id
left join Rack R on R.id = RS.rack_id
left join Dictionary D on AV.uint_value = D.dict_key
where A.attr_name not like 'Nagios%'
order by R.name, RO.name, A.attr_name


On 3 feb 2009, at 18:39 , Paul Seymour wrote:


Searching through the archives I found some information on custom reports. Here’s the URL specifically:

http://www.freelists.org/post/racktables-users/Feature-Request,4

Because I am no good at SQL queries, I was wondering if there was any way to get a list of ALL objects (not just servers) and their ports and labels. I really don’t need the asset tags, barcodes, or has_problems. Can anybody give me a helping hand?

Paul Seymour
Datacenter Operations
Lore Systems
pseymour@xxxxxxxx
Office – 703-542-2200 x141
Cell – 703-231-1086
P Lore Systems is an industry leader in Green IT & Datacenters.
Please consider the environment before printing this email.



Other related posts: