17.10 - Example: Querying Input Argument 23 with the ROTATERIGHT Function - Advanced SQL Engine - Teradata Database

Teradata Vantageā„¢ - SQL Functions, Expressions, and Predicates

Advanced SQL Engine
Teradata Database
Release Number
Release Date
July 2021
Content Type
Programming Reference
Publication ID
English (United States)

The following query takes the input argument 23, which has a data type of BYTEINT and a binary representation of 00010111, and sets the value of the third bit to 0. The query result is a BYTEINT value of 19 or binary 00010011.

   SELECT SETBIT(23,2,0);