In your Thunkable project, add a “Realtime DB component” (available in Snap to Place projects) or use cloud variables in the Drag and Drop editor. It really does depend on what program you are using.
There can also be another way in which I suppose replacing @ and . with any other application symbol or with just “_” could work.
I’m not sure although…
The JSON code:
{
"Data": {
"exampleKey": "exampleValue",
"users": {
"work7002_gmail_com": {
"email": "work7002@gmail.com"
},
"school7002_gmail_com": {
"email": "school7002@gmail.com"
}
}
},
"organization": {
"kuro": "sfjg"
},
"thunkableAccess": true
}
What block shall I use?
This way, i suppose, reading data would be easier?
I already added a “Realtime DB component” @krish0 I can easily input data, the thing is I’m unable to read it properly…
Looking at the Thunkable Docs right now, give me a couple minutes.
Buddy!
You won’t believe but I’ve watched every video, read every article, NOTHING HELPED!
Alright!
So, after 2-3 days of struggle, I figured it out, that MAYBE the thing I was talking about, was way more complex.
Getting value and find it’s key.
Since every userID is unique, and unpredictable, it will NEVER work.
I tried creating a new userID according to email, replacing every “@” and “.” with “_”.
and then fetched data and use code to check if “schoolwork702_gmail_com”
existed or not.
and guess what! IT WORKED!
- blocks:
and it will answer No/Yes accordingly!
Now if a user tried to register again, it will firstly check if userID (same email is in use or not) and it I can now control is user have an account from same ID or a new one.
NOTE: I’m using signing with google.
I appreciate your sincere efforts buddy!
Congratulations! I’m glad I tried to help, great job on finding it yourself!