With the use command
Sometimes the datasets that you need to access may have too many variables for the edition of Stata that you have purchased. This often results in people calling us and wanting to upgrade their Stata from IC to SE or SE to MP. While we welcome the additional sale, there is a way that Stata allows you to only use the variables that you need from a dataset instead of bringing the entire dataset into Stata. This is often the case with the HILDA dataset.
Stata/IC can have a maximum of 2,048 variables in any one dataset, and while 2048 variables seems like a lot, apparently that is still not enough to hold the entire HILDA dataset. HILDA is such a big dataset because it is a longitudinal dataset with all the variables stored for each year for each of the observations, and so when you have 300 variables each year, as soon as you have more than 7 years of data you are now dealing with more variables than Stata IC can handle. BUT DO NOT FEAR!. When you download the HILDA dataset as a Stata .dta file you can use the Stata command:
use [varlist] [if] [in] using filename
This allows you to bring in just the variables you want. Learn more on this at this TechTip.