On Sep 28, 2006, at 10:40 AM, Norman Palardy wrote:

Hard to know if it SQLite forgiving things that it should not or just the error not being reported A quick test here suggest SQLIte does give you an error when there are more values than columns in something like

        create table test ( a integer , b varchar(100) )
        insert into test ( a , b ) values ( 1,1,1,1 )

In my test app using the older SQLIte plugin I do get an error saying "4 values for 2 columns"

Trying to reproduce the issue here in a sample app, I get a similar error message. In other words, REALSQLdatabase is behaving as expected.

I need to look into this more.  My code below:

-----------

  Dim DB As New REALSQLDatabase
  Dim rs As RecordSet

  If Not DB.Connect Then
    MsgBox "Cannot connect to the In-Memory database."
  Else
DB.SQLExecute("CREATE TABLE testTable ( ivalue INTEGER , dvalue DOUBLE )")
    If DB.Error Then
MsgBox "Error on CREATE TABLE: [" + Str(DB.ErrorCode) + "] " + DB.ErrorMessage
    Else
      DB.Commit
    End If
  End If

DB.SQLExecute("INSERT INTO testTable ( ivalue, dvalue ) VALUES ( 15, 103,58 )")

  If DB.Error Then
MsgBox "Error on INSERT: [" + Str(DB.ErrorCode) + "] " + DB.ErrorMessage
  Else
    DB.Commit
  End If

  rs = DB.SQLSelect("SELECT dvalue FROM testTable")

If Not (rs Is Nil) Then MsgBox Format(rs.RecordCount, "0") + " records."

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to