I've been creating collections under my SCCM Console and successfully have done two queries where the first is based on the computer account object OUs. Then the other generates a collection that contains only laptop devices.

Does anyone know of a query that will generate a collection by only picking out a certain part of a computer name? Per say under an OU there are several computers names as followed; SYS-BSC-2FJ4L5S, SYS-IS-FBQM1NM and SYS-CH-G2BM45S. If I want to start a collection that will only contain computers from the BSC department, is there a way for a query to only pick out all computers that contains SYS-BSC-"%" ? Please advise.

Answer Summary:
Cancel
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Community Chosen Answer

5

this will look for bsc in the name:

SELECT SYSTEM_DESCRIPTION, MACHINE.NAME AS SYSTEM_NAME  FROM MACHINE  WHERE (MACHINE.NAME like '%bsc%')  ORDER BY SYSTEM_DESCRIPTION

this looks for names starting with sys-bsc

SELECT SYSTEM_DESCRIPTION, MACHINE.NAME AS SYSTEM_NAME  FROM MACHINE  WHERE (MACHINE.NAME like 'sys-bsc%')  ORDER BY SYSTEM_NAME

Answered 04/23/2013 by: SMal.tmcc
Red Belt

Please log in to comment

Answers

2

My SQL knowledge is super old, but try something like this in the SQL statement - just clone/edit the one to have working.

Select Computer.Name.Table.Whatever Where Computer.Name is LIKE "SYS%"

I dont know if its single or double quotes, hope you get what I mean. You need to use the LIKE with some wildcards. Hopefully someone else who knows SQL will be able to help.

*told you m sql was bad (;

 

Answered 04/23/2013 by: rileyz
Red Belt

Please log in to comment
0

Dear All
We have using the SCCM 2012. I have some question regarding mentioned below, Its can be possible fix up all the issues without any manual practices.

1- Bad Host Name issues

2-Bad DNS issues

3- VPN user how Can active in the sccm console .

4- VPN user how to fix


Answered 09/13/2016 by: deepak rawat
White Belt

Please log in to comment
0

Thanks everyone! This gave me a good idea on what I need to do.

Answered 04/24/2013 by: TheMessican
Senior Yellow Belt

Please log in to comment
Answer this question or Comment on this question for clarity