Created
October 3, 2014 23:13
-
-
Save camsaul/8cd3144edf07657f4fcf to your computer and use it in GitHub Desktop.
Perl replace one-liner
This file contains hidden or 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
TABLE="DROP TABLE public.timeseries_metriccomment;" | |
echo $TABLE | perl -ne 's/(^DROP TABLE.*);/$1 CASCADE;/, print' | |
# -> DROP TABLE public.timeseries_metriccomment CASCADE; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment