SQL Query "Year-Month"

Hi team!

I have a question.
In a table a have a column with datetime.

I wanna make a Query from this Column and to get this:

Example: 2015-03-20 14:44:47 and I want to get this: 2015-03-20.
2015-03-19 14:44:50
2015-03-29 20:44:47

For Get a common data I know that I need to use DISTINCT(field), where field is the name of date column.
If I use MONTH or Year It filters me Month or Year, example With month, when theres an item of “May” it displays “3”

sqlFecha = “SELECT MONTH(Comprobante_Fecha) FROM facturas_recibidas WHERE Receptor_RFC = '”+ RFC +"’"

I don’t know if theres a way to get date in this format: YEAR-MONTH, or 2015-03.

Thanks

depends on what SQL Engine… but for Oracle

SELECT trunc(datefield,'MONTH') as newdate

[quote=196086:@Dave S]depends on what SQL Engine… but for Oracle

SELECT trunc(datefield,'MONTH') as newdate [/quote]
And if I using MySQL?

Have a look at http://dev.mysql.com/doc/refman/5.7/en/date-and-time-functions.html#function_date-format

Yeah I Use this, reading the manual:
sqlFecha = “SELECT DISTINCT date_format(Comprobante_Fecha, ‘%Y/%m’) FROM facturas_recibidas WHERE Receptor_RFC = '”+ RFC +"’"

Date format - to format the selected date, and DISTINCT to choose only one from several items with the same type