Javaメソッドの実装 - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - SQL外部ルーチン プログラミング

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Published
2021年7月
Language
日本語
Last Update
2021-09-23
dita:mapPath
ja-JP/rin1593638965306.ditamap
dita:ditavalPath
ja-JP/wrg1590696035526.ditaval
dita:id
B035-1147
Product Category
Software
Teradata Vantage
public class UDFExample {
   public static Integer fact( Integer x ) {
      if (x == null)
         return null;
      int x_t = x.intValue();
      if (x_t < 0)
         return new Integer(0);
      int factResult = 1;
      while (x_t > 1) {
         factResult = factResult * x_t;
         x_t = x_t - 1;
      }
      return new Integer(factResult);
   }
}