Gracias Kipow por responder.
De hecho realizo una desconexion y una conexion a la base de datos. Lo que intento hacer es lo siguiente:
1) Realizo reestructura de la tabla.
2) Como esta tabla contiene informacion, la consulto (tambien mediante un TQuery con RequestLive = true) y edito el registro.
Pero cuando intento Editar el registro me marca un error de que el campo no existe. Pero curiosamente edito 2 campos, los cuales son nuevos. Pero solo uno de ellos me marca el error que no existe.
Código Delphi
[-]
with Tabla do
begin
...
SQL.Clear;
SQL.Add('ALTER TABLE USUARIO ADD CODIINTE INTEGER NOT NULL');
ExecSQL;
Close;
...
SQL.Clear;
SQL.Add('ALTER TABLE MUSUA ADD CAMBPASE CHAR(1) DEFAULT ''N''');
ExecSQL;
Close;
...
dm.dbase.Connected := false;
dm.dbase.Connected := true;
Close;
SQL.Clear;
SQL.Add('Select CODIINTE from MUSUA');
Open;
First;
While not Eof do
begin
Inc(vX);
Edit;
FieldByName('CODIINTE').AsInteger := vX;
FieldByName('CAMBPASE').asString := 'N'; Next;
end;
end;
...
¿¿¿Alguna sugerencia!????