BookmarkSubscribeRSS Feed
sasg
Calcite | Level 5

Hi All,

 

I have a sas data set,which will update with different column names everymonth.I have to create teradata table from this dataset.How can i define the structure of the table based on SAS dataset(how to choose index variable etc) it is a huge dataset??

 

Ex: dataset april month:

 

PRSN_ID exp1 exp2 exp3

     .           1        0      1

    111       2        3       1

 

dataset May month

 

Name  exp2 db008 behaviour

rxt         1       2        good

tuv         0       1        notbad

5 REPLIES 5
Quentin
Super User

So is it the case that every month you are getting a new dataset that has no relationship to the previous month's dataset? 

 

Do you want to load the May data into Teradata and and replace the April table in Teradata?

 

If you get a new dataset every month, with different column names, you would probably need to ask the provider to also provide information on keys/indexes when they deliver the data. 

 

You can of course add your own GUID, or every month look through variables to see if you can find set of variables that would be reasonable candidates to use as an index, but that wouldn't seem very useful.

 

I'm perplexed by the big picture.  The idea of a "dynamic table" where columns change every month does not seem very useful to me. 

BASUG is hosting free webinars Next up: Don Henderson presenting on using hash functions (not hash tables!) to segment data on June 12. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
sasg
Calcite | Level 5

it is very huge data with 115 columns,finding solution how to load this data in the database automatically. this table is the input for 10 other processes.

Quentin
Super User
So could your question be simplified to "How do I load a SAS dataset into Teradata?"
BASUG is hosting free webinars Next up: Don Henderson presenting on using hash functions (not hash tables!) to segment data on June 12. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
sasg
Calcite | Level 5

yes,based on proc datasets output i want to read the column names and datatypes and pass it to create table statement.

Quentin
Super User
If you show some sample data and the create table statement that you would want to generate for that data, it might make it easier for folks to help you.
BASUG is hosting free webinars Next up: Don Henderson presenting on using hash functions (not hash tables!) to segment data on June 12. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 5 replies
  • 1286 views
  • 0 likes
  • 2 in conversation