|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
Re: ADO/VB6/.addnew
From: Marcin P (protected
poczta.onet.pl)
Date: Mon Jan 19 2004 - 07:36:13 CST
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
IMHO it would be much better to
Call objConn.Execute "INSERT INTO IMPOSTAZIONI(NOME,VALORE)
VALUES('VAR-NAME1','1.2.3')
and the best would be to use command object with parametrized query (or
Stored Procedure).
Why would you get all the records from this table when you only
want to insert one ??!
Best Regards,
Marcin Pytel
Uzytkownik "ilMes mes" <il_mes
hotmail.com> napisal w wiadomosci
news:Law9-F98BtKarvzr0dS00039d43
hotmail.com...
>
> Hello,
>
> MaxDB 7.05.08, on Linux Red Hat 8.0
> Visual Basic 6.0, ADO 2.8
>
> i have an .AddNew problem:
>
> Dim rs As adodb.Recordset
> Dim objConn As New adodb.Connection
> objConn.ConnectionString = "DSN=MATRICE;UID=USER;PWD=PSWUSER"
> Call objConn.Open
>
> Set rs = New adodb.Recordset
> Set rs.ActiveConnection = objConn
> rs.CursorType = adOpenStatic
> rs.CursorLocation = adUseClient
> rs.Open "SELECT * FROM IMPOSTAZIONI"
>
> rs.AddNew ' << DO NOT WORK!!!!!! WHY???????
> rs.Fields("NOME") = "VAR-NAME1"
> rs.Fields("VALORE") = "1.2.3"
> rs.Update
>
> the VB generate the error:
> 3251 - The object or provider is not capable of performing the requested
> operation. Some operations depend on a particular provider version.
>
> I tryed adOpenKeyset and adUseServer in same combinations, but do not
work.
> how it is made to make a addnew with ADO and MaxDB?
>
> TNKS!
>
> Ettore, il Mes
>
> _________________________________________________________________
> MSN Extra Storage! Hotmail all'ennesima potenza. Provalo!
>
http://join.msn.com/?pgmarket=it-it&page=hotmail/es2&xAPID=1983&DI=2049&ST=1
>
>
> --
> MaxDB Discussion Mailing List
> For list archives: http://lists.mysql.com/maxdb
> To unsubscribe:
http://lists.mysql.com/maxdb?unsub=gcdm-maxdb
m.gmane.org
>
>
--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]