PARTITIONED_BY= Data Set Option

Specifies the column name to use as the partition key for creating fact tables.

Valid in: DATA and PROC steps (when accessing DBMS data using SAS/ACCESS software)
Category: Data Set Control
Aliases: PARTITION_BY
PARTITION
Default: none
Data source: Impala

Table of Contents

Syntax

PARTITIONED_BY=(column-name1< ... column-nameN>)

Required Argument

column-name1 <... column-nameN>

specifies the column names that are used to partition the table that is being bulk loaded. Separate multiple values with spaces and include the list in parentheses.

Example: Load a Partitioned Table

This example shows how to load a table that is partitioned by columns Col4 and Col5.

options sastrace=',,,d' sastraceloc=saslog 
   nostsuffix msglevel=i;
data x.partitionsample(partitioned_by=(col4 col5) dbtype=(col4='int' col5='int') );
col1=1;
col2='This is a test';
col3='*********0*********';
col4=1;
col5=10;
run;
IMPALA_2: Executed: on connection 2
CREATE TABLE `default `.`partitionsample` (`col1` double,`col2` VARCHAR(14),
   `col3` VARCHAR(19)) PARTITIONED BY (`col4` int,`col5` int)

IMPALA_3: Prepared: on connection 2
SELECT * FROM `default`.`partitionsample`

IMPALA_4: Prepared: on connection 2
INSERT INTO `default`.`partitionsample` (`col1`,`col2`,`col3`,`col4`,
   `col5`) VALUES ( ? , ?, ? , ? , ? )

IMPALA_5: Executed: on connection 2
Prepared statement IMPALA_4
Last updated: February 3, 2026