-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #284 from dyvenia/dev
Release 0.3.0
- Loading branch information
Showing
57 changed files
with
2,193 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -150,3 +150,6 @@ config.toml | |
desktop.ini | ||
|
||
.viminfo | ||
|
||
# SAP RFC lib | ||
sap_netweaver_rfc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# How to pull excel file from Sharepoint | ||
|
||
With Viadot you can download Excel file from Sharepoint and then upload it to Azure Data Lake. You can set a URL to file on Sharepoint an specify parameters such as path to local Excel file, number of rows and sheet number to be extracted. | ||
|
||
## Pull data from Sharepoint and save output as a csv file on Azure Data Lake | ||
|
||
To pull Excel file from Sharepint we create flow basing on `SharepointToADLS` | ||
:::viadot.flows.SharepointToADLS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import os | ||
|
||
from viadot.config import local_config | ||
|
||
try: | ||
import pyrfc | ||
except ModuleNotFoundError: | ||
raise | ||
|
||
from viadot.flows import SAPToDuckDB | ||
|
||
sap_test_creds = local_config.get("SAP").get("TEST") | ||
duckdb_creds = {"database": "test1.duckdb"} | ||
|
||
|
||
def test_sap_to_duckdb(): | ||
flow = SAPToDuckDB( | ||
name="SAPToDuckDB flow test", | ||
query=""" | ||
select | ||
,CLIENT as client | ||
,KNUMV as number_of_the_document_condition | ||
,KPOSN as condition_item_number | ||
,STUNR as step_number | ||
,KAPPL as application | ||
from PRCD_ELEMENTS | ||
where KNUMV = '2003393196' | ||
and KPOSN = '000001' | ||
or STUNR = '570' | ||
and CLIENT = '009' | ||
limit 3 | ||
""", | ||
schema="main", | ||
table="test", | ||
local_file_path="local.parquet", | ||
table_if_exists="replace", | ||
sap_credentials=sap_test_creds, | ||
duckdb_credentials=duckdb_creds, | ||
) | ||
|
||
result = flow.run() | ||
assert result.is_successful() | ||
|
||
task_results = result.result.values() | ||
assert all([task_result.is_successful() for task_result in task_results]) | ||
|
||
os.remove("test1.duckdb") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.