Created
February 23, 2018 20:09
-
-
Save mathiasmag/25837973ea4b910e07b841c12190fa80 to your computer and use it in GitHub Desktop.
sqlcl script to be used in VisualCode for PL/SQL build tasks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Modified to use sqlcl instead of sqlplus | |
# Origin: https://ora-00001.blogspot.se/2017/03/using-vs-code-for-plsql-development.html | |
# https://gist.github.com/mortenbra/9af4b0211782161619c0bab01ed7031a#file-vscode_run_sqlplus-sh | |
# make sure script uses correct environment settings for sqlplus | |
source ~/.profile | |
SQLPATH=$SQLPATH:.;export SQLPATH | |
# run sqlplus, execute the script, then get the error list and exit | |
~/sqlcl/bin/sql $1 << EOF | |
$2 | |
@_show_errors.sql | |
exit; | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment