Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Insert in access with vfp6
Message
De
19/04/2006 12:51:24
Erick Miranda
Formata Data Business - Grupo Linx
Contagem, Brésil
 
 
À
19/04/2006 09:38:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 6
OS:
Windows XP
Network:
Windows 2000 Server
Database:
Visual FoxPro
Divers
Thread ID:
01114563
Message ID:
01114649
Vues:
12
Hi Jose,

If your commands are equal what you wrote here, so you forgot to pass cMotor variable. Try:
xselect = [insert into vehiculos articulo, chassis, tipo, marca, modelo, color, ano, placa, motor) 
values(&carti, &cchasi, &ctipo, &cmarca, &cmodelo, &ccolor, &nano, &cplaca, &cMotor)]
If isn't this, so what did error you receive?


>how I can make to insert a registry in a table of Access with vfp 6, I did it with ado object, but insert does not work with more of a field, it gives error me.
>
>pconn=createobject("ADODB.Connection")
>pconn.open(strconn)
>carti = '19999'
>cchasi = "HDHDGSS"
>ctipo = "CARRO"
>cmarca = "TOYOTA"
>cmodelo= "CAMRY"
>ccolor = "NEGRO"
>nano = "2005"
>cplaca = "ABDG32"
>cmotor = '763HSD'
>xselect=[insert into vehiculos(articulo,chassis,tipo,marca,modelo,color,ano,placa,motor) values(&carti,&cchasi,&ctipo,&cmarca,&cmodelo,&ccolor,&nano,&cplaca)]
>rstabla = createobject("ADODB.Recordset")
>oconn =pconn
>rstabla.cursorlocation = 3
>rstabla.cursortype = 2
>rstabla.locktype = 4
>rstabla.open (xselect,oconn)
Erick
Força Sempre!
Strength Always!
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform