我正在尝试将每个月的所有日子合并为一个日期。选择inventory_items。acquired_at AS Date_Acquired,products。name AS products_name,SUM(inventory_items.primary_quantity) AS inventory_items_primary_quantity FROM inventory_items inventory_items INNER JOIN customers customers ON inventory_items。source_id= customers.id INN
我正在尝试获取ToDate将具有上一个日期而FromDate将具有当前月份的第一个日期的起始日期。对于一月份,它将是1/1/2013,依此类推。如何正确获取当月的第一个日期?我不能做这件事。today.add(Calendar.DAY_OF_MONTH, -1);ToDate = sdfFile1.format(newjava.sql.Date(previousDay.getTime()));
t