sqlt-diagram command not found

In this troubleshooting guide we learn how to fix sqlt-diagram command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

sqlt-diagram: command not found

or when using sudo you get the following error message

sudo: sqlt-diagram: command not found

Solutions to sqlt-diagram: command not found

How To Fix sqlt-diagram: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu sqlt-diagram is provided by libsql-translator-perl package.

libsql-translator-perl is:

SQL::Translator (also known as SQL Fairy) is a collection of Perl modules for manipulating structured data definitions (mostly database schemas). It can perform tasks like converting between different SQL data definition language (DDL) dialects, visualizations of schemas (pseudo-ER diagrams created with GD or GraphViz), converting non-RDBMS files to SQL schemas (xSV text files, Excel spreadsheets), serializing parsed schemas (via Storable, YAML and XML), creating documentation, and more.

To fix this problem, we can install more using the command below.

sudo apt-get -y install libsql-translator-perl

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install libsql-translator-perl.

sudo apt -y install libsql-translator-perl

Or if you have aptitude installed you can use the following command.

sudo aptitude install libsql-translator-perl

Summary

In this tutorial we learn how to fix sqlt-diagram command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.