Example: A 10   Results of RPAD with first parameter as integer, 2, and 3 parameters
SELECT char(rpad(927,12, *. ),50) FROM SYSIBM.SYSDUMMY1;
                                                   
1                                                  
                                                   
927*.*.*.*.*                                       
    1 record(s) selected.
                                                                          
SELECT char(rpad(927,12,  ) ||  X ,50) FROM SYSIBM.SYSDUMMY1;
                                                   
1                                                  
                                                   
927         X                                      
    1 record(s) selected.
                                                                          
SELECT char(rpad(9021,3),20) FROM SYSIBM.SYSDUMMY1;
                                                   
1                    
                     
902                  
    1 record(s) selected.
The counterpart for RPAD are the LPAD functions, which are shown in 
Example A 11.
Example: A 11   LPAD: CREATE FUNCTION and sample usage
CREATE FUNCTION LPAD (C1 VarChar(4000), N integer, C2 VarChar(4000))
 RETURNS VARCHAR(4000)
 LANGUAGE SQL
 SPECIFIC LPADBase
 DETERMINISTIC
 CONTAINS SQL
 NO EXTERNAL ACTION
 RETURN 
 CASE
342 
MySQL to DB2 UDB Conversion Guide






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

san diego web hosting

 

Our partners: PHP: Hypertext Preprocessor Cheap Web Hosting JSP Web Hosting Ontario Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Java Hosting Cheapest Hosting

Visionwebhosting.net Business web hosting division of Vision Web Hosting Inc.. All rights reserved