How to Add AM/PM to a Time or Datetime Value in MariaDB

MariaDB includes many functions that allow you to return time and datetime values in a variety of formats.

Two functions allow you to format the time portion using a 12 hour clock, with the AM/PM designator are DATE_FORMAT() and TIME_FORMAT().

There are many format specifiers that can be used with these functions, but only a couple that return the AM/PM designator.

Continue reading

Get the Language Currently Being Used in SQL Server

There are several ways to get the language currently being used in SQL Server.

The language of the current session will often be the default language for the login, but this is not necessarily always the case. A user can change the current language during the session.

Also, some of SQL Server’s built-in functions accept an argument that allows you to specify a language for that specific query.

This article shows you how to return the language currently being used.

Continue reading