Help in initializing variable with spaces in SAS.

Statistical Analysis System and Cloud Computing.
Post Reply
vkpani
New Member
Posts: 2
Joined: Tue Nov 25, 2014 5:18 pm

Help in initializing variable with spaces in SAS.

Post by vkpani »

Hi,

Can anyone of you please help me to initialize the variable with spaces in SAS?

Say, for example, I have a variable declared as SE1 = ' ',

Now SE1 is declared with only one space. But I want to initialise with more spaces. How can I do that?

Thanks in advance.
User avatar
Robert Sample
Global Moderator
Global Moderator
Posts: 1891
Joined: Fri Jun 28, 2013 1:22 am
Location: Dubuque Iowa
United States of America

Re: Help in initializing variable with spaces in SAS.

Post by Robert Sample »

You could use

Code: Select all

SE1 = '     ';
(that is, put more than one space between the quote marks). Or you can use the REPEAT function to specify how many spaces you want SE1 to have.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “SAS & Cloud Computing.”