Skip to content

Commit

Permalink
🎨 Changed to map and added super() in to_df method
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafalz13 authored and trymzet committed Oct 4, 2024
1 parent 735311d commit c74367f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/viadot/sources/azure_sql.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def to_df(
remove_special_characters. If None whole data frame will be processed.
Defaults to None.
"""
df = self.to_df(query=query, if_empty=if_empty)
df = super().to_df(query=query, if_empty=if_empty)

if convert_bytes:
df = df_converts_bytes_to_int(df=df)
Expand Down
2 changes: 1 addition & 1 deletion src/viadot/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -973,7 +973,7 @@ def df_converts_bytes_to_int(df: pd.DataFrame) -> pd.DataFrame:
Returns:
pd.DataFrame: Data Frame after convert
"""
return df.applymap(lambda x: int(x) if isinstance(x, bytes) else x)
return df.map(lambda x: int(x) if isinstance(x, bytes) else x)


def df_clean_column(
Expand Down

0 comments on commit c74367f

Please sign in to comment.