CREATE AND DROP

Hi all,
i have a user in a big database like HR i can create,drop and do any thing with my schema's tables ........now the problem is this
I want some table to create and never to be dropped so can i myself revoke my permission on those table to drop ....If yes tell me how because those table are very important and i want to get free from that no one from that user(HR) can drop or truncate that table........only update can be possible....remember no drop n truncate...this will be really a great help to because it will make my database tension free for me...:).
I am not system user remember i m in HR kinna user
UDAY

> Tigger won't stop him from dropping ......
Really?
SQL> create or replace trigger DDL_GUARD
2 before DROP or TRUNCATE
3 on schema
4 begin
5 raise_application_error( -20001, 'You are not allowed to DROP or TRUNCATE tables in this schema. ' );
6 end;
7 /
Trigger created.
SQL>
SQL>
SQL> create table emp ( emmpid number, deptid number );
Table created.
SQL>
SQL>
SQL> drop table emp;
drop table emp
ERROR at line 1:
ORA-00604: error occurred at recursive SQL level 1
ORA-20001: You are not allowed to DROP or TRUNCATE tables in this schema.
ORA-06512: at line 2
SQL>
SQL> descr emp
Name Null? Type
EMMPID NUMBER
DEPTID NUMBER

Similar Messages

  • How to create and drop partitions automatically?

    How to create and drop partitions automatically?
    The environment is Oracle 10g(10.2.0.3) on the RHEL4.0 system.
    I want to partition the MESSAGE table by date (NUMTODSINTERVAL(1,'DAY') ). One partition per day. Because the table is huge, only 2 partitions (today and yesterday's data) are necessary to be kept online. All the partitions that earlier than the previous day will be backed up and then dropped. I want to make the partition creating and dropping jobs run automatically. How to do it?
    Thank you

    junez wrote:
    How to create and drop partitions automatically?
    The environment is Oracle 10g(10.2.0.3) on the RHEL4.0 system.
    I want to partition the MESSAGE table by date (NUMTODSINTERVAL(1,'DAY') ). One partition per day. Because the table is huge, only 2 partitions (today and yesterday's data) are necessary to be kept online. All the partitions that earlier than the previous day will be backed up and then dropped. I want to make the partition creating and dropping jobs run automatically. How to do it?With 11g, new partitions can automatically be created.
    With 10g, you need to do that yourself. I prefer to create a "buffer" of future partitions - in case the job whose task it is to add new partitions gets held up or stuck. Or the job queue is full due to some problem and it does not get the chance to execute in time.
    I dislike your partitioning criteria. I prefer using the date directly and not mangling it to something else. If a specific day has a large volume of data, then another option is to use hourly date ranged partitions. With local partitioned indexes and the date time range used for querying, this can be quite effective performance wise.
    As for partitioning maintenance - I use a custom written partitionManager PL/SQL package that provides an interface for adding daily and hourly partitions to a table. Input parameters are for example name of the table, start date and the number of partitions to add. Similarly it provides interfaces for aging partitions - again by specifying a table and a date-time to use as the starting point, back into time, for removing old partitions.
    I typically call this code from the actual application code itself - so before a new partition will be used for example, the app code will first ensure that it has a partition to use. This is safer than a separate job as the dependency is resolved where and when it is needed - and not done as a separate task.
    For example - you should have a procedure/package that provides an app the means to log a message into your MESSAGE table. As part of an autonomous transaction, this procedure can check if the required partition exists, before attempting to insert a message into the table.
    Where this approach is not possible, a DBMS_JOB can be used to create future partitions - but as I mentioned, rather have it add a bunch of future (empty) partitions in case something goes pear shape with the job mechanism.

  • Creating and Dropping a temporary table in Bi publisher?

    Hi all.
    My database is sybase.
    I created a new data set in BI publisher where it creates a temporary table,
    uses that temp table in a select query and then I dropped the temporary table.
    I wrote all these 3 SQL statements in a single dataset.
    This is executed for the first time with out any errors.
    The second time I am tryiong to run the report..It says It cannot create temp table as it has one temp table with the same name.
    When I execute the same query in my database (SQL developer) this works. But not working in BI publisher.
    Please suggest.

    I came across this thread...in this forum while looking for a solution..
    Can i create temporary table with BI Publisher ?
    If we have to use a data template...Does the function in data trigger necessarily needs to be a PL/SQL function? because..we donot use oracle database. we use T-SQL to write queries..

  • Create and insert into temporary table

    Dear all,
    I want to create an temporary table and insert data from select statement and order data by field in that table, at the end i want to drop temporary table.
    CURSOR rob_twin
    IS
    SELECT t.tarj, s.b24, date, status, fii, acnt, mbr, pviv, type
    FROM
    p6.tarj t
    p6.stb24 s
    p6.cuet c
    WHERE .......
    --now I want to create table and insert above data (from cursor rob_twin)
    --after that I need to order data by t.tary from new table
    --finally I want to drop this table
    Thank you for your help.
    Regards,
    Robert

    The point is in Oracle you do not create the temporary table at run-time, use it, and drop it again.
    But you can create a GTT (Global Temporary Table) once and then it stays in the data dictionary, just like a normal table. The "temporary" part is simply that the data is temporary, can only be seen in this one session, and will go away either on commit or when the session ends.
    So first you create a global temporary table with the columns you wish. Using either ON COMMIT DELETE ROWS or ON COMMIT PRESERVE ROWS you decide whether data in this GTT should survive across transactions or not.
    Your logic could then be to populate this GTT with data from your remote database using INSERT INTO gtt_table SELECT ... FROM ...@dblink
    Then work with that data in the GTT as you would with any normal local table
    And finally either you simply commit your transaction and the data in the GTT goes away (if you did ON COMMIT DELETE ROWS), or you just DELETE gtt_table.
    You do not continually create and drop a GTT. The table definition is permanent - it is only the data that is temporary.
    Edit:
    PS: As Karthick stated above - for almost any usual purposes it is likely to be possible to solve the problem without having to use GTT's. Usually even with db_links it can be done with suitable SQL and joins without having to use a GTT. But if that turns out to be one of those rare occasions where that is hard - then the above is the way to go ;-)
    Edited by: Kim Berg Hansen on Sep 19, 2011 1:38 PM

  • When I drag and drop an icon from the address bar to the desktop is does creat the shortcut but will not display the website icon, only the firefox icon, how can I display website icons?

    When I drag and drop a website icon from the Forefox address bar to the desk top, the short cut is created but the icon that appears is the firefox Icon. I want to disply the icon from the website that the short cut refers to. I have checked all I can think of in my computer to no avail.

    You have to assign the favicon yourself to the desktop shortcut (right-click the shortcut: Properties) after you have dragged the link to the desktop.
    You can usually find the favicon in Tools >Page Info > Media and save the icon there.
    Otherwise use the main domain of the website and add favicon.ico (e.g. mozilla.com/favicon.ico ) to display the favicon in a tab and save that image to a folder.

  • Drag and Drop to photo page creates links, doesn't replace placeholders

    I searched the discussions for quite a while and didn't find much similar to this topic. Basically, drag and drop is no longer working on my iWeb and my photo grids will not accept pictures to replace the placeholder (sample) photos. I will try to explain the whole problem in detail.
    I am a new iWeb user, and I set up a page without any problems at first. Yet when I returned in iWeb to add another photo page today, I have had a lot of trouble. I used the template Photo Page and opened the Inspector and the Media Viewer to drag photos onto the placeholder photos, as the Help pages and tutorials show. Yet when I drag the picture file from the Media Viewer into the photo grid, only a small text box appears that sets up a hyperlink to the photo file on my computer. I've tried messing with the inspector, seeing what the difference is between the placeholder photos' settings and the files I'm trying to add.
    The only differences I can see are: in the Link Inspector's pane I can tell the program is at first making a hyperlink to the file instead of displaying the photo (yet disabling the hyperlink doesn't change anything); also,
    In the Graphic Inspector pane that appears when I have selected a general area in the photo grid, at the top the "Style" , "Layout" and "Caption" options appear, along with a display of a sample photo style. When I click on one of the rectangles that appears with the file I am trying to drag and drop, I have only the "fill" option, which has "none" selected. Fiddling with the options does not get the photo to appear.
    I can see the blue grid surrounding the placeholder photos, so the photo grid exists. I have also tried using different templates' photo pages, but they all have the same problem. I also tried creating an album in iPhoto and importing it to iWeb, but only two photos appeared out of 12.
    So the main part of my problem is not that photos don't appear at all (if I try and insert them they appear on their own, completely independant of the template's style and the photo grid)., it is that they do not work with the photo grid and that drag-and-drop no longer works.
    Any information that could help is greatly appreciated.
    Sue

    Susan,
    Try out the following things. These suggestions are
    sort of the starting point for non-specific strange
    behavior in iWeb.
    1. Delete iWeb preference file at:
    YourHardDrive/Users/yourname/Users/Library/Preferences
    /"com.apple.iWeb.plist"
    2. Delete iLife Media Browser preference file at:
    YourHardDrive/Library/Preferences/"com.apple.iLifeMedi
    aBrowser.plist"
    3. Repair startup disk permissions using Disk
    Utility
    4. Reboot machine
    5. Delete iWeb application (but keep a backup of the
    Domain file!) and reinstall iWeb 1.0 from original
    iLife'06 DVD or Recovery Disks and then update
    directly to 1.1.1 via Software Update.
    These are the top 5 things that seem to garner some
    kind of positive results from people having similar
    problems.
    I am having the same problem Susan described. I've tried #1 and #2 from the above recommendations and still have the same problem of photos not opening in the photo page after dragging them from iphoto. I, too, published a site (not on .Mac, but I don't know if that matters) and now want to add a photo page. Also, the template shows six placeholders, but when I select the photo page only three appear.
    Hope you can help. Thank you.

  • How do I create a drop down menu with Code Snippets and Flash CS5?

    Hi
    I am wondering how to create a drop down menu using the Code Snippets and CS5?
    There are some older tutorials out there and it would be nice if someone could create an updated drop down menu tutorial, and it might be me doing this after I have figured out the best and easiest way to create one, but before that I need some pointers.
    Thanks!
    Have a great day!
    Paal Joachim

    You can use panel widget to create manual menu where set to show target on rollover.
    Something like this :
    http://muse.adobe.com/exchange-library/menu-vertical-accordion-widget-1
    http://muse.adobe.com/exchange-library/tiptop-navigation-menu
    Thanks,
    Sanjit

  • I have 2 auxillary disk drives for my MacBokk Pro. Time Machine uses one for backup and I use the other for storage, but I am unable to create a new folder or drag and drop files or folders to the aux drive.

    I am unable to create a new folder on either of my auxillary disk drives.  I can access the files and folders that were there when I transferred one of the drives from a PC.  Time machine uses one for backup and I want to use the other to store photos which are large files.  An help would be appreciated.

    Thanks for the reply.  If I reformat the drive will I be able to access the files on it from the MAC.  I do not share the drive with a PC.  The files were originally created on a PC which I no longer use.  I do want to continue to access the files put there by the PC.  I would like to not have to copy them over to the MAC hard drive just to use them.  The second aux drive is new and works fine because it was formatted by the MAC.  I can drag and drop files there and work with just as if they were on the internal drive.

  • What is the correct way to add styling to drag-and-drop created calendars?

    I have a working instance of a rich client calendar. I generated the view with the required fields (start, stop, provider, ...), put it into the App Module, and dragged it onto a JSF page to create a calendar.
    Next I created an activityScope object in a class called CalendarBean (no inheritance)
    Class CalendarBean()
    private HashMap<Set<String>, InstanceStyles> activityColorMap;
    +..+
    +public CalendarBean() {+
    super();
    activityColorMap = new HashMap<Set<String>, InstanceStyles>();
    HashSet setEd = new HashSet<String>();
    HashSet setLen = new HashSet<String>();
    setEd.add("Work");
    setLen.add("Home");
    activityColorMap.put(setEd, CalendarActivityRamp.getActivityRamp(CalendarActivityRamp.RampKey.ORANGE));
    activityColorMap.put(setLen, CalendarActivityRamp.getActivityRamp(CalendarActivityRamp.RampKey.RED));
    +}+
    +}+
    Next, I linked this up as a backing bean and associated the ActivityStyles of CalendarBean to it:
    +#{backingBeanScope.calendarBean.activityColorMap}+
    I populated some records in the database with properties "Work" and "Ed', but they show default blue.
    As I understand it, I need to do something with the getTags() method of the underlying CalendarActivity class, but I'm not quite sure how to do that.
    Took a stab at creating a class, CalendarActivityBean, that extended CalendarActivity, and pointed all the CalendarActivity references I had to the new class, but it didn't seem to fire (in debug), and I got into trouble, when inserting records, with
    public void calendarActivityListener(CalendarActivityEvent calendarActivityEvent) {
    currActivity = (CalendarActivityBean) calendarActivityEvent.getCalendarActivity();
    being an illegal cast
    What is the correct way to add provider-based styling to drag-and-drop create calendars?
    Ed Schechter

    A colleague of mine was kind enough to solve this:
    The calendar has ActivityStyles property = #{calendarBean.activityStyles}
    CalendarBean looks something like this:
    package com.hub.appointmentscheduler.ui.schedule;
    import java.util.HashMap;
    import java.util.HashSet;
    import java.util.Set;
    import oracle.adf.view.rich.util.CalendarActivityRamp;
    import oracle.adf.view.rich.util.InstanceStyles;
    +public class CalendarBean {+
    private HashMap activityStyles;
    private String dummy;
    +public CalendarBean() {+
    +// Define colors+
    activityStyles = new HashMap<Set<String>, InstanceStyles>();
    HashSet setPending = new HashSet<String>();
    HashSet setArrived = new HashSet<String>();
    HashSet setApproved = new HashSet<String>();
    HashSet setCompleted = new HashSet<String>();
    setApproved.add("APPROVED");
    setPending.add("PENDING");
    setArrived.add("ARRIVED");
    setCompleted.add("COMPLETED");
    activityStyles.put(setApproved, CalendarActivityRamp.getActivityRamp(CalendarActivityRamp.RampKey.GREEN));
    activityStyles.put(setPending, CalendarActivityRamp.getActivityRamp(CalendarActivityRamp.RampKey.ORANGE));
    activityStyles.put(setArrived, CalendarActivityRamp.getActivityRamp(CalendarActivityRamp.RampKey.PLUM));
    activityStyles.put(setCompleted, CalendarActivityRamp.getActivityRamp(CalendarActivityRamp.RampKey.LAVENDAR));
    +}+
    +public void setactivityStyles(HashMap activityStyles) {+
    this.activityStyles = activityStyles;
    +}+
    +public HashMap getactivityStyles() {+
    return activityStyles;
    +}+
    +}+
    Now, go into the Bindings tab on the calendar page, double click the calendar binding, and specify the column you've defined as the calendar's Provider in the Tags dropdown.
    Should show colors.

  • How to Create Table Using Column Drag and Drop Feature

    Hi:
    I am new to Oracle SQL dev Data Modeler tool and would like to know if there is a way to create a new table by re-using the existing columns or column groups. The idea is to maintain consistency and save table design time. If columns created previously can be re-used and require drag and drop of column in the right pane, then only new columns need to be manually created.
    Any thoughts on this will be appreciated.
    Thanks!

    Hi Kent
    I checked out the video and tried it in Oracle designer, it works and works great!
    My other question is that I may have several set of columns that I may want to group depending on the table requirements. Can I have multiple templates and choose which one to apply to?
    Also, how do I choose the table where the table template needs to be applied. As I may be interested in applying the table template to selected tables only.
    Thanks
    Edited by: user648132 on Feb 20, 2012 10:47 AM

  • Can't resize firefox so i can drag and drop to create a shortcut

    I can't make my Firefox page smaller so I can drag and drop a web site to create a shortcut. I am using windows 7. I have no grippe when i point in the lower right corner. When I use zoom the page itself re sizes but not the window. I just need to see a little of my desktop so I can create a shortcut.

    Could it be, you are in full-screen mode? Press F11 to check it: if you are indeed in the fulöl-screen mode, the FX window will resize and you should be able to grp the lower right corner for resizing.
    Let us know if it helped.

  • Acrobat 9 no longer lets me drag and drop to create pdf

    acrobat 9 no longer lets me drag and drop to create a pdf

    What kind of files? If DOC files, is PDF Maker active in WORD? We need more info to help. The applications (and versions) as well as OS would help.

  • How do I create a text style in CC libraries? Every time I drag and drop text into library form Photoshop or illustrator it turns it into a graphic.

    How do I create a text style in CC libraries? Every time I drag and drop text into library form Photoshop or illustrator it turns it into a graphic.
    If I select the text layer and click the text style button in the library it just creates a new text style for Myriad Pro 12pt - I'm not using that anywhere in my document.
    Can anyone help? Seems like a bug to me as I'm trying what the video tutorials are saying.
    Thanks

    I realize AI is an illustration program.
    Do you realize it is an object-based vector-based program? Do you know the difference between raster-based and vector-based content?
    My question seems to be all over the forum but no one has been able to answer other than exporting to these file formats, which make text look awful and of no use....
    And yet everyone else in the world makes proper web images every day using a plethora of programs, including these...go figure.
    Am I missing something?
    Yep. Pretty much.
    Hello Adobe! People use transparency on website logos.
    Hello, cocteau! What you're calling "transparency" is inherent to object-based vector artwork. But web browsers don't support object-based vector artwork, except via file formats like Flash and SVG, or by viewing as a PDF in a plug-in version of Reader. Raster imaging in general only supports "transparency" by either indexing a specific color (i.e.; "don't display this color", as in GIF) or including an alpha channel (i.e.; "blend all the pixels with existing pixels, based on values from this extra channel", as in PNG). It's all in the raster file format you use, cocteau; it has little-to-nothing to do specifically with Adobe software. Such things are among the most basic matters understood by someone doing web design.
    When I export an eps from .ai file, and open the eps in photoshop,...I save as a gif for the web, it goes back to the original problem...creates jagged text. I"m giving up on this garbage...Thanks a lot adobe! Lower the price of this software if this is all that can be done.
    Once it leaves Photoshop (or Illustrator, or whatever) as a non-proprietary raster image format, it's all about what the format can do re "transparency". You can do this stuff with most any graphics program. You should read about basic web design and the differences between raster and vector content, rather than rant.
    JET

  • How can I allow a learner to review a created Drag and Drop Quiz to show the learner their incorrect/correct answers?

    Captivate 8: I have created an assessment with two multiple choice question slides and eight drag and drop question slides. After the learner views their score, I would like them to be able to review all of their answers to see where errors were made. Currently, the review quiz only shows their answers and the correct answers for Multiple choice question slides. Ideally, I would like a review of the drag and drop question slides where the incorrect choices are outlined in red or something to this effect. I appreciate any insight and suggestions!

    Sorry, D&D is not a normal question slide and I can only recommend logging a feature request. I would really like to be able to choose whether an interaction is reset or not, because this problem doesn't exist only for D&D but for all learning interactions as well.

  • Is it possible to create a tree with drag-and-drop functionality using ajax

    I saw these samples;
    Scott Spendolini's AJAX Select List Demo
    http://htmldb.oracle.com/pls/otn/f?p=33867:1:10730556242433798443
    Building an Ajax Memory Tree by Scott Spendolini
    http://www.oracle.com/technology/pub/articles/spendolini-tree.html
    Carl Backstrom ApEx-AJAX & DHTML examples;
    http://htmldb.oracle.com/pls/otn/f?p=11933:5:8901671725714285254
    Do you think is it possible to create a tree with drag-and-drop functionality using ajax and apex like this sample; http://www.scbr.com/docs/products/dhtmlxTree/
    Thank you,
    Kind regards.
    Tonguç

    Hello,
    Sure you can build it, I just don't think anyone has, you could also use their solution as well in an APEX page it's just a matter of integration.
    Carl

Maybe you are looking for