Skip to content

Instantly share code, notes, and snippets.

@nmccready
Last active December 26, 2015 22:39
Show Gist options
  • Save nmccready/7224107 to your computer and use it in GitHub Desktop.
Save nmccready/7224107 to your computer and use it in GitHub Desktop.
Script to take in a row of mysql ids and put put them with quotes and commas. So do a copy row unquotes from MySQL workbench and paste it with this script.
# usage as shown below
# $>ruby concatComa "1 2 3 4 5555555"
# $>"1","2","3","4","5555555"
v1 = ARGV[0]
puts v1.to_s.split.to_s[1..-2]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment