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 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71
| Private Sub Validé_SAV_Click()
Dim MyDate As Date
Dim RunMysql As String
Dim strmysql As String
Dim Or_Affectation As String
Dim EMEI As String
Dim anc_EMEI As String
DoCmd.SetWarnings False
Société = Me.Société.Column(0)
Adresse = Me.Société.Column(1)
Code_Postal = Me.Société.Column(2)
Ville = Me.Société.Column(3)
Service = Me.Société.Column(4)
Société_2 = Me.User.Column(1)
Nom = Me.User.Column(2)
Adresse_2 = Me.User.Column(3)
Code_Postal_2 = Me.User.Column(4)
Ville_2 = Me.User.Column(5)
Nom_utilisateur = Me.User.Column(6)
Email = Me.User.Column(7)
Num_Tel = Me.User.Column(8)
EMEI = Me.EMEI.Column(0)
Num_ligne = Me.EMEI.Column(1)
Marque = Me.EMEI.Column(2)
Modele = Me.EMEI.Column(3)
RunMysql = RunMysql & " INSERT INTO [Temps envoie SAV] ( [Société (destinataire)], [Adresse (destinataire)], [Code Postal (destinataire)], [Ville (destinataire)], [Service (destinataire)], "
RunMysql = RunMysql & " Société, Nom, Adresse, [Code Postal], Ville, [Nom de l'user], [Email (user)], [Numéro ligne (user)], [Numéro ligne du terminal (pann)], Marque, Modele, IMEI )"
RunMysql = RunMysql & " SELECT """
RunMysql = RunMysql & Société
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Adresse
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Code_Postal
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Ville
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Service
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Société_2
RunMysql = RunMysql & ""","""
RunMysql = RunMysql & Nom
RunMysql = RunMysql & ""","""
RunMysql = RunMysql & Adresse_2
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Code_Postal_2
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Ville_2
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Nom_utilisateur
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Email
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Num_Tel
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Num_ligne
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Marque
RunMysql = RunMysql & """, """
RunMysql = RunMysql & Modele
RunMysql = RunMysql & """, """
RunMysql = RunMysql & EMEI
RunMysql = RunMysql & """"
RunMysql = RunMysql & " FROM [Adresse de retour], [Coordonnés Client], Modèle INNER JOIN (Equipement INNER JOIN "
RunMysql = RunMysql & " (Abonnements INNER JOIN Affectation ON Abonnements.Num_SIM = Affectation.Num_SIM) ON Equipement.Num_EMEI = Affectation.Num_EMEI) ON Modèle.Modele = Equipement.Modele"
RunMysql = RunMysql & " where [Coordonnés Client].Nom =" & Me.User.Column(2) & ";"
DoCmd.RunSQL RunMysql
End Sub |
Partager