Forums on Intune, SCCM, and Windows 11

Welcome to the forums. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your topics and posts, as well as connect with other members through your own private inbox!

PENDING Clearing Required PXE Deployments

  • Thread starter Thread starter RJONA
  • Start date Start date
  • Replies Replies 1
  • Views Views 2K

RJONA

Active Member
Messages
42
Solutions
1
Reaction score
4
Points
8
Hey All,

Well aware that I can Clear Required PXE Deployments from the console itself, But is there a way that I can clear it using a SQL Query?
 
You may try this :-

SQL:
$Computer = "Server1"
$ResourceIDQuery = Get-WmiObject -Namespace "ROOT\SMS\SITE_TRT" -class "SMS_R_System" -Filter "NAME='$Computer'" -ErrorAction STOP
$Array = (,$ResourceIDQuery.ResourceID)
Invoke-WmiMethod -Namespace "ROOT\SMS\SITE_TRT" -class "SMS_Collection" -name ClearLastNBSAdvForMachines -ArgumentList (,$Array)
 
Back
Top