How will the user can access only his data?

This depends on whether "all" the plants need to be available in the online database, or not ?

Also note that image storage in cloudDB is currently broken, one needs to convert the image to base64 in order to save it there, and to convert back to display.

He can selectively do it too, by changing the image names according to the plants and dates of planting, and store them in the app specific directory, and use the FileTools (Kodular Community) extension to delete those if required.

@TIMAI2

He actually mentioned that he is using TinyDB to store the images. :sweat_smile:

See Below :

This doesn't make any sense in relation to storing images/data online ????
There is no real requirement for an extension in order to save files/images/data to the ASD.

Because the OP needs to reorganise their blocks in order to use cloudDB as the online datastore. Conversion to base64 still applies regardless of datastore location, if using tinydb to "store" images. Of course the OP can cache the images of the user to the device, to avoid repetitive downloads.

1 Like

Could you tell me how could I, that would be a help to me too. :sweat_smile:

This extension by @Juan_Antonio:

http://kio4.com/appinventor/277i_extension_imagen_string.htm

2 Likes

Yep, I'd be the one will be doing this project of mine, it is just that I'm not sure how I'm going to pull off the app's features; it's far too complicated for me as I'm still new and I can't seem to find something that is really helping me, cause if there is, maybe I'm not here, asking for someone's help.

So here are the app's features; I've already completed some of them, but there's still a significant portion, particularly the database, that I'm unable to complete.
The first is that users can create an account and sign in using the account he created, which I have already done using Cloud DB, I'm thinking of changing it to Firebase as I need the user to be able to access only his account's data, still searching for something that could help me.
After logging in, the user will be taken to the homepage (which still on the process of making).
Following that is the Plants Menu, where users can add their plants and also automatically set alarms and notifications when the plants require watering, fertilizing, and repotting, after the alarm sounds it will be set again, for example, if plant1 requires water every week, the app will sound an alarm and notify the user every week, I guess background tasks extension would help as I need the app to notif the user eventhough the app is closed or not in the background.
Also, if the user clicks on his added plant, it will open something similar to a card view with all of the plant's details and progress, such as how old is his plants, whens the plant last watered, fertilized, repot and its next watering and so on, he will also see a sample picture of how tall the plant or what look it should have by that time.
Users can also view and read tutorials from each plant, which I have done already also.
The crucial part, which I can't seem to get right, is that once a user logs in, he can only access his own data which I do some research and I think Firebase would be a great help than the CloudDB.

Also, I changed my blocks and come up with this blocks:

It output what I want but I can't get where and how I'm gonna add blocks, to be able to save it in DB may it on a TinyDB, Firebase or CloudDB (can't seem to decide what really can help me). Maybe this screenshot of my design would help what data I'm going to save using one tag? Or should I assigned tag in each and every one of it?^^"

How is this not the case? There is only one person per App isn't there? The User Data is stored on the User's device (phone).

What I don't understand about your GUI is this - do the Users add their plants by selecting from an existing database in the App or are they free to add to the database by providing their own data including an image?

You can store the data for one plant in TinyDb as a single comma separated string, including the image encoded to B64. However, you can instead store the data in an SQLite database, which would allow you to give the User a Search facility.

Yes.

What I mean in here is that, I want my user to access only his data. What happening is, when my user created an account, what he input on his other account is still there. ^^"

I see, I'll try to do a research about that.

I think that means he can access his data if he is logged in from another device, right ?

If thats the case, I have some suggestions.

  1. Use TinyDB to store the user data first.
  2. This will allow him to access his data even if he is offline.
  3. Add a backup button that allows the user to transfer his data to the database.
  4. Let the user restore his data from the database just as he does his log in.

Hello. Just wanted to thank y'all for your suggestions and guides.
So my problem is solved through the used of mySQL DB and the link below really helped me also:
https://www.newthinktank.com/2014/05/connect-app-inventor-mysql-database/
Also I tried if I could be able to retrieve the image without the used of BLOB, Base64, etc, I just followed the format on how I saved and retrieved texts and good thing that it worked also for the image that is saved on asset.




Just wondering, coz I'm using a free web hosting, for me to be able to access the php file, is there a chance that I will encounter some problems in the future?

An SQL database can be on the phone, so it is an offline solution too.

1 Like

Does it have to be online?

How?

No, but is it possible to access the data even if its offline?

LOL, I didn't know about that.
I'm not taught about databases actually, except MS Excel and MS Access.

So, I don't know quite about databases.
Just sharing whatever I know.

Yes, the data is stored on the phone so it is offline and you can access it with your App.

Depending on your search requirements, you could just as easily use a CSV file (comma separated text file), again stored on the phone. Also, depending on how many plants there are, you can use TinyDb.

Excel is a spreadsheet, Access is a Database, both designed by MS for Windows but there are variants for other OS.

2 Likes

Wait can't we access things in Excel from outside.

Not sad to know that actually. :sweat_smile:

In a convoluted way we can because Excel supports the CSV format. In such a process, we have to ensure that Excel is talking UTF-8 in many cases, as that's the default in App Inventor.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.