Cette action est irreversible, confirmez la suppression du commentaire ?
Signaler le commentaire
Veuillez sélectionner un problème
Nudité
Violence
Harcèlement
Fraude
Vente illégale
Discours haineux
Terrorisme
Autre
Daniel Carollo
Bonjour Jef!
Vous n'avez pas indique la jointure. Une formulation plus correcte serait: Sql = "SELECT Table1.*, Table2.* FROM Table1 INNER JOIN Table2 ON Table1.IdTache = Table2.IdTache WHERE Table2.SEM01 = True AND Table2.IdTache = 1" Voyez l'aide en ligne sur les jointures.
Bonne continuation.
Daniel :-)
Computing Technologies International - www.computing-tech.com - We provide solutions...
"Jeff" wrote in message news:3f1c0ddf$0$1357$
Bonjour voilà j'ai deux tables:
Table1 --> IdTache Tache
Table2 --> IdOpération IdTache Sem01
Dans la Table1 : 1 Un test 2 Un autre Test
Dans la Table2 : 1 1 Oui
La code
Dim Record As Recordset Dim Sql As String
Sql = "SELECT Table1.*, Table2.* FROM Table1, Table2 WHERE Table2.SEM01
= True AND Table2.IdTache = 1"
Set Record = CurrentDb.OpenRecordset(Sql)
With Record If .RecordCount > 0 Then .MoveLast Do While Not .EOF print .Fields!Table1.Tache print .Fields!table2.idOperation
.MoveNext Loop End If .Close End With
Set Record = Nothing
j'obtient
1 Un test 1 Un test
comment faire pour ne pas répéter le recordset ??
Merci de votre aide @+ Jeff
Bonjour Jef!
Vous n'avez pas indique la jointure. Une formulation plus correcte serait:
Sql = "SELECT Table1.*, Table2.* FROM Table1 INNER JOIN Table2 ON
Table1.IdTache = Table2.IdTache WHERE Table2.SEM01 = True AND Table2.IdTache
= 1"
Voyez l'aide en ligne sur les jointures.
Bonne continuation.
Daniel :-)
Computing Technologies International - www.computing-tech.com - We
provide solutions...
"Jeff" <mail@free.fr> wrote in message
news:3f1c0ddf$0$1357$626a54ce@news.free.fr...
Bonjour voilà j'ai deux tables:
Table1 --> IdTache
Tache
Table2 --> IdOpération
IdTache
Sem01
Dans la Table1 : 1 Un test
2 Un autre Test
Dans la Table2 : 1 1 Oui
La code
Dim Record As Recordset
Dim Sql As String
Sql = "SELECT Table1.*, Table2.* FROM Table1, Table2 WHERE
Table2.SEM01
= True AND Table2.IdTache = 1"
Set Record = CurrentDb.OpenRecordset(Sql)
With Record
If .RecordCount > 0 Then
.MoveLast
Do While Not .EOF
print .Fields!Table1.Tache
print .Fields!table2.idOperation
Vous n'avez pas indique la jointure. Une formulation plus correcte serait: Sql = "SELECT Table1.*, Table2.* FROM Table1 INNER JOIN Table2 ON Table1.IdTache = Table2.IdTache WHERE Table2.SEM01 = True AND Table2.IdTache = 1" Voyez l'aide en ligne sur les jointures.
Bonne continuation.
Daniel :-)
Computing Technologies International - www.computing-tech.com - We provide solutions...
"Jeff" wrote in message news:3f1c0ddf$0$1357$
Bonjour voilà j'ai deux tables:
Table1 --> IdTache Tache
Table2 --> IdOpération IdTache Sem01
Dans la Table1 : 1 Un test 2 Un autre Test
Dans la Table2 : 1 1 Oui
La code
Dim Record As Recordset Dim Sql As String
Sql = "SELECT Table1.*, Table2.* FROM Table1, Table2 WHERE Table2.SEM01
= True AND Table2.IdTache = 1"
Set Record = CurrentDb.OpenRecordset(Sql)
With Record If .RecordCount > 0 Then .MoveLast Do While Not .EOF print .Fields!Table1.Tache print .Fields!table2.idOperation
.MoveNext Loop End If .Close End With
Set Record = Nothing
j'obtient
1 Un test 1 Un test
comment faire pour ne pas répéter le recordset ??
Merci de votre aide @+ Jeff
Jeff
heu oui ces vrai
merci
"Daniel Carollo" a écrit dans le message de news:
Bonjour Jef!
Vous n'avez pas indique la jointure. Une formulation plus correcte serait: Sql = "SELECT Table1.*, Table2.* FROM Table1 INNER JOIN Table2 ON Table1.IdTache = Table2.IdTache WHERE Table2.SEM01 = True AND Table2.IdTache
= 1" Voyez l'aide en ligne sur les jointures.
Bonne continuation.
Daniel :-)
Computing Technologies International - www.computing-tech.com - We provide solutions...
"Jeff" wrote in message news:3f1c0ddf$0$1357$
Bonjour voilà j'ai deux tables:
Table1 --> IdTache Tache
Table2 --> IdOpération IdTache Sem01
Dans la Table1 : 1 Un test 2 Un autre Test
Dans la Table2 : 1 1 Oui
La code
Dim Record As Recordset Dim Sql As String
Sql = "SELECT Table1.*, Table2.* FROM Table1, Table2 WHERE Table2.SEM01
= True AND Table2.IdTache = 1"
Set Record = CurrentDb.OpenRecordset(Sql)
With Record If .RecordCount > 0 Then .MoveLast Do While Not .EOF print .Fields!Table1.Tache print .Fields!table2.idOperation
.MoveNext Loop End If .Close End With
Set Record = Nothing
j'obtient
1 Un test 1 Un test
comment faire pour ne pas répéter le recordset ??
Merci de votre aide @+ Jeff
heu oui ces vrai
merci
"Daniel Carollo" <danielc@NO_SPAM_PLEASE.computing-tech.com> a écrit dans le
message de news:eOfFuk8TDHA.1688@TK2MSFTNGP11.phx.gbl...
Bonjour Jef!
Vous n'avez pas indique la jointure. Une formulation plus correcte serait:
Sql = "SELECT Table1.*, Table2.* FROM Table1 INNER JOIN Table2 ON
Table1.IdTache = Table2.IdTache WHERE Table2.SEM01 = True AND
Table2.IdTache
= 1"
Voyez l'aide en ligne sur les jointures.
Bonne continuation.
Daniel :-)
Computing Technologies International - www.computing-tech.com - We
provide solutions...
"Jeff" <mail@free.fr> wrote in message
news:3f1c0ddf$0$1357$626a54ce@news.free.fr...
Bonjour voilà j'ai deux tables:
Table1 --> IdTache
Tache
Table2 --> IdOpération
IdTache
Sem01
Dans la Table1 : 1 Un test
2 Un autre Test
Dans la Table2 : 1 1 Oui
La code
Dim Record As Recordset
Dim Sql As String
Sql = "SELECT Table1.*, Table2.* FROM Table1, Table2 WHERE
Table2.SEM01
= True AND Table2.IdTache = 1"
Set Record = CurrentDb.OpenRecordset(Sql)
With Record
If .RecordCount > 0 Then
.MoveLast
Do While Not .EOF
print .Fields!Table1.Tache
print .Fields!table2.idOperation
Vous n'avez pas indique la jointure. Une formulation plus correcte serait: Sql = "SELECT Table1.*, Table2.* FROM Table1 INNER JOIN Table2 ON Table1.IdTache = Table2.IdTache WHERE Table2.SEM01 = True AND Table2.IdTache
= 1" Voyez l'aide en ligne sur les jointures.
Bonne continuation.
Daniel :-)
Computing Technologies International - www.computing-tech.com - We provide solutions...
"Jeff" wrote in message news:3f1c0ddf$0$1357$
Bonjour voilà j'ai deux tables:
Table1 --> IdTache Tache
Table2 --> IdOpération IdTache Sem01
Dans la Table1 : 1 Un test 2 Un autre Test
Dans la Table2 : 1 1 Oui
La code
Dim Record As Recordset Dim Sql As String
Sql = "SELECT Table1.*, Table2.* FROM Table1, Table2 WHERE Table2.SEM01
= True AND Table2.IdTache = 1"
Set Record = CurrentDb.OpenRecordset(Sql)
With Record If .RecordCount > 0 Then .MoveLast Do While Not .EOF print .Fields!Table1.Tache print .Fields!table2.idOperation