الانتقال إلى المحتوى
View in the app

A better way to browse. Learn more.

مجموعة مستخدمي أوراكل العربية

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

تنفيذ جملة Sql على اكثر من User

Featured Replies

بتاريخ:

السلام عليكم

لدي اكثر من 20 database users والجميع يحنوي على نفس الجداول

سؤالي هو : إذا كان لدي جملة sql مثل ater table ?? add ?? number(1) واريد تنفيذها على جميع ال users بدون ما ادخل عليهم واحد واحد كيف؟

مع الشكر الجزيل

بتاريخ:

Generate Script as SQL ouput then save it to SQL file then run @ sql* ..that's all

بتاريخ:
  • كاتب الموضوع

شكرا للرد لكن ليس هذا ما اريد اريد وانا على احد users انفذ ال script تتنفذ على جميع ال users الاخرين

بتاريخ:

send the query

بتاريخ:

.

تم تعديل بواسطة Darwiesh.fci

بتاريخ:

use this







begin
for i in (select * from DBA_users) loop
-- DBMS_OUTPUT.PUT_LINE('UserName : '|| i.USERNAME);
for obj in (SELECT owner, table_name FROM all_tables where upper(owner)= upper( i.USERNAME)) loop
-- DBMS_OUTPUT.PUT_LINE(' tablename : '|| obj.table_name);
begin
execute immediate 'alter table '||i.USERNAME||'.'||obj.table_name ||' add colname (number(10))'
exception
when others then
null;--or what ever
end ;
end loop;
end loop;
end loop;




و علي كل حال شكرا علي حسن الرد

  • بعد 1 شهر...
بتاريخ:

اخي الكريم طبق الجمله التاليه وانشاء الله تشتغل:
alter table scott.t add id number;
alter table hr.t add id number;
alter table username.t add id number;
alter table username.t add id number;
.
.
.
ادخل على system ونفذ السابق اخذ copy كل الجمل ثم الصقهن في sql
وتحياتي ...

انضم إلى المناقشة

يمكنك المشاركة الآن والتسجيل لاحقاً. إذا كان لديك حساب, سجل دخولك الآن لتقوم بالمشاركة من خلال حسابك.

زائر
أضف رد على هذا الموضوع...

برجاء الإنتباه

بإستخدامك للموقع فأنت تتعهد بالموافقة على هذه البنود: سياسة الخصوصية

Account

Navigation

البحث

إعداد إشعارات المتصفح الفورية

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.