Save information about execution days

Asked

Viewed 26 times

0

Good afternoon, you guys. I have an automation monitoring system that consumes a table that contains information about n automations registered, about 40 currently. I would however like to do a check on the days on which these automations will run. Example: Automation 1 runs only Monday to Friday, Automation 2 runs also on Saturdays and Sundays, etc. Not to make these rules directly in the code was thinking of making a table of days of the week and connects it as foreign key to the table where the automations are. My question is: Is this the best way? How would you make the table? I was thinking about making a table with id and boolean weekdays and then treating that in the source.

1 answer

0


Good morning buddy,

In companies that I’ve worked on both as a developer and other roles, it’s common practice to perform a scale register of equipment work, which in your case we’ll call scale automations, where you define which days of the week that application will run that application or then a scale configuration in general. If your routine changes, you just change this scale to that specific equipment or just change the overall scale and let the system do the days calculation. In addition Voce can create a holiday registration if use as resesso, so that it calculates non-automatization these days too.

Any doubt I’m available!

  • how is this scale register? is an id | mon | tue | wed | thu | fri | Sab and there you leave marks the days? is done in the same comic?

  • Ai already depends on how you prefer to work and treat the days of the week, but yes, are usually checks that Voce.

  • got it, all right, thank you ;)

Browser other questions tagged

You are not signed in. Login or sign up in order to post.