Mvula Member Licensed User Longtime User Nov 4, 2016 #1 In the example below, https://www.b4x.com/android/forum/threads/sql-tutorial.6736/ Sub InsertBlob 'convert the image file to a bytes arrayDim InputStream1 AsInputStream InputStream1 = File.OpenInput(File.DirAssets, "smiley.gif") Dim OutputStream1 AsOutputStream OutputStream1.InitializeToBytesArray(1000) File.Copy2(InputStream1, OutputStream1) Dim Buffer() As Byte 'declares an empty array Buffer = OutputStream1.ToBytesArray 'write the image to the database SQL1.ExecNonQuery2("INSERT INTO table2 VALUES('smiley', ?)", ArrayAs Object(Buffer))End Sub I am using the exact same table BUT I want to UPDATE the table instead of INSERTING into the table. What is the correct phrase, please?
In the example below, https://www.b4x.com/android/forum/threads/sql-tutorial.6736/ Sub InsertBlob 'convert the image file to a bytes arrayDim InputStream1 AsInputStream InputStream1 = File.OpenInput(File.DirAssets, "smiley.gif") Dim OutputStream1 AsOutputStream OutputStream1.InitializeToBytesArray(1000) File.Copy2(InputStream1, OutputStream1) Dim Buffer() As Byte 'declares an empty array Buffer = OutputStream1.ToBytesArray 'write the image to the database SQL1.ExecNonQuery2("INSERT INTO table2 VALUES('smiley', ?)", ArrayAs Object(Buffer))End Sub I am using the exact same table BUT I want to UPDATE the table instead of INSERTING into the table. What is the correct phrase, please?
Lahksman Active Member Licensed User Longtime User Nov 4, 2016 #2 Check Klaus's user guide. Chapter 5 is all about SQLite databases including UPDATE. Upvote 0