J Jinora29 Member Jan 13, 2021 #1 I read the tutorial for getting a blob and an image from a database, but I couldn't understand it properly and when I write the code that is in that tutorial, the program doesn't work. Can someone tell me what the appropriate code is? This is my code for getting text... B4X: Copy Dim rs As ResultSet rs = Starter.sqll.ExecQuery2("SELECT Text from Datable WHERE Date=?" , Array As String(total)) If rs.NextRow Then Label1.Text = rs.GetString("Text") End If rs.Close Sorry if I'm asking too many questions today ?
I read the tutorial for getting a blob and an image from a database, but I couldn't understand it properly and when I write the code that is in that tutorial, the program doesn't work. Can someone tell me what the appropriate code is? This is my code for getting text... B4X: Copy Dim rs As ResultSet rs = Starter.sqll.ExecQuery2("SELECT Text from Datable WHERE Date=?" , Array As String(total)) If rs.NextRow Then Label1.Text = rs.GetString("Text") End If rs.Close Sorry if I'm asking too many questions today ?
klaus Expert Licensed User Longtime User Jan 13, 2021 #2 Which tutorial are you speaking of? You might have a look at the B4X SQLite database booklet. Especially chapters: 2.2.18 Insert an image and 2.2.18 Read an image Upvote 0
Which tutorial are you speaking of? You might have a look at the B4X SQLite database booklet. Especially chapters: 2.2.18 Insert an image and 2.2.18 Read an image
J Jinora29 Member Jan 13, 2021 #3 klaus said: Which tutorial are you speaking of? You might have a look at the B4X SQLite database booklet. Especially chapters: 2.2.18 Insert an image and 2.2.18 Read an image Click to expand... I used the codes written in this, but it seems that I don't have a library, because my "ResultSet1" is in red... What library does it need? Upvote 0
klaus said: Which tutorial are you speaking of? You might have a look at the B4X SQLite database booklet. Especially chapters: 2.2.18 Insert an image and 2.2.18 Read an image Click to expand... I used the codes written in this, but it seems that I don't have a library, because my "ResultSet1" is in red... What library does it need?
M Mahares Expert Licensed User Longtime User Jan 13, 2021 #4 Jinora29 said: I used the codes written in this Click to expand... What is 'this'. You do not mention what 'this' is. I think you are making it a little harder for anyone to help here. You really need to show what code you used to extract the blob, then it would be easier to help Upvote 0
Jinora29 said: I used the codes written in this Click to expand... What is 'this'. You do not mention what 'this' is. I think you are making it a little harder for anyone to help here. You really need to show what code you used to extract the blob, then it would be easier to help
klaus Expert Licensed User Longtime User Jan 13, 2021 #5 The code you show in post #1 is not for an image! You need to check the SQL library in the Libraries Manger. It seems that in another thread you have already a working project with a SQLite database so it should work. Upvote 0
The code you show in post #1 is not for an image! You need to check the SQL library in the Libraries Manger. It seems that in another thread you have already a working project with a SQLite database so it should work.
klaus Expert Licensed User Longtime User Jan 13, 2021 #6 I would suggest you to read this chapter: Ask a question in the forum in the B4X Help tools booklet. Upvote 0