Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

1 new york 7,262,700
2 los angeles 3,259,340
3 philadelphia 1,642,900

how to read the above data using input statement
consider the above data is in txt format externally
u have to use infile and input statement.

Answer Posted / chandrakanth

To Solasa and others ....whenever you read data from an input file...you need to be careful about the last data value in every dataline you have values like x,xxx,xxx which is total width of 9, when you mention more than 9 the input pointer will go the next data line to get the remaining spaces. So in your code you used comma10. try with using comma9. I am very sure it will work.

Another option is if you want to keep that comma10. use TRUNCOVER in the infile statement, this should fix all the extra spaces you mention in the input statement.

let me know if this does not help you

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the purpose of trailing @ and @@? How do you use them?

1011


What is a pdv and what are its functions?

1096


why is a stop statement needed for the point=option on a set statement? : Sas programming

1055


In proc transpose and data step with arrays which one you pick?

3079


Differentiate between sas functions and sas procedures.

1186


Have you ever used the SAS Debugger?

1722


hi all, I need the SAS DI DUMP(A00 260) for attending the certification. if any one have, pls provide it.Please Email to vrpotluri@hotmail.com. Thanks - Ramana

5413


What are the different operating system platforms in which we can use sas? : sas-grid-administration

1033


What is substr function?

1138


What does the trace option do?

1080


Name types of category in which SAS Informats are placed?

1125


What is PROC in SAS?

1028


How are numeric and character missing values represented internally?

1632


describe about physical data integration? : Sas-di

1018


What is the difference between %put and symbolgen? : sas-macro

1201