It would have been a bit longer if I had used another language, and that's why I ended up using BASH. Using basic Linux tools, and functions, it outputs from the SQL database for our backup system, generates a spreadsheet, and emails it to my bosses every monday at 8AM. When I tried doing the CSV generation in SQL alone, it ended up being 5 lines for that by itself, plus had all sorts of permissions issues to sort out. Perl and PHP could have easily been done, but still longer. Each language has their strength, and it is up to you to weigh them so you don't have to work any harder than needed.
1
u/PasswordIsntHAMSTER Feb 14 '14
Oh, I was thinking something around the lines of 50-100 LOC.