Skip to content

Instantly share code, notes, and snippets.

@JohnMGant
Last active August 1, 2019 20:12
Show Gist options
  • Select an option

  • Save JohnMGant/11129c244a28f9cc2992375384e97e14 to your computer and use it in GitHub Desktop.

Select an option

Save JohnMGant/11129c244a28f9cc2992375384e97e14 to your computer and use it in GitHub Desktop.
SQL for ORM Examples
select Id, FirstName + ' ' + LastName as Name, coalesce(FavoriteColor, 'Green') as FavoriteColor
from Employees
where LastName like '[whatever you passed in]%'
order by LastName, FirstName
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment