Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[suggestion] Powergamers sql column type #499

Closed
luanluciano93 opened this issue Dec 29, 2021 · 2 comments
Closed

[suggestion] Powergamers sql column type #499

luanluciano93 opened this issue Dec 29, 2021 · 2 comments

Comments

@luanluciano93
Copy link
Contributor

luanluciano93 commented Dec 29, 2021

The columns onlinetimetoday, onlinetime1, onlinetime2, onlinetime3, onlinetime4, onlinetime5, onlinetime6, onlinetime7 could not have their type changed to smallint taking into account that their maximum value will be 1440.

ADD `onlinetimetoday` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime1` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime2` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime3` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime4` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime5` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime6` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',
ADD `onlinetime7` MEDIUMINT UNSIGNED NOT NULL DEFAULT '0',

@EPuncker
Copy link
Contributor

the saved value on these columns are in seconds, so a day have 86400 seconds, and smallint can hold only 0 to 65535, that is why we use the next one, that is mediumint and can hold 0 to 16777215

@luanluciano93
Copy link
Contributor Author

Sorry for my stupidity, i confused the globalevents interval and found it to be performed every hour, as it is every minute. Sorry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants