New Horizons Get Schooled Blog

Use GETDATE() to pull a Monday-to-Sunday report no matter when it’s created (SQL Server)

Posted on 12/3/18 8:41 AM by Get Schooled in SQL Server, in SQL

In a perfect world, reports would be pulled on the same day and time every week to achieve maximum consistency. Unfortunately, mere mortals cannot maintain this regularity without fail. It only takes one unforeseen circumstance to throw the reports off.

Fortunately, the GETDATE() function replaces human fallibility and pulls a dynamic weekly performance data report starting on any specified day. This provides flexibility to the program and maintains consistency. A real win-win!

To specify the report start date use: WHERE CAST(table.Date as DATE) < CAST(DATEADD(DAYS, -DATEPART(dw, getdate())-1), getdate()) as DATE). If this code is run on a Tuesday, the results will begin on the most recent Monday and so on until Sunday.

0 CommentsContinue Reading →

Web-based app developers in high demand

Posted on 1/31/14 8:04 AM by Get Schooled in IT Career, in IT News, in SQL, in SQL Server, in training, in web design

The world is going increasingly mobile. According to ZDNet contributor Matt Baxter-Reynolds, the mobile Web is dead. Native apps have taken over as the preferred means of Web connection for countless Internet users, and companies that require these apps are taking notice. According to Robert Half Technology's 2014 IT Salary Guide, Web developers will be one of the most in-demand professions of the next new year, and they will need to be trained in development tools like SQL.

0 CommentsContinue Reading →

Determine which named instance you’re connected to

Posted on 1/27/11 3:00 PM by Get Schooled in Instance, in Microsoft, in New Horizons Computer Learning Center, in @@SERVERNAME, in SQL, in SQL Server, in T-SQL, in Tips & Tricks

Programmatically determine which named instance you’re connected to (SQL Server 2000/2005)

0 CommentsContinue Reading →

Which Language? C, C++, SQL?

Posted on 5/11/10 3:28 PM by Get Schooled in Ask The Expert, in C, in Coding, in Java, in PL, in SQL

When performing intense calculations, an obvious language choice is C or C++. However, PL/SQL is a natural choice for logic that interacts heavily with database data. If all you need to do is add or multiply a few large numbers, there's no reason you can't leverage the appropriate algorithms to perform the arithmetic in PL/SQL and still get good performance.

0 CommentsContinue Reading →

Search by Topic

    Lists by Topic

    see all

    Knowledge Ninjas

    a web-based service that allows software application end users to access a subject matter expert in real-time via a chat interface to resolve questions or problems they encounter in their specific software.