Ver Mensaje Individual
  #6 (permalink)  
Antiguo 09/05/2011, 12:08
Avatar de culd
culd
 
Fecha de Ingreso: noviembre-2003
Mensajes: 959
Antigüedad: 20 años, 6 meses
Puntos: 19
Respuesta: Problema con delete de registros.

Cita:
Iniciado por t0n1 Ver Mensaje
Una base de datos access alojada en un servidor sql.
Access es un archivo .mdb
SQL es un lenguaje que lo utilizan muchos motores de base de datos...

Tu respuesta tendria que haber sido...
UNA BASE DE DATOS ACCESS, en la que uso SENTENCIAS SQL

Cita:
Iniciado por t0n1 Ver Mensaje
¿Dónde tendría que poner el order by?. Acá está el código que utilizo:

If Not Conectar() Then Exit Sub

sql = "select * from Informes where Codigo = " & lblCodigo.Caption & ""
Set Rs = Cn.Execute(sql)
If Rs.EOF Then
sql = "insert into Informes (Codigo, Apellido, Domicilio, Telefono, Localidad, Email, Interesado) values (" & lblCodigo.Caption & ", '" & txtApellido.Text & "', '" & txtDomicilio.Text & "', '" & txtTelefono.Text & "', '" & txtLocalidad.Text & "', '" & txtEmail.Text & "', " & cmbCurso & ")"
MsgBox "Registro agregado"
txtApellido.Text = ""
txtDomicilio.Text = ""
txtTelefono.Text = ""
txtLocalidad.Text = ""
txtEmail.Text = ""
txtApellido.SetFocus
End If

Set Rs = Cn.Execute(sql)

Set Rs = Nothing
A vos no te tiene que importar como guarda el registro... A vos lo que te tiene que importar es como leerlo.

Vos guardalo como quieras... Al momento de leer la informacion, y que te quede ordenada ahi usas un ORDER BY en la consulta SELECT