Download SQL Patch Info

  • Nice job, Theo, it seems a timesaving activity, so I'm trying it out on a development machine.

    For the moment I'd only suggest to modify the CreateServerInfoDbAndTables.sql file, inserting a USE [ServerInfo] statement just before creating the tables, or you'll end up messing with the master database.

  • Alberto Turelli - Monday, July 3, 2017 2:05 AM

    Nice job, Theo, it seems a timesaving activity, so I'm trying it out on a development machine.

    For the moment I'd only suggest to modify the CreateServerInfoDbAndTables.sql file, inserting a USE [ServerInfo] statement just before creating the tables, or you'll end up messing with the master database.

    Good point. Adding it now 🙂

  • Nice job Theo;
    I had created a procedure to check the current patch version,all available patch version, and the suggested Service pack version, but it used an internally contained CTE full of static values from the last time I downloaded and formatted that information.
    If I can twist my proc around to use your table, I'll post it so you can add it to your solution.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • Thanks Lowell 🙂

    I'd like to see what you come up with.

  • Nice project. But I'm not getting anything in the @html variable, the html file is empty. It can reach the site and I've tried another path without spaces with same result and changing the link and still nothing.

  • christoffersen366 - Wednesday, July 5, 2017 8:16 AM

    Nice project. But I'm not getting anything in the @html variable, the html file is empty. It can reach the site and I've tried another path without spaces with same result and changing the link and still nothing.

    I had that at first too.  Is your wget set up properly?  you need 3 files for it to work properly: the wget.exe and 2 dll's.

    I have this working in one of our test instances and am now building up a stored procedure that goes out and queries all of the other servers to see what version they are on and then builds up a result to indicate if I am behind or not.
    On the test systems, most of mine are a little bit behind, but not terrible.

    Thanks a bunch for the script!

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • christoffersen366 - Wednesday, July 5, 2017 8:16 AM

    Nice project. But I'm not getting anything in the @html variable, the html file is empty. It can reach the site and I've tried another path without spaces with same result and changing the link and still nothing.

    You could try to execute WGET in a comd windows first to check if that step is working

    Maybe some firewall is blocking you?  🙂

  • I'm thinking of adding a second HTML scraper, and add the SQL EOL date columns.

    Usefull ?  Not Usefull?

    What do you guys think ?

  • Has anyone found the equivalent tool for Windows patches?

    412-977-3526 call/text

  • Theo Ekelmans - Thursday, July 6, 2017 4:55 AM

    I'm thinking of adding a second HTML scraper, and add the SQL EOL date columns.

    Usefull ?  Not Usefull?

    What do you guys think ?

    robert.sterbal 56890 - Thursday, July 6, 2017 12:39 PM

    Has anyone found the equivalent tool for Windows patches?

    Theo - that sounds useful to me 🙂
    Robert - There are tools out there that will do this for you.  Where I work, we have a tool called "Desktop Central" that will allow you to look at and install patches on windows machines.  It is not a free tool, but I imagine you could build something using Powershell and WMI.

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • bmg002 - Wednesday, July 5, 2017 11:08 AM

    christoffersen366 - Wednesday, July 5, 2017 8:16 AM

    Nice project. But I'm not getting anything in the @html variable, the html file is empty. It can reach the site and I've tried another path without spaces with same result and changing the link and still nothing.

    I had that at first too.  Is your wget set up properly?  you need 3 files for it to work properly: the wget.exe and 2 dll's.

    I have this working in one of our test instances and am now building up a stored procedure that goes out and queries all of the other servers to see what version they are on and then builds up a result to indicate if I am behind or not.
    On the test systems, most of mine are a little bit behind, but not terrible.

    Thanks a bunch for the script!

    Just got it without those files, I didn't want to challenge my firewall, it's very strict.

    Theo Ekelmans - Thursday, July 6, 2017 4:53 AM

    christoffersen366 - Wednesday, July 5, 2017 8:16 AM

    Nice project. But I'm not getting anything in the @html variable, the html file is empty. It can reach the site and I've tried another path without spaces with same result and changing the link and still nothing.

    You could try to execute WGET in a comd windows first to check if that step is working

    Maybe some firewall is blocking you?  🙂

    Thanks. While typing it in I realized the file I downloaded was called wget64.exe while the name in the script is just wget.exe 🙂
    Now it gets the data from the site, but when putting it into the tblBuildListImport, it either gives me an error because it isn't there or because it is, and doesn't seem to go any further, the table is empty.
    But I just got past the former issue so I might find out in a bit.

  • Got it to work after rewriting the line that drops the import table if its ID is null, to dropping it if it exists. Select into can't work if it's there, and Insert into instead would be more work since there's an ID column.
    This could result in it deleting the table and remaking it with nothing, if it runs without net access for example, so @out should be checked too.
    Again, great work.

  • christoffersen366 - Friday, July 7, 2017 5:03 AM

    Got it to work after rewriting the line that drops the import table if its ID is null, to dropping it if it exists. Select into can't work if it's there, and Insert into instead would be more work since there's an ID column.
    This could result in it deleting the table and remaking it with nothing, if it runs without net access for example, so @out should be checked too.
    Again, great work.

    Thanks for the feedback 🙂

  • bmg002 - Thursday, July 6, 2017 12:53 PM

    Theo Ekelmans - Thursday, July 6, 2017 4:55 AM

    I'm thinking of adding a second HTML scraper, and add the SQL EOL date columns.

    Usefull ?  Not Usefull?

    What do you guys think ?

    robert.sterbal 56890 - Thursday, July 6, 2017 12:39 PM

    Has anyone found the equivalent tool for Windows patches?

    Theo - that sounds useful to me 🙂
    Robert - There are tools out there that will do this for you.  Where I work, we have a tool called "Desktop Central" that will allow you to look at and install patches on windows machines.  It is not a free tool, but I imagine you could build something using Powershell and WMI.

    I'm looking for a list of patches by OS. Once I have the source I'll be able to process it, but I'm finding it hard to find a source.

    412-977-3526 call/text

  • robert.sterbal 56890 - Friday, July 7, 2017 6:10 AM

    bmg002 - Thursday, July 6, 2017 12:53 PM

    Theo Ekelmans - Thursday, July 6, 2017 4:55 AM

    I'm thinking of adding a second HTML scraper, and add the SQL EOL date columns.

    Usefull ?  Not Usefull?

    What do you guys think ?

    robert.sterbal 56890 - Thursday, July 6, 2017 12:39 PM

    Has anyone found the equivalent tool for Windows patches?

    Theo - that sounds useful to me 🙂
    Robert - There are tools out there that will do this for you.  Where I work, we have a tool called "Desktop Central" that will allow you to look at and install patches on windows machines.  It is not a free tool, but I imagine you could build something using Powershell and WMI.

    I'm looking for a list of patches by OS. Once I have the source I'll be able to process it, but I'm finding it hard to find a source.

    That is a good point.  I do not know of a good source online.  Plus it may be a tad tricky to keep that list up to date.
    With SQL patches, it is SP and CU updates that you care about.  With an OS, they are usually broken up into multiple KB's and not a CU.  So whomever maintains that list would be a very lengthy list and be rather painful to keep up to date.  Especially with all the different OS versions.  Keeping the list updated based on SP would be easy, but with MS releasing multiple KB's per month and different ones for x86 vs x64, I imagine that list to be GIANT.

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

Viewing 15 posts - 1 through 15 (of 74 total)

You must be logged in to reply to this topic. Login to reply