1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
|
// Requete de présence de l'enregistrement
MyQuery = "select ABC.ABC_badge as `Identifiant`, personnel.per_nom as `Nom` ,ABC.ABC_commande as `Authorisation`, ABC.ABC_date as `Dernière modif` from ABC, personnel where ABC.ABC_badge = personnel.per_id ")";
// Initialisation de l'adapter
odataAdapt.SelectCommand = odataCmd;
// Initialisation de la commande
odataCmd.Connection = odataCnct;
odataCmd.CommandText = MyQuery;
// Initialisation de l'adapter
odataAdapt.SelectCommand = odataCmd;
odataAdapt.Fill(dsLocal);
try
{
// Affichage du resultat
dgLocal.DataSource = dsLocal.Tables["Table"].DefaultView;
dgLocal.CaptionText = MyTitle;
dgLocal.Tag = nMode;
}
sbStatus.Text = "Requete à la base de données terminée";
}
catch
{
sbStatus.Text = "Requete à la base de données annulée";
} |
Partager