Here you can find the source of NVLn(String str, String replace)
Parameter | Description |
---|---|
str | a parameter |
replace | a parameter |
public static String NVLn(String str, String replace)
//package com.java2s; //License from project: Apache License public class Main { /**//from w ww.j a v a 2 s . c om * NVLn - fix null value (numeric) * @param str * @param replace * @return */ public static String NVLn(String str, String replace) { return NVL(str, replace); } /** * NVLn - fix null value (numeric) * @param str * @return */ public static String NVLn(String str) { return NVL(str, "null"); } /** * NVL - fix null value * @param String value * @param replace with * @return */ public static String NVL(String str, String replace) { if (str == null || str.trim().equals("") || str.trim().toUpperCase().equals("NULL")) return replace; return str; } /** * NVL - fix null value * @param string value * @return */ public static String NVL(String str) { return NVL(str, ""); } }