Search notes:

SAS: data step - merge join

data tq84_a;
   length txt $20;
   input  val txt;
datalines;
7 seven
9 nine
22 twenty-two
run;

data tq84_b;
   length txt $20;
   input  val txt;
datalines;
2 two
8 eight
13 thirteen
31 thirty-one
42 forty-two
run;

data tq84_a_b_merged;
   set tq84_a tq84_b;
/*
   In order to merge two data sets with "by", the
   two data sets need already to be sorted on the
   variable on which the merge takes place:
*/
   by  val;
run;
Github repository about-SAS, path: /programming/data-sets/merge-join.sas

See also

data step

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/Companie...', 1759408129, '216.73.216.42', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/Companies-Products/SAS/programming/data-step/merge-join(66): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78