Use the delete_data_source() method to remove the archived data source from the repository.
Required Parameter
- data_source
- Specifies either the name of the data source or object of the data source to remove from the repository.
Example setup
>>> from teradataml import DataFrame, DataSource, FeatureStore, load_example_data
Create teradataml DataFrame.
>>> load_example_data('dataframe', ['sales'])
>>> df = DataFrame("sales")
Create FeatureStore for repo 'vfs_v1'.
>>> fs = FeatureStore("vfs_v1")
Repo vfs_v1 does not exist. Run FeatureStore.setup() to create the repo and setup FeatureStore.
Set up FeatureStore for this repository.
>>> fs.setup()
True
Example: Delete the data source from the repository
Create a data source with source as teradataml DataFrame.
>>> ds = DataSource(name="sales_data", source=df)
Apply the data source to FeatureStore.
>>> fs.apply(ds)
True
Archive the data source.
>>> fs.archive_data_source("sales_data")
DataSource 'sales_data' is archived. True
Delete the data source with the name "sales_data".
>>> fs.delete_data_source("sales_data")
DataSource 'sales_data' is deleted. True
List the available data sources after delete.
>>> fs.list_data_sources()
Empty DataFrame Columns: [description, timestamp_column, source, creation_time, modified_time] Index: []