Latest Blog Articles

Allow remote connections to PostgreSQL

Allow remote connections to PostgreSQL

Working with the PostgreSQL in server is fine. But, sometimes we need to access the server or cloud database from our local machine. But, when we try to connect to the PostgresSQL server database from local it will not connect. Because, by the default configuration PostgreSQL only allows host "lo...

Read more

serializers in Django Rest Framework

serializers in Django Rest Framework

Serializers in django rest framework are similar to django forms. By using django rest framework serializers we can serialize and deserialize the data. We can also validate the incoming data using django rest framework serializers to maintain the integrity of the data. We can divide the django re...

Read more

how to add swap memory in ubuntu

how to add swap memory in ubuntu

In every computer we have a physical memory(i.e: RAM). When a user starts a program it is loaded from the disk (where the program resides) to the RAM, because RAM is faster than the disk memory. Some processes intially need more memory to startup but after it will not use the complete memory that...

Read more

working with supervisor on ubuntu

working with supervisor on ubuntu

In most of the ubuntu virtual private servers it is often case that we will have to run several small programs continuously. The most traditional way to do it is to write a init script in for the program that we want to run continuously. But it is a time consuming process to manage it.

Supervi...

Read more

how to use templates in django

how to use templates in django

Django is a webframework so, It needs to maintain the code in such a way that it should be easy to navigate and easy to read and maintain. As we already know the Django framework is a MVC, we do not write the HTML code in the views.py instead we write it in a template. In django web fra...

Read more

usage of group_by and string_agg in django, postgreSQL

usage of group_by and string_agg in django, postgreSQL

In this article we are going to learn how to optimize the queries in Django applications. Django has a built-in ORM which converts the django query into optimized SQL query. In some cases we need to group the data based on some common django field or a table column. This can also be done without ...

Read more

Introduction to RESTful api's

Introduction to RESTful api's

REST(Representational state transfer) is a one of the architectural(designed with some specific rules and regulations) ways to transfer the data by using the HTTP protocol. In this article we will learn what are the restful api's and why we use it.we'll understand api request format and...

Read more

getting started with django first app

getting started with django first app

Let's get started with our very first django application. I always recommend newbies to use the latest versions of django and python. Python2.X.X has no active support. We generally develop many projects on a single machine with different requirements(python packages). If we install python packag...

Read more

working with for loop in python

working with for loop in python

Let's start working with for loop in python. For loop is used when want to execute a block of code repeatedly a fixed number of times.  Python also comes with the support of iterating the sequences using the for loop. we can use any number of for loops one inside another. we call it as neste...

Read more

Working with if ... elif ... else conditions in python

Working with if ... elif ... else conditions in python

Lets start working withif ... elif .. else conditions in python. "if ... elif .. else" allow us to take decisions. It can be nested. In some cases we may need to execute the code based on conditions. Then we use "if ... elif ... else" conditions in python. For example, if we wan to sor...

Read more

understanding the request-response lifecycle in Django

understanding the request-response lifecycle in Django

Let's start understanding  the  request-response lifecycle of a Django application. Every web application uses HTTP/HTTPS protocol. In the HTTP/HTTPS protocol client sends a request to the server based on the request data server sends the response back to the client. It's the basic...

Read more

custom path converters in django

custom path converters in django

In django version 2.0  introduced new way to write url patterns using "path". In django 2.0 regular expression type "url" is removed and added 2 things to work with urls. 1. using "path" and 2. using "re_path". For writing the clean urls django provided the path converters. It helps us to wr...

Read more

working with xls and xlsx files in python

working with xls and xlsx files in python

Let's start working with xls and xlsx files in python. We can read data from xls or xlsx files using python programming and we can also write to xls or xlsx files using python programming. We do this by using the python package "openpyxl".  The package "openpyxl" can be found in Python Packa...

Read more
Read More Blog Posts