Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
7714 Widoki

On v7, group by date (anywhere), groups results by month and not the day. I understand that there is a workaround to add date to char column and group by that field.

The thing is that i defensively don't want to go through 9-10 modules i have inline and fix them.

is there any other solution?

Awatar
Odrzuć

The problem is your date will be of string type. Please check its type. You have to convert it into datetime and then check. You will get the result

Najlepsza odpowiedź

This is a confirmed bug and you will have execute a sql command manually.

cr.execute('SELECT call_date, COUNT(*) AS num_calls FROM bitco_voice_daily_summary GROUP BY call_date;')
results = cr.fetchall()
for result in results:
    p 'There were ' + str(result[1]) + ' calls made on '+ str(result[0])

Be careful of sql injection if you're building a query with parameters.

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
3
cze 25
1192
1
sty 25
18028
0
maj 24
1766
1
lip 21
2747
1
sty 20
3995