Introduction In this tutorial I am going to show you how to use Python client to work with Apache kafka distributed stream processing system. I will create Kafka producer and consumer examples using Python language. KafkaConsumer is a high-level message consumer that consumes records from a kafka cluster. The consumer is not thread safe and…

Posted in Kafka Python

Python Client for Apache Kafka Producer and Consumer

Introduction We are going to show you how to extract text from PDF file and convert them into audio speech using Google gTTS API. gTTS (Google Text-to-Speech), a Python library and CLI tool to interface with Google Translate’s text-to-speech API. Write spoken mp3 data to a file, a file-like object (bytestring) for further audio manipulation,…

Posted in Python

Convert PDF File Text to Audio Speech using Python and Google gTTS API

Introduction We will create an example using Python programming language how to extract text from PDF file. In this example we are going to use PyPDF2 package from Python to work with PDF file.

Posted in Python

Extract Text from PDF File using Python

Introduction This example will show you how to insert CSV data into MySQL database table directly. So I am going to create insert SQL statement for inserting data individually or I will also load the csv data directly into the MySQL table. CSV means Comma Separated Value, so it’s a plain text data. Each line…

Posted in MySQL Python

How to insert CSV data into MySQL database using Python in different ways

Here we will see how to connect to MySQL database server using Python in different ways. We need to install mysql-connector-python module to connect to MySQL database from Python programming language. We will create the connection objects in different ways and using this connection object we will be able to connect to MySQL server.

Posted in MySQL Python

How to connect to MySQL database using Python in different ways

In this example you are going to see how you can convert XML data into CSV data. XML is an Extensible Markup Language and CSV is Comma Separated Values. In this example I am going to read both XML file and XML string and show you how to display the converted csv string data in…

Posted in Python

How to convert XML to CSV using Python

Introduction Here I am going to create an example on how to convert CSV to XML. CSV means Comma Separated Value. So the sources of these values may be different. These values may be put into a file or in a string. XML is an Extensible Markup Language that defines a set of rules for…

Posted in Python

How to convert CSV to XML using Python

Introduction In this example I am going to show you how to read CSV file or string using Python programming language. You may come across a situation where you need to read CSV string or CSV file and manipulated data for any further business process. CSV means Comma Separated Values and the source of these…

Posted in Python

How to read CSV file or string using Python

In this tutorial we build an application using Python based Flask framework to fetch all products from MySQL database and display on the HTML table. This example is all about to delete multiple rows from HTML as well as database tables. We will use IN clause with WHERE condition in MySQL query to delete multiple…

Posted in AJAX Flask jQuery MySQL Python

Delete Multiple Rows from Table using Flask, AJAX, jQuery, MySQL

Introduction In this tutorial I will show you how to upload image and display on the web page once it is uploaded successfully. I have seen few tutorials on file uploads using Python Flask API but here I will show you how to allow users upload image file and display it on the browser once…

Posted in File Upload Flask Python

Upload and display image using Python Flask

Introduction In this example we will see how to build fibonacci series using Python programming language. We will create both recursive and non-recursive function in Python programming language to build the fibonacci series. In mathematics, the Fibonacci numbers, commonly denoted Fₙ, form a sequence, called the Fibonacci sequence, such that each number is the sum…

Posted in Python

Fibonacci Series using Python

Introduction In this post we will see how to create voting or rating system using Flask, MySQL and AJAX. We post tutorials, articles or blogs either on our own blog site or as a guest user to other sites. Sometimes we need to let user rate on our tutorials or articles or blogs so that…

Posted in AJAX Flask jQuery MySQL

jQuery AJAX based Voting or Rating System using Flask and MySQL