/build/static/layout/Breadcrumb_cap_w.png

Is there a method to create a union of two smart labels?

I am patching the machines in our organization.  I have found that some of my users prefer that there be a KACE pop-up advising them to reboot during patches (install during the day, and notify at time of completion of reboot.)  Other users prefer that I delay the patching until the overnight hours and forcefully reboot their systems no matter what.

I have a list of users who want either option, but now I'd like to do a union between the departmental list of what-machines-get-what-patch with the list of who-likes-what-kind-of-updates.  Is it possible to reference one smart label from the sql of another smart label?


0 Comments   [ + ] Show comments

Answers (2)

Answer Summary:
Posted by: dugullett 10 years ago
Red Belt
2

Sorry for the new answer. It's easier to read these SQL queries, and to know where you need to edit. If I'm understanding your question correctly this should work.

 

Edit the label name and machine name fields. My answer on this post may also help with the manual label part. 

http://www.itninja.com/question/add-machines-to-manual-label-in-bulk

 

select MACHINE.*, C.CLIENT_CONNECTED, UNIX_TIMESTAMP(now()) - UNIX_TIMESTAMP(LAST_SYNC) as LAST_SYNC_TIME,

UNIX_TIMESTAMP(LAST_SYNC) as LAST_SYNC_SECONDS

from ORG1.MACHINE

LEFT JOIN KBSYS.KUID_ORGANIZATION O ON O.KUID=MACHINE.KUID LEFT JOIN KBSYS.SMMP_CONNECTION C ON C.KUID = MACHINE.KUID AND O.ORGANIZATION_ID = 1

where (((  (1  in (select 1 from ORG1.LABEL, ORG1.MACHINE_LABEL_JT where MACHINE.ID = MACHINE_LABEL_JT.MACHINE_ID

and MACHINE_LABEL_JT.LABEL_ID = LABEL.ID and LABEL.TYPE != 'hidden' and LABEL.NAME = '<LABEL NAME>'))

and (  MACHINE.NAME IN ('<MACHINE_1>','<MACHINE_2>', '<MACHINE_3>')))))
Posted by: dugullett 10 years ago
Red Belt
0

If you created a label off of the logged in user I would think that would change frequently depending on what machine that user logged into. So say a user who wanted a pop-up logged into a machine that didn't want the pop-up for whatever reason. That machine would then have that other label.

Have you thought about doing a manual label, or LDAP label? Do you have a list of the machine names, or just the users?


Comments:
  • I definitely did not make it clear in the post, however I'm willing and able to figure out what the machine names are for the users in question. So, given I have a manual label of x machines, can I union it with a smart label? The union is the important part. I'm figuring I'll have to go pure sql if there's no method of doing it in the interface, but it just feels kludgey to have to do that. - petergrace 10 years ago

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ