mardi 31 juillet 2018

Function to return if is first or second half of the month

I'm learning SQL, and I'm stuck in a issue... is there a way to create a function that return if is first or second half of the month, given a specific date. For example, if date is 01/07/2018 then 0 cause is first half of the month, or if date is 30/07/2018 then 1 cause is second half of the month

Hope I was clear enough ^^'

Aucun commentaire:

Enregistrer un commentaire