ابدأ بالتواصل مع الأشخاص وتبادل معارفك المهنية

أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.

متابعة

Write a query to display all days in the current year starting from 1-Jan to 31-Dec. The query should display 365 records for one column named Day

user-image
تم إضافة السؤال من قبل Sameh Mohamed Aly Sewilam , Oracle Technical Team Leader , National Technology
تاريخ النشر: 2014/08/21
Gaith Amer Yousef  Rammaha
من قبل Gaith Amer Yousef Rammaha , Sr. Oracle developer and Project Manager , Technology village information system TVIS

CREATE OR REPLACE PROCEDURE user.getday ISV_START_DATE date;V_END_DATE date;V_DAY varchar2(50);V_SUM_DATE number;begin select to_date('','dd-mm-yyyy') into V_Start_DATE From dual; select to_date('','dd-mm-yyyy') into V_END_DATE From dual; V_SUM_DATE := V_END_DATE - V_START_DATE +1; FOR i in1..V_SUM_DATE loopV_DAY := to_char(to_date(V_Start_DATE,'dd-mm-yyyy'),'DAY') ;insert into user.days(DAY) values(V_DAY);commit;V_START_DATE := V_START_DATE +1; END LOOP; end;

ADIL MUSTAFA
من قبل ADIL MUSTAFA , Senior System Engineer , Infosys Limited

select to_char(to_date('1/1/','mm/dd/yyyy') + level -1,'DAY') from dual connect by level <=;

Mohammad Aman
من قبل Mohammad Aman , Web Developer , IHCC

SELECT*FROM tablename WHERE columname BETWEEN':00:00'AND':59:59'easy!

المزيد من الأسئلة المماثلة