Backup all MySQL Databases of a User

The following script can be used to backup all MySQL-Databases of a user each in it’s own compressed. sql file inside a folder with todays date:

You just need to substitute username, password and backuplocation. If you use the root-MySQL user all databases of the whole MySQL-server are backed up.

Using SSH to copy files between systems

Copy something from this system to some other system:

Copy something from some system to some other system:

Copy something from another system to this system:

Source: Stackoverflow: how-to-download-a-file-from-server-using-ssh

Oracle Log Script Errors

Table to Hold the script errors

Method to call from within the script

Small example how to use it

Backup a DVD

The following command can be used to backup/rip a DVD. All files are decrypted and stored in a folder (with the name of the DVD).

If you want to create an iso file from those decrypted files you can use the following command:

How to properly deprecate methods

If you work with a C# class that has many deprecated methods in they clutter intellisense and you cannot see the useful methods anymore. To avoid this you can add the Annotation EditorBrowsable and disable intellisense:

Find out how wpf is being rendered

WPF applications can render in three modes: everything in software, partial hardware rendering or full hardware rendering. The rendering mode may have a big effect to the application performance. This it is important to know which mode is active:

Converting txt to doc

In order to convert textfiles to word documents you can use the following command

or if you want to convert multiple files:

Get a large corpus of text data

I needed to get a large corpus of text data in order to test some full-text-search functionality. Also the text data should not be in one big file but in many small files instead. This lead me to Project Gutenberg and to Wikipedia.

Here is how you can get lot’s of data (we exclude the zip from gutenberg because they contain just the other files that are downloaded anyway):