RE: Hardware report with Prompt
- From: Dan <Dan@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 30 Jun 2005 05:26:04 -0700
Dale,
Nice report, I'm going to use this one!
Dan
"Dale" wrote:
> This report requires a prompts.
>
> Report Name: Computers by a specific Model
>
> Select SYS.Netbios_Name0 as 'Machine Name',
> PCB.SerialNumber0 as 'Serial No',
> SYS.User_Name0 As 'User',
> SYS.AD_Site_Name0 AS Site,
> OPSYS.Caption0 AS 'Operating System',
> OPSYS.CSDVersion0 AS 'Serv Pack',
> SYST.Model0 as Model,
> 'Chassis Type' =
> Case
> SYSE.ChassisTypes0
> when '1' then 'Other'
> when '2' then 'Unknown'
> when '3' then 'Desktop'
> when '4' then 'Low Profile Desktop'
> when '5' then 'Pizza Box'
> when '6' then 'Mini Tower'
> when '7' then 'Tower'
> when '8' then 'Portable'
> when '9' then 'Docking Station'
> when '10' then 'Notebook'
> when '11' then 'Hand Held'
> when '12' then 'Laptop'
> when '13' then 'All in One'
> when '14' then 'Sub Notebook'
> when '15' then 'Space-Saving'
> when '16' then 'Lunch Box'
> when '17' then 'Main System Chassis'
> when '18' then 'Expansion Chassis'
> when '19' then 'SubChassis'
> when '20' then 'Bus Expansion Chassis'
> when '21' then 'Peripheral Chassis'
> when '22' then 'Storage Chassis'
> when '23' then 'Rack Mount Chassis'
> when '24' then 'Sealed-Case PC'
> else 'Undefinded'
> end
> from v_R_System SYS
> Left JOIN v_GS_SYSTEM_ENCLOSURE SYSE ON SYS.ResourceID = SYSE.ResourceID
> Left Join v_GS_OPERATING_SYSTEM OPSYS on SYS.ResourceID = OPSYS.ResourceID
> left join v_GS_COMPUTER_SYSTEM SYST ON SYS.ResourceID=SYST.ResourceID
> left join v_GS_PC_BIOS PCB on SYS.ResourceID=PCB.ResourceID
> where
> (SYST.Model0 like @mt And @mt<> '') Or
> (SYST.Model0 Is NULL and (@mt Is NULL or Upper(@mt) like '' Or Upper(@mt)
> like 'NULL'))
> order by SYS.Netbios_Name0
> ---------------
> Prompt
>
> Name: mt
> Prompt text: Model Type
>
> Sql statment for prompt:
>
> begin
> if (@__filterwildcard = '')
> select distinct Model0 as Model from v_GS_COMPUTER_SYSTEM order by Model0
> else
> select distinct Model0 as Model from v_GS_COMPUTER_SYSTEM
> WHERE Model0 like @__filterwildcard
> order by Model0
> end
> ---------------------------
>
> Dale
> --
> (if you like the post please rate it)
>
>
> "Danny M" wrote:
>
> > Don't worry about this...I've come up with another way around this through
> > the queries.. I made a query and got the details I wanted...I'll now just
> > copy that across to the reporting section...I'll just follow this procedure
> > until I become acustomed to the language (that's right, I'm new to SQL
> > querying language).
> >
> > cheers
> > --
> > D
> >
> >
> > "Danny M" wrote:
> >
> > > I'm trying to generate a report that will list the all the computers of a
> > > particular model I'm after from the databases. I've referenced a couple of
> > > the queries other people have posted which has been a great help, but any
> > > more help would be much appreciated...
> > > --
> > > D
.
- References:
- Hardware report with Prompt
- From: Danny M
- RE: Hardware report with Prompt
- From: Danny M
- RE: Hardware report with Prompt
- From: Dale
- Hardware report with Prompt
- Prev by Date: RE: SMS 2003 - Problem with SQL Tables created by MOF classes.
- Next by Date: Multiple Processors on Servers
- Previous by thread: RE: Hardware report with Prompt
- Next by thread: Printer inventory
- Index(es):
Relevant Pages
|