Dear All,
I have a string variable and I want to divide it into three parts. Here's the example.


Code:
clear
input str50 nic_code
"Division 43 Specialized construction activities"
"Division 49 Land transport and transport via pipelines"
"Division 69 Legal and accounting activities"
"Group 421 Construction of roads and railways"
"Group 451 Sale of motor vehicles"
"Group 461 Wholesale on a fee or contract basis"
"Group 432 Electrical, plumbing and other construction installation activities"
"Section A Agriculture, forestry and fishing"
"Section B Mining and quarrying"
"Section C Manufacturing"
end
I want to divide the above strings to three parts such as:

Code:
clear
input str10 x1 str4 x2 str50 x3
"Division" "43" "Specialized construction activities"
"Division" "69" "Legal and accounting activities"
"Group" "421" "Construction of roads and railways"
"Section" "A" "Agriculture, forestry and fishing"
end
and so on.

Any help will be greatly appriciated.