firebase-realtime-database

Code not finishing the function, it is ending execution halfway through

ぐ巨炮叔叔 提交于 2020-07-23 06:48:13
问题 My code is as follows: @IBAction func clicked(_ sender: Any) { let ref = Database.database().reference() let pass = password.text var firpass = "" var bool = false; ref.child(name.text as! String).child("password").observeSingleEvent(of: .value, with: { dataSnapshot in firpass = dataSnapshot.value as! String if firpass == pass { bool = true print("in here") } }) print(bool) if bool { self.sendname = name.text! let vc = DatabaseTableViewController(nibName: "DatabaseTableViewController", bundle

Code not finishing the function, it is ending execution halfway through

你说的曾经没有我的故事 提交于 2020-07-23 06:46:51
问题 My code is as follows: @IBAction func clicked(_ sender: Any) { let ref = Database.database().reference() let pass = password.text var firpass = "" var bool = false; ref.child(name.text as! String).child("password").observeSingleEvent(of: .value, with: { dataSnapshot in firpass = dataSnapshot.value as! String if firpass == pass { bool = true print("in here") } }) print(bool) if bool { self.sendname = name.text! let vc = DatabaseTableViewController(nibName: "DatabaseTableViewController", bundle

Flutter - Firebase RTDB read issue for node at index 0, 1 and 2

一个人想着一个人 提交于 2020-07-23 06:43:05
问题 In my Flutter code, I have a dropdown list linked to a list of cars. Once a car is selected I want to retrieve the brand associated to the car. But for some reason the code used to read the firebase RTDB has to be different for Index 0, index 1 and Index 2 and above. My sample tree taken as is from my RTDB is as follows: [ { "Brand" : "Alfa Romeo", "Car" : "Alfa Romeo Guilia 2.9 V6 BiTurbo Quadrifoglioli Automatic Petrol Sedan RWD", }, { "Brand" : "Alfa Romeo", "Car" : "Alfa Romeo Guilia 2.0T

Flutter - Firebase RTDB read issue for node at index 0, 1 and 2

我的未来我决定 提交于 2020-07-23 06:42:38
问题 In my Flutter code, I have a dropdown list linked to a list of cars. Once a car is selected I want to retrieve the brand associated to the car. But for some reason the code used to read the firebase RTDB has to be different for Index 0, index 1 and Index 2 and above. My sample tree taken as is from my RTDB is as follows: [ { "Brand" : "Alfa Romeo", "Car" : "Alfa Romeo Guilia 2.9 V6 BiTurbo Quadrifoglioli Automatic Petrol Sedan RWD", }, { "Brand" : "Alfa Romeo", "Car" : "Alfa Romeo Guilia 2.0T

Flutter - Firebase RTDB read issue for node at index 0, 1 and 2

梦想的初衷 提交于 2020-07-23 06:41:30
问题 In my Flutter code, I have a dropdown list linked to a list of cars. Once a car is selected I want to retrieve the brand associated to the car. But for some reason the code used to read the firebase RTDB has to be different for Index 0, index 1 and Index 2 and above. My sample tree taken as is from my RTDB is as follows: [ { "Brand" : "Alfa Romeo", "Car" : "Alfa Romeo Guilia 2.9 V6 BiTurbo Quadrifoglioli Automatic Petrol Sedan RWD", }, { "Brand" : "Alfa Romeo", "Car" : "Alfa Romeo Guilia 2.0T

Expected a List while deserializing, but got a class java.util.HashMap

假装没事ソ 提交于 2020-07-22 21:36:46
问题 I'm trying to get a list of users from Firebase, in Android. I already have the uuid of the user, and using that I'm trying to get the entire object. The uuid is both the node name and a field inside the user node (identical, of course). Here is my code: DatabaseReference usersRef = FirebaseDatabase.getInstance().getReference("users"); Query query = usersRef.orderByChild("uuid").equalTo(animalMarker.getUserUid()); query.addListenerForSingleValueEvent(new ValueEventListener() { @Override

Expected a List while deserializing, but got a class java.util.HashMap

半世苍凉 提交于 2020-07-22 21:35:54
问题 I'm trying to get a list of users from Firebase, in Android. I already have the uuid of the user, and using that I'm trying to get the entire object. The uuid is both the node name and a field inside the user node (identical, of course). Here is my code: DatabaseReference usersRef = FirebaseDatabase.getInstance().getReference("users"); Query query = usersRef.orderByChild("uuid").equalTo(animalMarker.getUserUid()); query.addListenerForSingleValueEvent(new ValueEventListener() { @Override

Make first letter of child name capital in Firebase

安稳与你 提交于 2020-07-22 06:08:07
问题 I push data to Firebase using Order object, the question is I want the first letter of every child name capital. I defined the property like "Complain" but in Firebase it still shows as "complain", I dont know how to make it. The current structure of the Firebase: The structure I want: I defined the property like this: @Data public class Order implements Serializable { @SerializedName("Complain") private String Complain; public Order() { Complain = ""; } public String getComplain() { return

Analyze Firebase data

两盒软妹~` 提交于 2020-07-21 06:29:05
问题 I have a mobile app that uses Firebase to store it's data. I am storing all user data, different business objects and relationships. I am looking for a way to analyze my data. I want to execute queries and aggregations on the data, and to generate reports. The Firebase site mentioned using BigQuery from Google, but there seems to be no easy way to import data from Firebase to it. What is the best way to achieve this? I know I can create daily backups, but after I have the raw JSON data how

Javascript WebSocket into Firebase?

僤鯓⒐⒋嵵緔 提交于 2020-07-20 08:22:33
问题 Is it possible to use standard WebSocket's to access a Firebase database instead of using their library. Specifically, I want to access the firebase real-time database using only vanilla javascript. Is that even feasible? 回答1: In most modern browsers the Firebase client communicates with its back-end over web sockets. But the wire protocol it uses is not documented, and may change over time. Then again, you could study the open-source JavaScript SDK to get a pretty good idea of how it works