Archivo mensual: mayo 2019

Generating Dates between two date ranges Oracle

select to_char(trunc(to_date(20190822,’YYYYMMDD’),’MM’),’YYYYMMDD’)-1 + level as Date1,to_char(to_date(to_char(trunc(to_date(20190822,’YYYYMMDD’),’MM’),’YYYYMMDD’),’YYYYMMDD’)-2 + level,’YYYYMMDD’) as Date2 from dual connect by level <= to_char(last_day(to_date(20190822,’YYYYMMDD’)),’DD’) order by Date1;

Publicado en DataBase, Oracle Data Base | Etiquetado , , | Deja un comentario

Oracle SQL with carriage return

create table rc as select ‘ABC</>DEF FF</>ZZZ’ rc from dual; select * from rc; WITH RETURN_LINE AS ( SELECT rc FROM rc ) SELECT trim(regexp_substr(rc, ‘[^]+’, 1, LEVEL)) rc FROM RETURN_LINE CONNECT BY instr(rc, », 1, LEVEL – 1) > … Sigue leyendo

Publicado en DataBase, Oracle Data Base | Etiquetado , | Deja un comentario

Oracle Segmentation 9i

Oracle9i 9.2.0.6.0 – 64bit Production Execute this query WITH T AS ( SELECT ‘/20/’ TXT FROM DUAL UNION SELECT ‘/20/21/’ TXT FROM DUAL UNION SELECT ‘/20/22/’ TXT FROM DUAL UNION SELECT ‘/20/23/24/’ TXT FROM DUAL UNION SELECT ‘/20/23/25/’ TXT FROM … Sigue leyendo

Publicado en DataBase, Oracle Data Base | Etiquetado , , | Deja un comentario

Oracle Heterogeneous Services conectar MySQL ODBC

1) Configura Heterogeneous Services, creamos un archivo llamdo initChocMySQL y le agregamos estos parámetros: Nombre el Archivo: initChocMySQL.oraHS_FDS_CONNECT_INFO = ChocMySQLHS_FDS_TRACE_LEVEL = OFF 2) configurar listener.ora agregar el siguiente parametro a SID_LIST_LISTENER (SID_DESC = (SID_NAME = ChocMySQL) (ORACLE_HOME = C:\oraclexe\app\oracle\product\11.2.0\server) (PROGRAM=dg4odbc) … Sigue leyendo

Publicado en DataBase, DBMS, Diversidad, Oracle Data Base | Etiquetado , , , , , | 1 comentario