Teradata Package for LangChain Function Reference - delete_datasets - Teradata® Package for LangChain - Look here for syntax, methods and examples for the functions included in the Teradata langchain-teradata package.

Teradata® Package for LangChain Function Reference

Deployment
VantageCloud
Edition
Enterprise
Product
Teradata® Package for LangChain
Release Number
20.00.00.01
Published
December 2025
ft:locale
en-US
ft:lastEdition
2025-12-19
dita:id
Langchain-Teradata_FxRef_Lake
Product Category
Teradata Vantage
libs.teradata.langchain_teradata.TeradataVectorStore.delete_datasets = delete_datasets(self, data, **kwargs)
DESCRIPTION:
    Deletes the specified dataset(s) from the an existing content-based vector store.
 
PARAMETERS:
    data:
        Required Argument.
        Specifies the name of the tables or teradataml DataFrames to be deleted from the VectorStore.
        Types: str, DataFrame, or list of str/DataFrame
 
    database_name:
        Optional Argument.
        Specifies the database name where the input table(s) or DataFrame(s) are located.
        Note: If not specified, all input data with the table name of "data" is deleted 
              from the Vector Store irrespective of the database in which it is located.
        Types: str
 
    update_style:
        Optional Argument.
        Specifies the style to be used for alter operation of the data
        from the vector store when "search_algorithm" is KMEANS/HNSW.
        Default Value: MINOR
        Permitted Values: MINOR, MAJOR
        Types: str
 
RETURNS:
    None
 
RAISES:
    TeradataMlException
 
EXAMPLES:
    # Create an instance of an 'content-based' vector store by passing the 'amazon_reviews_25' table.
    # Note:
    #   This is optional and can be skipped if the vector store is already created.
    >>> from langchain_teradata import TeradataVectorStore
    >>> from teradataml import DataFrame, copy_to_sql
    >>> from teradatagenai import load_data
    >>> load_data("byom", "amazon_reviews_25")       
    >>> amazon_reviews_25 = DataFrame('amazon_reviews_25')
    >>> amazon_reviews_10 = load_data("byom", "amazon_reviews_10")
    >>> vs_instance1 = TeradataVectorStore.from_datasets(name = "vs_example_1",
                                                         data = [amazon_reviews_25, amazon_reviews_10],
                                                         key_columns = ["rev_id", "aid"],
                                                         data_columns = ["rev_text"],
                                                         embedding = "amazon.titan-embed-text-v1")
    # Delete data from an existing content-based vector store "vs_example_1"
    >>> vs_instance1.delete_datasets(data=amazon_reviews_10)