Hi,
I'm a bit desperate. I have this query :
that was working fine with SQL 7. I upgraded my server to SQL 2000 and now I get this annoying error: Microsoft OLE DB Provider for SQL Server error '80040e07'
The conversion of char data type to smalldatetime data type resulted in an out-of-range smalldatetime value.
I'm having problems with this HAVING (((GPM_E_ABS.DATE_ABS)='" & date() & "')
I tried using CAST or CONVERT but could not make it work. I red a lot of post about this error but I can't figure out the syntax.
Can someone help me?
Thanks
I'm a bit desperate. I have this query :
Code:
SELECT GPM_E_ABS.FICHE " &_
"FROM ((GPM_E_DAN INNER JOIN (GPM_E_ABS INNER JOIN GPM_T_ECO ON GPM_E_ABS.ID_ECO = GPM_T_ECO.ID_ECO) ON (GPM_E_DAN.ID_ECO = GPM_T_ECO.ID_ECO) " &_
"AND (GPM_E_DAN.FICHE = GPM_E_ABS.FICHE) AND (GPM_E_DAN.ORG = GPM_T_ECO.ORG)) INNER JOIN GPM_E_ELE ON GPM_E_DAN.FICHE = GPM_E_ELE.FICHE) " &_
"INNER JOIN GPM_T_MOTIF_ABS ON (GPM_E_ABS.MOTIF_ABS = GPM_T_MOTIF_ABS.MOTIF_ABS) AND (GPM_T_ECO.ID_ECO = GPM_T_MOTIF_ABS.ID_ECO) " &_
"GROUP BY GPM_E_ABS.FICHE, GPM_E_ABS.DATE_ABS, GPM_T_ECO.ECO, GPM_T_ECO.ANNEE, GPM_E_ELE.NOM, GPM_E_DAN.CLASSE, GPM_T_MOTIF_ABS.DESCR " &_
"HAVING (((GPM_E_ABS.DATE_ABS)='" & date() & "') AND
((GPM_T_ECO.ECO)='" & schoolNum & "') AND ((GPM_T_ECO.ANNEE)=" & schoolYear() & ")) " &_
"ORDER BY GPM_E_ELE.NOM;"
that was working fine with SQL 7. I upgraded my server to SQL 2000 and now I get this annoying error: Microsoft OLE DB Provider for SQL Server error '80040e07'
The conversion of char data type to smalldatetime data type resulted in an out-of-range smalldatetime value.
I'm having problems with this HAVING (((GPM_E_ABS.DATE_ABS)='" & date() & "')
I tried using CAST or CONVERT but could not make it work. I red a lot of post about this error but I can't figure out the syntax.
Can someone help me?
Thanks