Character Set Mysql Datenbank ermitteln

Wie finde ich heraus, ob die Character Set Einstellung von client bis Datenbank passen?

Zunächst, die Einstellung der Datenbank Instanz prüfen:

SELECT @@global.character_set_database;

Wichtig zu wissen: Die Default Einstellung kann zur Laufzeit, in der Verbindungskonfiguration oder während der Session, überschrieben werden! Daher dringend alle Einflüsse prüfen!

Einstellung des Client prüfen:

SELECT @@global.character_set_client

Einstellung der Verbindung / Session prüfen:

 SELECT @@global.character_set_connection;

Einstellung der Datenbank prüfen

SELECT * FROM information_schema.SCHEMATA WHERE schema_name like '<datenbankname>';




+--------------+--------------+----------------------------+------------------------+----------+
| CATALOG_NAME | SCHEMA_NAME  | DEFAULT_CHARACTER_SET_NAME | DEFAULT_COLLATION_NAME | SQL_PATH |
+--------------+--------------+----------------------------+------------------------+----------+
| def          | datenbankname| utf8                       | utf8_unicode_ci        | NULL     |

How to execute a script on 2. last Workday of month only?

A few days i had to answer this question.

How to execute a script on 2. last Workday of month only?

With workdays, regular business days was meant.

So, i will explain the way to solve this requirement.
For some statistic jobs it may neccessary to start a script a business day eayrlier than last day of a month.
The first answer is how to get out if today is the last day of month.

  • We want to keep it simple
  • Find a general rule

„How to execute a script on 2. last Workday of month only?“ weiterlesen