I have imports as the following:
from pyspark.sql.functions import *
Within these there is a filter function in PySpark. How do I use the python filter function instead. Is the only way to import from PySpark the functions I require?
I have imports as the following:
from pyspark.sql.functions import *
Within these there is a filter function in PySpark. How do I use the python filter function instead. Is the only way to import from PySpark the functions I require?
import pyspark.sql.functions as pyr
then just use pyr.filter() to use pyspark filter and filter() to use python builtin
In general it's better to not use '' from .. import * '' because you're losing informations about which library you're using function from, making your code less clear even thought smaller