Recuerdo que se podía obtener con un API o mediante SQL, o calcularse por programa.
Con API QWCRSVAL (solo para la fecha actual) Con SQL: select dayofweek_ISO(fecha) from archivo Con SQL embebido: Exec SQL Set :DiaSemana = DayOfWeek_ISO(:Fecha); Dsply DiaSemana; Calculado (tenía este ejemplo guardado, no recuerdo si alguna vez lo probé): **************************************************************************** ** Return Day of Week - Use Zeller's congruence* ** Returns an integer with the day number of the year* ** 0 = Monday, 1 = Tuesday 2 = Wednesday, etc. * *************************************************************************** * *P getDayOfWeek B Export * *D getDayOfWeek PI 10i 0 * *D InDate d const datfmt(*iso) * * * * *D nDay s 10i 0 * *D nMonth s 10i 0 * *D nYear s 10i 0 * *D nDayOfWeek s 10i 0 * * * * * /free * * nDay = %subdt(InDate:*days); * * nMonth = %subdt(InDate:*months); * * nYear = %subdt(InDate:*years); * * if nMonth < 3; * * nMonth = nMonth + 12; * * nYear = nYear - 1; * * endif; * * nDayOfWeek = %rem(%int((13 * nMonth + 3) / 5) + nDay + nYear + * * %int(nYear / 4) - %int(nYear / 100) + * * %int(nYear / 400) : 7); * * return nDayOfWeek; * * /end-free * *P getDayOfWeek E * -- Saludos Jesús Olague Zacatecas, México http://jholaguepersonal.blogspot.com 2016-07-19 10:17 GMT-05:00 alberto <[email protected]>: > Hola Foro > Cómo puedo hacer para que en el Qdayofweek me salga el lunes como primer > dia de la semana, y no el domingo como sale por defecto? > Gracias! > ____________________________________________________ > Únete a Recursos AS400, nuestra Comunidad ( http://bit.ly/db68dd ) > Forum.Help400 © Publicaciones Help400, S.L. >
____________________________________________________ Únete a Recursos AS400, nuestra Comunidad ( http://bit.ly/db68dd ) Forum.Help400 © Publicaciones Help400, S.L.

