0
Glr, I want to retrieve a data in Firebase that is inside a Ode. Can someone give me a Light ? Note: This topic already exists and I have seen a solution, but the author of the answer describes a method that no longer exists in Firebase due to updates.. I’m using the image of this same topic because the problem is the same. From the image see if this structure and what I want is to recover the user’s name
Have you tried the method
child( "Notificas" ).child("Usuarios").child("ID")
?– Valdeir Psr
What answer is that that no longer works? Explain what you have tried because there is a danger of receiving a response like the one you have already done.
– Pablo Almeida
then, in the answer q was given is said to use a Firebaseconfig class, I looked at the documentation to q it seems that this class has been reformulated, having some modified methods.. I instituted the new class but did not find the same methods. I soon came to the conclusion that the solution has become obsolete
– Iago Nogueira
@Valdeirpsr, yes, but what happens is that I need to get the user ID to get to the Name field and that I’m not able to do.. You see, I have an Activity Login q collects the past data, creates a new user and stores it in Firebase, then I go to Activity Main where it has 4 Fragments. This is where I’m trying to recover user data
– Iago Nogueira
@When you come out
activity login
foractivity main
, pass the "ID" value as argument or useSharedPreferences
to save the value and consult it later. This way you can do as I mentioned in the first comment.– Valdeir Psr
https://firebase.google.com/docs/database/android/read-and-write?hl=pt-br
– Caique Oliveira