Example setup: Import and load modules
>>> from teradataml import * >>> from teradatagenai import load_data
Example 1: When connection is created without "temp_database_name", the table is loaded in users' default database
>>> con = create_context(host = 'tdhost', username='tduser', password = 'tdpassword')
>>> load_data('employee', 'employee_data')
Create a teradataml DataFrame:
>>> df = DataFrame("employee_data")
Example 2: When connection is created with "temp_database_name" parameter and configuration option "temp_table_database" is also specified, the table is created in the database specified in the configuration option
>>> con = create_context(host = 'tdhost', username='tduser', password = 'tdpassword',
temp_database_name = "temp_db")
>>> configure.temp_table_database = "temp_db1"
>>> load_data('employee', 'employee_data')
Create a teradataml DataFrame.
>>> df = DataFrame(in_schema("temp_db1", "employee_data"))