Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Setup PETL with jobs "diagnosis," "services," and "visit" #28
Setup PETL with jobs "diagnosis," "services," and "visit" #28
Changes from 4 commits
986b4c1
10c2d20
ad2d47f
ab62caa
fdd4f68
834258c
56c0f76
5078ea7
f1f40b9
ef74cde
219658e
a66ea16
7f6f3b6
7749080
a357d99
c96a37e
3ebf7b9
8be5ea5
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no? Para la hora despues de medianoche?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tal vez queriras excluyir 00:00 y 23:59, que son horas associadas con encuentros sin hora exacto
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Incluyo las 24 horas para contar todos los encuentros que se hayan hecho, ya que por motivos de red algunas citas puede que no se registren ese mismo día en que se realizo el registro y tenga que hacerlo el siguiente.
No se si eso te parece correcto.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
El calculacion que quieres es para este año del calendario?
En este caso, debes adaptar el numero de dias de trabajo (251) para ser el numero aproximo de estos dias que han pasado, no? Algo como
DATEDIFF(NOW(), YEAR(NOW) + "-1-1") / 365 * 251
?O quieres calcular por los ultimos 365 dias?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Que hace el "-1-1"(puedes explicarlo en ingles para mayor precisión)?
PD: Gracias por el tip, la idea era al principio esa pero no encontré un modo de aplicarla en el momento..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
YEAR(NOW) + "-1-1"
debe producir2021-1-1
, la fecha.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
¿Se supone que arroja un null en lugar de un decimal o un integer ?. Además, ejecutar
YEAR (NOW) +" -1-1 "
, muestra solo el año 2020 en lugar del formato de fecha completo y el año correcto. Quizás sería mejor dejarlo con "2021-01-01" por ahora.¿?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh noooo, SQL es un fracaso. Hace
CONCAT(YEAR(NOW()), '-01-01')
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All done!