Lors de l'exécution de [select cdta.id_Classement as sH_IdClassement, case when isnull(state,'')='' then cast(pos_categ as varchar)+'.' else state end as [sR_#RANG] , dossard as [sI_#NR] , case when sexe<>'M' then sexe else '' end as sC_ ,case when isnull(privacy,0)&8192!=0 then 'ANONYMOUS' else isnull(nom,'')+' '+isnull(prenom,'') end as [sB_#NAME] , case when year(naissance)>1900 then cast(2004-year(naissance) as varchar) else '' end as [sC_#AGE] , isnull(nationalite,pays) as [sC_#NAT] , left(club_open,25) as [#OPEN] , tours as [sR_##] , officiel as [sB_t_#OFFICIEL] , case when pos>0 then officiel/(cast(isnull(distance,) as float)/1000.0) else 0 end as [t_#TKM] , case when pos>0 and isnull(officiel,0)>0 then str(cast(isnull(distance,) as float)/cast(officiel as float)*3600.0,6,2) else '' end as [sI_#MOYENNE] , pos as [sIL_#SCRATCH] , points as [sB_#PTS] , ville as [sI_#LOCALITE] from classement_data cdta where isnull(state,'')<>'DNS' and id_Classement=172 and (null is null or idx-1>=null) and (null is null or idx-1<=null) and (null is null or ville like null) and (null is null or club_ligue like null) and (null is null or club_open like null) and ('ASM' is null or categ = 'ASM') and (null is null or (dossard=null) or (isnull(nom,prenom) like null) ) order by idx ]: System.Data.SqlClient.SqlException (0x80131904): Incorrect syntax near ')'. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) at System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) at ChronoRace.Common.Sql.SqlTools.<>c__DisplayClass34_0.b__1() in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\SqlTools.cs:line 579 at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.<>c__DisplayClass1.b__0() at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.ExecuteAction[TResult](Func`1 func) at ChronoRace.Common.Sql.SqlTools.GetDataSet(DbConnectionProvider provider, IDbConnection conn, String qry, DataSet ds) in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\SqlTools.cs:line 572 ClientConnectionId:05bb59dd-bc19-498f-885c-68649bd0c1d7 Error Number:102,State:1,Class:15 ClientConnectionId before routing:7b0878c2-c3b9-408a-b9cb-a3786b665131 Routing Destination:b73e731bcfed.tr645.northeurope1-a.worker.database.windows.net,11000 at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) at System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) at ChronoRace.Common.Sql.SqlTools.<>c__DisplayClass34_0.b__1() in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\SqlTools.cs:line 579 at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.<>c__DisplayClass1.b__0() at Microsoft.Practices.EnterpriseLibrary.TransientFaultHandling.RetryPolicy.ExecuteAction[TResult](Func`1 func) at ChronoRace.Common.Sql.SqlTools.GetDataSet(DbConnectionProvider provider, IDbConnection conn, String qry, DataSet ds) in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\SqlTools.cs:line 572
at ChronoRace.Common.Sql.SqlTools.GetDataSet(DbConnectionProvider provider, IDbConnection conn, String qry, DataSet ds) in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\SqlTools.cs:line 601
at ChronoRace.Common.Sql.SqlTools.GetDataSet(DbConnectionProvider provider, IDbConnection conn, String qry) in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\SqlTools.cs:line 612
at ChronoRace.Common.Sql.DataSetCache.GetDataSet(DbConnectionProvider provider, String qry) in D:\ChronoRace\git\chronorace-git\Modules\Infrastructure\Legacy\ChronoRace.Utilities.Sql\DataSetCache.cs:line 53
at ChronoRace.Print.Report.ReportGeneratorConfig.BuildGeneratorConfig(CCQuery ccq, Boolean pageable) in D:\ChronoRace\git\chronorace-git\Modules\Legacy\ChronoRace.Print\Report\ReportGeneratorConfig.cs:line 123
at ReportGeneratorGadget.get_Config() in D:\ChronoRace\git\chronorace-git\Web\Registration\ChronoRace.WEB.Azure\Classements\Controls\ReportGeneratorControl.ascx.cs:line 89
at ClassementsClassement.GenereRapport() in D:\ChronoRace\git\chronorace-git\Web\Registration\ChronoRace.WEB.Azure\Classements\Classement.aspx.cs:line 976

Query: select cdta.id_Classement as sH_IdClassement, case when isnull(state,'')='' then cast(pos_categ as varchar)+'.' else state end as [sR_#RANG] , dossard as [sI_#NR] , case when sexe<>'M' then sexe else '' end as sC_ ,case when isnull(privacy,0)&8192!=0 then 'ANONYMOUS' else isnull(nom,'')+' '+isnull(prenom,'') end as [sB_#NAME] , case when year(naissance)>1900 then cast(2004-year(naissance) as varchar) else '' end as [sC_#AGE] , isnull(nationalite,pays) as [sC_#NAT] , left(club_open,25) as [#OPEN] , tours as [sR_##] , officiel as [sB_t_#OFFICIEL] , case when pos>0 then officiel/(cast(isnull(distance,) as float)/1000.0) else 0 end as [t_#TKM] , case when pos>0 and isnull(officiel,0)>0 then str(cast(isnull(distance,) as float)/cast(officiel as float)*3600.0,6,2) else '' end as [sI_#MOYENNE] , pos as [sIL_#SCRATCH] , points as [sB_#PTS] , ville as [sI_#LOCALITE] from classement_data cdta where isnull(state,'')<>'DNS' and id_Classement=172 and (null is null or idx-1>=null) and (null is null or idx-1<=null) and (null is null or ville like null) and (null is null or club_ligue like null) and (null is null or club_open like null) and ('ASM' is null or categ = 'ASM') and (null is null or (dossard=null) or (isnull(nom,prenom) like null) ) order by idx