Edward Jackson

Edward Jackson

1578133017

Python Firebase Real Time Database Tutorial with Example

Python Firebase Real Time Database – in this Python article iam going to talk about Python Firebase Real Time Database.

So first of all Firebase is platform which allow to build web and mobile applications without server

side programming language. You can store users data on its real-time database which sync

data among users data in no time.

Firebase is a google product which offers so many useful features. Like

  • 1: Firebase Real Time Database
  • 2: Push Notifications
  • 3: Firebase Authentication_
  • 4: Firebase Cloud Messaging
  • 5: Firebase Test Lab For Android
  • 6: Firebase Crash Reporting_
  • 7: Firebase Notification
  • 8: Firebase App Indexing and many more _

So in this article we are going to use Real Time Database Feature of Firebase.

OK when you want to use Firebase in Python you need to install some packages

pip install requests

pip install python-firebase

So now this is the code for inserting data to Firebase Real Time database

from firebase import firebase


firebase = firebase.FirebaseApplication('URL of Database', None)
data =  { 'Name': 'John Doe',
          'RollNo': 3,
          'Percentage': 70.02
          }
result = firebase.post('/python-example-f6d0b/Students/',data)
print(result)

OK now in this line of code FirebaseApplication takes two parameters; one is URL of database and second is authentication details for database

because for this project we have not set a rule by this reason we have given None in the second parameter.

firebase = firebase.FirebaseApplication('URL of Database', None)

And in this line of code we are going to insert data to our table

result = firebase.post('/python-example-f6d0b/Students/',data)

OK this was for inserting data and now we want to retrieve the data, you can use this code

Retrieving The Data

from firebase import firebase



firebase = firebase.FirebaseApplication('URL of database', None)
result = firebase.get('/python-example-f6d0b/Students/', '')
print(result)

Updating The Data

from firebase import firebase

firebase = firebase.FirebaseApplication('Database URL', None)
firebase.put('/python-example-f6d0b/Students/-LjLUhaWGuxNd5gOEmse','Name','Bob')
print('Record Updated')

Deleting The Data

from firebase import firebase

firebase = firebase.FirebaseApplication('URL Of Database', None)
firebase.delete('/python-example-f6d0b/Students/', '-LjLUhaWGuxNd5gOEmse')
print('Record Deleted')

#python #firebase #databases

What is GEEK

Buddha Community

Python Firebase Real Time Database Tutorial with Example
Ray  Patel

Ray Patel

1619518440

top 30 Python Tips and Tricks for Beginners

Welcome to my Blog , In this article, you are going to learn the top 10 python tips and tricks.

1) swap two numbers.

2) Reversing a string in Python.

3) Create a single string from all the elements in list.

4) Chaining Of Comparison Operators.

5) Print The File Path Of Imported Modules.

6) Return Multiple Values From Functions.

7) Find The Most Frequent Value In A List.

8) Check The Memory Usage Of An Object.

#python #python hacks tricks #python learning tips #python programming tricks #python tips #python tips and tricks #python tips and tricks advanced #python tips and tricks for beginners #python tips tricks and techniques #python tutorial #tips and tricks in python #tips to learn python #top 30 python tips and tricks for beginners

What is firebase,firebase bangla tutorial.

https://youtu.be/8BnVKuf1E5M

#firebase #firebase database #c# with firebase #c# with firebase tutorials #c# with firebase database #asp.net with firebase database

Ray  Patel

Ray Patel

1619510796

Lambda, Map, Filter functions in python

Welcome to my Blog, In this article, we will learn python lambda function, Map function, and filter function.

Lambda function in python: Lambda is a one line anonymous function and lambda takes any number of arguments but can only have one expression and python lambda syntax is

Syntax: x = lambda arguments : expression

Now i will show you some python lambda function examples:

#python #anonymous function python #filter function in python #lambda #lambda python 3 #map python #python filter #python filter lambda #python lambda #python lambda examples #python map

Hal  Sauer

Hal Sauer

1591688078

Python Datetime Tutorial: Manipulate Times, Dates, and Time Spans

Dealing with dates and times in Python can be a hassle. Thankfully, there’s a built-in way of making it easier: the Python datetime module.

datetime helps us identify and process time-related elements like dates, hours, minutes, seconds, days of the week, months, years, etc. It offers various services like managing time zones and daylight savings time. It can work with timestamp data. It can extract the day of the week, day of the month, and other date and time formats from strings.

#data science tutorials #calendar #date #dates #datetime #intermediate #python #time #time series #times #tutorial #tutorials

Create database into firebase

https://youtu.be/u3F3GCdBu08

#firebase #firebase database #c# with firebase #c# with firebase database #c# with firebase tutorials #asp.net with firebase database