Monday, July 18, 2016

Some new logic

Hi Guys daily i am  facing different kind of issues some of them is below listed..


Q:-Is is possible to get the previous month end date in Informatica? It would need to be MMDDYYYY 

A:-select sysdate , to_char(last_day(ADD_MONTHS(SYSDATE, -1)),'MMDDYYYY') Prev_Month_LastDay from dual;

Q> select to_char(sysdate,'Q') from dual;
A:- quaters

SQL> Select trunc(sysdate,'yyyy') from dual ;

TRUNC(SYS
---------
01-JAN-16

SQL> Select to_char(last_day(add_months(trunc(sysdate,'yyyy'),level-1)),'dd') from dual connect by level<=12;

TO
--
31
29
31
30
31
30
31
31
30
31
30
31

12 rows selected.

SQL> SELECT * FROM A;

A
--------------------
135.00000000
234.88889000
1246.1111456

   
SQL> SELECT TO_CHAR(A, '99999D99') FROM A;

TO_CHAR(A
---------
   135.00
   234.89

  1246.11

Data engineering Interview Questions

1)  What all challenges you have faced and how did you overcome from it? Ans:- Challenges Faced and Overcome As a hypothetical Spark develop...