Skip to content

Instantly share code, notes, and snippets.

@MadaraUchiha
Created April 29, 2012 21:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MadaraUchiha/2553439 to your computer and use it in GitHub Desktop.
Save MadaraUchiha/2553439 to your computer and use it in GitHub Desktop.
heredoc demonstration
<?php
$sql = <<<SQL
SELECT DISTINCT timeBlocks.date
FROM timeBlocks
WHERE timeBlocks.location = '{$appointmentLocation}'
AND timeBlocks.school = '{$_SESSION["school"]}'
AND timeBlocks.date >= DATE_ADD(curdate(), INTERVAL 1 DAY)
ORDER BY timeBlocks.date ASC;
SQL;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment