Netezza / PureData – How to Substring on a Character

  I had a reason this week to perform a substring on a character in Netezza this week, something I have not had a need to do before.  The process was not as straightforward as I would have thought, since the command is explained as a static position command, and the IBM documentation, honestly, wasn’t … Continue reading Netezza / PureData – How to Substring on a Character

Oracle TO_CHAR to SQL Server CONVERT Equivalents to change Date to String

Transact SQL (T-SQL) When it comes to SQL I tend to lean on the SQL I have used the most over the years, which is Oracle.  Today was no exception, I found myself trying to use the TO_CHAR command in SQL Server to format a date, which of course does not work. So, after a … Continue reading Oracle TO_CHAR to SQL Server CONVERT Equivalents to change Date to String

SQL server table Describe (DESC) equivalent

Transact SQL (T-SQL) Microsoft SQL Server doesn’t seem have a describe command and usually, folks seem to want to build a stored procedure to get the describe behaviors.  However, this is not always practical based on your permissions. So, the simple SQL below will provide describe like information in a pinch.  You may want to … Continue reading SQL server table Describe (DESC) equivalent

Microsoft SQL Server – Useful links

Microsoft SQL Server 2017 Here are a few references for the Microsoft SQL Server 2017 database, which may be helpful. Table Of Useful Microsoft SQL Server Database References Reference Type Link SQL Server 2017 Download Page https://www.microsoft.com/en-us/sql-server/sql-server-downloads SQL SERVER version, edition, and update level https://support.microsoft.com/en-us/help/321185/how-to-determine-the-version--edition-and-update-level-of-sql-server-a SQL Server 2017 Release Notes https://docs.microsoft.com/en-us/sql/sql-server/sql-server-2017-release-notes SQL Server Transact SQL Commands … Continue reading Microsoft SQL Server – Useful links

Netezza / PureData – How To Get A List Of When A Store Procedure Was Last Changed Or Created

In the continuing journey to track down impacted objects and to determine when the code in a database was last changed or added, here is another quick SQL, which can be used in Aginity Workbench for Netezza to retrieve a list of when Store Procedures were last updated or were created. SQL List of When A Stored Procedure was … Continue reading Netezza / PureData – How To Get A List Of When A Store Procedure Was Last Changed Or Created

Netezza / PureData – How To Get a SQL List of When View Was Last Changed or Created

Sometimes it is handy to be able to get a quick list of when a view was changed last.  It could be for any number of reason, but sometimes folks just lose track of when a view was last updated or even need to verify that it hadn't been changed recently.  So here is a quick … Continue reading Netezza / PureData – How To Get a SQL List of When View Was Last Changed or Created

Netezza / PureData – How To Quote a Single Quote in Netezza SQL

How To Quote a Single Quote in Netezza SQL? The short answer is to use four single quotes (''''), which will result in a single quote within the select statement results. How to Assemble the SQL to Quote a Single Quote in a SQL Select Statement Knowing how to construct a list to embed in … Continue reading Netezza / PureData – How To Quote a Single Quote in Netezza SQL