palinkas-jo-reggelt / hMailServer-Firewall-Ban

Windows Defender Firewall Ban for hMailServer
GNU General Public License v3.0
10 stars 2 forks source link

MSSQL Fixes #6

Closed lcamilo closed 4 years ago

palinkas-jo-reggelt commented 4 years ago

I have a question about this:

($( DBFormatDate (DBCastDateTimeFieldAsDate 'timestamp') '%c') $(If ($DatabaseType -eq 'MYSQL'){Write "- 1"})) AS month,

The reason I subtract 1 from the month is because JavaScript month format is 0-11, so its necessary for the charts. Were you aware of that? I left it alone because I thought maybe SQL server does something automatically, but after thinking about it, I figure you may not be aware of the reason its there.

lcamilo commented 4 years ago

The reason I subtract 1 from the month is because JavaScript month format is 0-11, so its necessary for the charts. Were you aware of that? I left it alone because I thought maybe SQL server does something automatically, but after thinking about it, I figure you may not be aware of the reason its there.

I have a question about this:

($( DBFormatDate (DBCastDateTimeFieldAsDate 'timestamp') '%c') $(If ($DatabaseType -eq 'MYSQL'){Write "- 1"})) AS month,

The reason I subtract 1 from the month is because JavaScript month format is 0-11, so its necessary for the charts. Were you aware of that? I left it alone because I thought maybe SQL server does something automatically, but after thinking about it, I figure you may not be aware of the reason its there.

Ow.. I know about javascript, but I thought this was some adjustment because of MySql. Sorry, as I don't use MySql, I thought it was a fix because of it.

That way, I'll check if we need to make an adjustment in MSSQL, because of data types (string varchar plus an int).

palinkas-jo-reggelt commented 4 years ago

The reason I subtract 1 from the month is because JavaScript month format is 0-11, so its necessary for the charts. Were you aware of that? I left it alone because I thought maybe SQL server does something automatically, but after thinking about it, I figure you may not be aware of the reason its there.

I have a question about this: ($( DBFormatDate (DBCastDateTimeFieldAsDate 'timestamp') '%c') $(If ($DatabaseType -eq 'MYSQL'){Write "- 1"})) AS month, The reason I subtract 1 from the month is because JavaScript month format is 0-11, so its necessary for the charts. Were you aware of that? I left it alone because I thought maybe SQL server does something automatically, but after thinking about it, I figure you may not be aware of the reason its there.

Ow.. I know about javascript, but I thought this was some adjustment because of MySql. Sorry, as I don't use MySql, I thought it was a fix because of it.

That way, I'll check if we need to make an adjustment in MSSQL, because of data types (string varchar plus an int).

LOL we both thought the same thing. I didn't say anything before because I though MSSQL handled it automatically.

This -1 only applies to the charts. I'll fix it in the powershell chart updater.