Page 39 - SAS_manual
P. 39

Purpose:                              Syntax
                                                                                 translate(string,"tostring","from
                   TRANSLATE            used to replace charcter in given string           string");
                                        used to replace set of charcter in given   tranwrd(string,"fromstring","to
                    TRANWRD                            string                              string")
                                        used to find position of first occurance of
                                         given string taking it as part of word or
                      INDEX                        separate word                  INDEX(source,"part string")
                                        used to find position of first occurance of
                     INDEXw             given string taking it as separate of word   INDEX(source,"complete string")
                                        used to find position of first occurance of
                                       given string taking each character of it as
                      INDEXc                       individual value             INDEX(source,"individual string")

               Program 4.13:





















               Output:










               4.3 Date and Time function


               How to store date values:
                SAS can read dates in almost any form, such as the following:


               Date Description


                                                    SAS HANDBOOK | VISIT:: http://nikhilanalytics.com  39
   34   35   36   37   38   39   40   41   42   43   44