Hi,
I have a need to dynamically create a database table based on a CSV file being imported. I am clear with reading the CSV file, processing the header for column names, etc., but I am unsure how to create the table in this scenario.
Clearly, SQL like 'CREATE TABLE XXXDTALIB.TestTable ( Data1 nvarchar(1000), Data2 nvarchar(1000), Data3 nvarchar(1000) );' would work as SQL, but I am wondering how would I execute this from within a LANSA once I've built the string in question?
Thanks.
Executing SQL - CREATE TABLE
Re: Executing SQL - CREATE TABLE
You could use the create table in a select_sql command , like these:
viewtopic.php?f=3&t=2595&p=7678&hilit=S ... _dql#p7803
viewtopic.php?f=3&t=2595&p=7678&hilit=S ... _dql#p7803