Jump to content

Novos erros SQLite

Go to solution Solved by HQuintas,

Recommended Posts


Novos erros após actualização SQLite. Recentemente fiz um upgrade de uma máquina para windows 10 64 bits, actualizei a dll do sqlite para a versão mas só tem surgido problemas.

Para adicionar um novo registo tinha a seguinte rotina:

 If existe() = False Then
            strSQL = "INSERT INTO clientes (id,nome,morada1,morada2,codpostal,local,tel,movel,nif,email) " &
            "VALUES (@id,@nome,@morada1,@morada2,@codpostal,@local,@tel,@movel,@nif,@email)"

            strSQL = "UPDATE clientes set id=@id,nome=@nome,morada1=@morada1,morada2=@morada2,codpostal=@codpostal,local=@local,tel=@tel,movel=@movel,nif=@nif,email=@email  WHERE id=@id"
        End If

        Dim cmd As New SQLiteCommand(strSQL, connection)


        With cmd.Parameters
            .Add("@id", SqlDbType.Int).Value = txt_numcli.Text
            .Add("@nome", SqlDbType.VarChar).Value = txt_nome.Text
            .Add("@morada1", SqlDbType.VarChar).Value = txt_morada1.Text
            .Add("@morada2", SqlDbType.VarChar).Value = txt_morada2.Text
            .Add("@codpostal", SqlDbType.VarChar).Value = txt_codpos.Text
            .Add("@local", SqlDbType.VarChar).Value = txt_localidade.Text
            .Add("@tel", SqlDbType.VarChar).Value = txt_tel.Text
            .Add("@movel", SqlDbType.VarChar).Value = txt_movel.Text
            .Add("@nif", SqlDbType.Int).Value = txt_nif.Text
            .Add("@email", SqlDbType.VarChar).Value = txt_email.Text
        End With



        frm_orca_lista.txt_num_cliente.Text = txt_numcli.Text


Como posso resolver? Será que é a versão certa?...?

Também para ler, tenho que alterar as rotinas. O que funcionava bem deixou de funcionar.


Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.