بتاريخ: 1 مايو 200818 سنة comment_127824 create or replace procedure search_in_data(w_owner varchar2,w_name varchar2) is w_cnt number; w_select varchar2(300); begin -- this procedure to serch in varchar items in all tables -- and output the table name and the column name -- you must wright the following order on the sql screen -- ------------------- -- set serveroutput on -- ------------------- for i in (select table_name,column_name from sys.dba_tab_columns where owner = upper(w_owner) and data_type = 'VARCHAR2' order by table_name,column_name) loop if length(i.table_name) <= 28 then w_select := 'select count(*) from '||w_owner||'.'||i.table_name|| ' where '||upper(i.column_name)||' like '||''''||'%'||w_Name||'%'||'''' ; execute immediate w_select into w_cnt; if w_cnt > 0 then DBMS_OUTPUT.put_line (i.table_name||'-'||i.column_name); end if; end if; end loop; ---------------------- -- [email protected] ---------------------- end search_in_data; / تقديم بلاغ
بتاريخ: 21 يونيو 200818 سنة comment_131705 THANK YOU FOR YOUR GREAT EFFORT تم تعديل 21 يونيو 200818 سنة بواسطة mohamed fathei تقديم بلاغ
بتاريخ: 24 يونيو 200818 سنة comment_131894 أشكرك على المجهود الرائع ، و لكن أين سأضع الكود في الفورم بلدر و لا البروسيدر بلدر تقديم بلاغ
بتاريخ: 12 ديسمبر 200817 سنة comment_144667 ياريت تحط لنا كود البحث الي بيبحث عن السجلات الي تبدى بنفس الحرف create or replace procedure search_in_data(w_owner varchar2,w_name varchar2) is w_cnt number; w_select varchar2(300); begin -- this procedure to serch in varchar items in all tables -- and output the table name and the column name -- you must wright the following order on the sql screen -- ------------------- -- set serveroutput on -- ------------------- for i in (select table_name,column_name from sys.dba_tab_columns where owner = upper(w_owner) and data_type = 'VARCHAR2' order by table_name,column_name) loop if length(i.table_name) <= 28 then w_select := 'select count(*) from '||w_owner||'.'||i.table_name|| ' where '||upper(i.column_name)||' like '||''''||'%'||w_Name||'%'||'''' ; execute immediate w_select into w_cnt; if w_cnt > 0 then DBMS_OUTPUT.put_line (i.table_name||'-'||i.column_name); end if; end if; end loop; ---------------------- -- [email protected] ---------------------- end search_in_data; / تقديم بلاغ
بتاريخ: 12 ديسمبر 200817 سنة comment_144672 السلام عليكم ورحمة الله وبركاتهالله يعطيك العافية على هذا Procedure الرائع و أتمنى لك التفيق والنجاح دائما ، لكن لم أجرب الكود ، و أشكرك جزيل الشكر على هذا الجهد الممتاز. تقديم بلاغ
انضم إلى المناقشة
يمكنك المشاركة الآن والتسجيل لاحقاً. إذا كان لديك حساب, سجل دخولك الآن لتقوم بالمشاركة من خلال حسابك.