Questions tagged [firebase-realtime-database]

Firebase Realtime Database is a cloud hosted, NoSQL, JSON database that provides offline caching and synchronization. Do NOT use this tag for questions about Cloud Firestore; instead use the [google-cloud-firestore] tag.

About Firebase Realtime Database

Firebase Realtime Database is a component of the Firebase suite of tools for cross-platform application development.

  • Intuitive and easy-to-use API
  • Remains responsive regardless of network latency or Internet connectivity so your Firebase app works offline. Data synchronizes when connectivity returns
  • Handles the complexity of realtime synchronization and provides flexible conflict resolution
  • Accessible directly from client SDKs, or from your server with the REST API

To learn more: Firebase Realtime Database for SQL Developers (video series)

Related tags

40037 questions
5
votes
4 answers

How to update an item stored in an ArrayList? (Android)

I am fetching data from Firebase and after fetching the supposed data, I stored it on an ArrayList. So here is the sample code. markerArray = new ArrayList<>(); Firebase ref = new Firebase(Config.FIREBASE_URL_DRIVER); ref.addValueEventListener(new…
5
votes
1 answer

Firebase 3x method not working in real device but working on simulator Swift 3.0

We are working with Google Firebase 3.x version and we faced strange issue from Firebase. We are using Swift 3.0 and for getting user details, we are using the following code snippet: func getUserDetails(uid text:String!, userBlock:@escaping (_…
Nitin Gohel
  • 49,482
  • 17
  • 105
  • 144
5
votes
1 answer

Using Firebase API in Lambda Functions AWS

Can someone please tell me how to do this? This is what i have so far and It's not adding data into my database I tested this out without using lambda functions on a regular web application and it works var http = require('http'); var firebase =…
5
votes
1 answer

How to retrieve data from a Push firebase data

i used push to save data on firebase and it automatically saves with its own push id, now am trying to retrieve the data to use for history but i cant because of that id. this is what i have mDatabase =…
henry
  • 81
  • 2
  • 9
5
votes
2 answers

Write new Data in Android Firebase Database

I am using Firebase Database in an Android application, and everytime a user is registred I store some values in the database for this purpose I am doing what follows: database = FirebaseDatabase.getInstance(); …
rainman
  • 2,551
  • 6
  • 29
  • 43
5
votes
0 answers

Observers hanging when using Firebase offline

I'm trying to add offline capabilities to our iOS app (simply put, an app that manages users and projects), which relies on Firebase. This is using Swift 3.0. I have followed the guides and did the following: Added this to my application delegate,…
bbousquet
  • 49
  • 1
  • 4
5
votes
3 answers

Getting Data from Firebase in Swift 3.0

I am using an app with Firebase. After moving to swift 3.0 today, Xcode asked me to change this code: ref.observeEventType(.ChildAdded, withBlock: { snapshot in let currentData = snapshot.value!.objectForKey("Dogs") if…
Eliko
  • 1,137
  • 4
  • 16
  • 26
5
votes
3 answers

(setValue:) Cannot store object of type _SwiftValue at pictureURL. Can only store objects of type NSNumber, NSString, NSDictionary, and NSArray

Having some issues understanding firebase with Swift 3. I've remade my observer to look like this: currentUserFirebaseReference.observeSingleEvent(of: .value, with: { (snapshot: FIRDataSnapshot) in let UID = snapshot.key let dict…
user6820041
  • 1,213
  • 2
  • 13
  • 29
5
votes
2 answers

Swift / Firebase: How do I properly store a Facebook user into Firebase database when they create an account?

I'm trying to save users to my firebase database. I'm using a FBSDKLoginManager() to create an account / log in. Upon account creation, I want to store the users into my firebase database. I can currently log the user in and their email shows up in…
5
votes
1 answer

Firebase,Swift : Not able to retrieve Data

I'm trying to do a simple task, to get a value from Firebase. I added the image below with the relevant screens. At least one of the print commands should print a message to the console, but it's not working. I've been trying to fix it for 1,5 days…
5
votes
0 answers

Firebase - iOS suddenly returning null for snapshots that I know exist?

I came back to work on a project I have not touched in a week and suddenly my code was not working. I take a snapshot of data that I am sure exists (I can see it exactly in the database and changed no code) yet it is returning NSNULL for the…
Alex
  • 299
  • 3
  • 16
5
votes
1 answer

Firebase : Retrieve childByAutoID from Realtime Database

I'm currently learning the ropes of Firebase and iOS so please bear with me. I'm currently posting to my table called Posts as shown here: let postInfo = ["Description": txtPostDescription.text!, "ImageUrl": imgUrl, "Likes": 0] var t =…
Code Ratchet
  • 5,758
  • 18
  • 77
  • 141
5
votes
0 answers

Load formatted text from firebase and display on IOS

I have a terms and condition(TOC) section on my app. What I want to achieve is to download the TOC from the internet and load it onto the screen for the user to use. Because I dont know any html/web stuff, what I am currently doing is putting all…
user172902
  • 3,541
  • 9
  • 32
  • 75
5
votes
1 answer

Creating an API with Firebase 3

I have a use case where I'd like to create an API that allows users of my Firebase web application to access their portion of the Firebase Realtime Database programatically from a server. I’ve explored a couple of options, but it would be great to…
user4717644
5
votes
2 answers

setState with Firebase Promise in React

How can i set state inside react component? I`ve got error message: Uncaught TypeError: Cannot read property 'setState' of null here is the component code listing: class MessageList extends React.Component { constructor(props){ super(props); …