To make sqlcmd/bcp accessible from the bash shell for interactive/non-login sessions, modify the PATH in the ~/.bashrc file with the following command:
Unfortunately, Microsoft does not officially support this OS at the moment.
We track supported platforms at https://docs.microsoft.com/en-us/sql/linux/sql-server-linux-setup?view=sql-server-ver15#supportedplatforms
2. Creating SQL Server User and Database
2.1. Run sqlcmd and enter your root password (change <YourSAPassword> with your real password)
sqlcmd -S localhost -U SA -P '<YourSAPassword>'
2.2. The following lines create a database hesdb, the user with name hesuser and password <user_password>. Сhange <user_password> to a strong password, otherwise you may get a password validator error.
> CREATE LOGIN [hesuser] WITH PASSWORD = '<user_password>';
> GO
> CREATE DATABASE hesdb;
> GO
> USE hesdb;
> GO
> CREATE USER [hesuser] from login [hesuser];
> GO
> GRANT CONTROL ON DATABASE::hesdb TO [hesuser];
> GO
To exit from the Transact-SQL console, press Ctrl+C.