Oracle SQL: Update table with data from another table

Suppose you have a column in Table1 that you need to update with data from another column in Table2. Let’s do it!

May 11, 2022 · 1 min · 173 words · Vitalie Ciobanu

Power Query – Week start and end dates in same column

Someone asked me the other day below thing: “On the same column I want a Range of dates not Duration between two dates So I have a Creation date and fulfillment date I need to come up with a column of weekly Range like for example 10/21 – 10/27 10/28 – 11/01 11/02 – 11/09…

November 2, 2019 · 3 min · 443 words · Vitalie Ciobanu

Find OS Architecture using Win32_OperatingSystem class

WMI queries to find 64 and 32 bit computers: SELECT * FROM Win32_OperatingSystem WHERE OSArchitecture = “64-bit” SELECT * FROM Win32_OperatingSystem WHERE OSArchitecture = “32-bit”

October 19, 2012 · 1 min · 25 words · Vitalie Ciobanu

Computers without Java 6 Update 30

select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name,SMS_R_SYSTEM.SMSUniqueIdentifier, SMS_R_SYSTEM.ResourceDomainORWorkgroup,SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_ADD_REMOVE_PROGRAMS on SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceID = SMS_R_System.ResourceId where SMS_G_System_ADD_REMOVE_PROGRAMS.Version < “6.0.300” and SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName like “Java(TM) 6%”

October 19, 2012 · 1 min · 21 words · Vitalie Ciobanu

Count Adobe Reader versions

SELECT DISTINCT TOP (100) PERCENT DisplayName0, Version0, COUNT(Version0) AS Total FROM dbo.v_GS_ADD_REMOVE_PROGRAMS GROUP BY DisplayName0, Version0 HAVING (DisplayName0 LIKE ‘%Adobe Reader%’) ORDER BY Total DESC, DisplayName0

October 19, 2012 · 1 min · 26 words · Vitalie Ciobanu

Collections with computers without Forefront Endpoint Protection 2010 client

A customer asked me today to help him with creating some collections with client computers that do not have FEP 2010 installed so he can advertise the antivirus client to those computers. You can find the queries bellow. All Windows 7 without Forefront Endpoint Protection 2010 select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name,SMS_R_SYSTEM.SMSUniqueIdentifier, SMS_R_SYSTEM.ResourceDomainORWorkgroup,SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_COMPUTER_SYSTEM on…

October 19, 2012 · 2 min · 326 words · Vitalie Ciobanu

Report with computer models and manufacturers

SELECT TOP (100) PERCENT Manufacturer0 AS Manufacturer, Model0 AS Model, COUNT(Model0) AS Total FROM dbo.v_GS_COMPUTER_SYSTEM GROUP BY Model0, Manufacturer0 ORDER BY Total DESC, Manufacturer, Model

September 13, 2010 · 1 min · 25 words · Vitalie Ciobanu

Collection with client Computers without ConfigMgr client

select SMS_R_SYSTEM.ResourceID, SMS_R_SYSTEM.ResourceType, SMS_R_SYSTEM.Name, SMS_R_SYSTEM.SMSUniqueIdentifier, SMS_R_SYSTEM.ResourceDomainORWorkgroup, SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_OPERATING_SYSTEM on SMS_G_System_OPERATING_SYSTEM.ResourceId = SMS_R_System.ResourceId where SMS_R_System.Client = 0 and SMS_G_System_OPERATING_SYSTEM.Caption not like “%Server%” or SMS_R_System.Client is null and SMS_G_System_OPERATING_SYSTEM.Caption not like “%Server%”

September 13, 2010 · 1 min · 34 words · Vitalie Ciobanu

Collection based on computer model

select SMS_R_SYSTEM.ResourceID, SMS_R_SYSTEM.ResourceType, SMS_R_SYSTEM.Name, SMS_R_SYSTEM.SMSUniqueIdentifier, SMS_R_SYSTEM.ResourceDomainORWorkgroup, SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_COMPUTER_SYSTEM on SMS_G_System_COMPUTER_SYSTEM.ResourceID = SMS_R_System.ResourceId where SMS_G_System_COMPUTER_SYSTEM.Model like “%HP ProBook 4710s%”

February 14, 2010 · 1 min · 22 words · Vitalie Ciobanu

Upgrade Configuration Manager client

Recently I reinstalled ConfigMgr server in my company and was looking for an easy method to upgrade all Configuration Manager clients to 4.00.6487.2000 version. Put some notes on the table and finally made the following plan: Create a report that counts all client versions. (This is optional, just for informational purposes). Report query is:SELECT TOP…

January 14, 2010 · 2 min · 216 words · Vitalie Ciobanu