http://code.google.com/p/syntaxhighlighter/
// SINGLE QUOTE ' HANGS
// retrouver la publication à partir de l`idagence / id type publication --- in this line makes it crash
if (iIdPublication == 0 && iIdTypePublication != 0 && iIdAgence != 0) {
sStmtA = "SELECT idpublication "
+ " FROM table1 WITH(NOLOCK) "
+ " WHERE idagence = " + iIdAgence
+ " AND idtypepublication = " + iIdTypePublication;
using (Sql sql = new Sql("bc", "immobc"))
iIdPublication = F.ForceInt(sql.ExecScalar(sStmtA));
}
// alertes pour une publication donnée
if(iIdPublication != 0) {
using(Sql oSql = new Sql("aboemail")) {
sStmt = "SELECT table1.*, table3.*, table2.month, table2.year, "
+ " table2.nbsends as nbsends2 "
+ " FROM table1 WITH(NOLOCK) "
+ " LEFT JOIN table2 WITH(NOLOCK) ON table1.idabo_email=table2.idabo_email "
+ " INNER JOIN table3 WITH(NOLOCK) ON table1.idabotypeaction = table3.idabotypeaction "
+ " WHERE idpublication = " + iIdPublication + sWhereSup
+ " ORDER BY table1.idabo_email, table2.year DESC, table2.month DESC";
oDS=oSql.ExecCached(sStmt);
}
}
//Mail.SendMail("glop@glop.com","glop@glop.com","abo",sStmtP + " " + sStmtA + " " + sStmt,false);
string[] AMonths = new string[12] { "Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Aout","Septembre","Octobre","Novembre","Décembre" };
DicContext["AMonths"] = AMonths;