Linux Ask!

Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.

Aug 152010

Multi-line string in Ruby


To declare a multi-line string in Ruby, it is as easy as the following.

sql = "
        SELECT *
            FROM `user` AS u
            JOIN `company` AS c
                ON u.cid =
             WHERE = 8

puts sql

 Leave a Reply



You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>