How to Import ONLY Synoymns

Hi There,
I was wondering how to import only the synonyms (including public) from one database into another database.
I started an import but forgot to drop the synoyms first.
Thanks in advanced,
J

Import is probably the wrong tool.
Consider using dy. sql to create a script for this.
I can dig up an example if you want.
ex
set pagesize 5000
set linesize 110
spool c:\synonyms.sql
select 'create or replace synonym '||a.SYNONYM_NAME||' for ' || a.TABLE_NAME || ' ;' from dba_synonyms a
where a. OWNER = 'SCOTT';
spool off
Edited by: mseberg on Jul 14, 2010 10:43 AM
Better (or more real world SQL)
select 'create or replace synonym '||a.SYNONYM_NAME||' for ' || a.TABLE_NAME || ' ;' from dba_synonyms a where a.TABLE_OWNER = 'SCOTT';
Use the script...

Similar Messages

  • How to import only procedures, functions, and packages only

    Hi everybody...
    How to import only procedures, functions, and packages only from one user to another user.
    Thanks in advance
    pal

    Thanks for your reply...i did the following..can you please help from this how to proceed
    ---------------- getcode.sql -------------------------------
    set feedback off
    set heading off
    set termout off
    set linesize 1000
    set trimspool on
    set verify off
    spool &1..sql
    prompt set define off
    select decode( type||'-'||to_char(line,'fm99999'),
    'PACKAGE BODY-1', '/'||chr(10),
    null) ||
    decode(line,1,'create or replace ', '' ) ||
    text text
    from user_source
    where name = upper('&&1')
    order by type, line;
    prompt /
    prompt set define on
    spool off
    set feedback on
    set heading on
    set termout on
    set linesize 100
    ------------------- getallcode.sql -------------------------
    set termout off
    set heading off
    set feedback off
    set linesize 50
    spool c:\xtmpx.sql
    select '@getcode ' || object_name
    from user_objects
    where object_type in ( 'PROCEDURE', 'FUNCTION', 'PACKAGE' )
    spool off
    spool c:\getallcode_INSTALL
    select '@' || object_name
    from user_objects
    where object_type in ( 'PROCEDURE', 'FUNCTION', 'PACKAGE' )
    spool off
    set heading on
    set feedback on
    set linesize 130
    set termout on
    @xtmpx.sql
    I did this one user and created the xtmpx.sql
    and getallcode_INSTALL.LST.
    From this, how to proceed to run these in another user.
    Thanks,
    Pal

  • How to import only grants

    Hello,
    Does anyone know how to import only grants from a .dmp file?
    1. We did a full export of the source schema.
    2. During our 1st import run, we imported the tables only.
    3. Now we would like to import only grants.
    Is this (step 3) possible with the datapump import/export utility?
    Thank you for your help!

    OrionNet,
    Thanks for the link. It was a good doc, which helped me to understand the datapump with sqlfile parameter.
    I did a test run of generating sqlfile with impdp, and was able to get the sql script with grant only.
    Here is what I did:
    1. Run the following:
    impdp system/***** parfile=test_imp_grant_only.param
    2. Below is what's in the parameter file (test_imp_grant_only.param)
    DIRECTORY=datapump
    SCHEMAS=ABC
    Include=grant
    sqlfile=datapump:test_imp_grant_only.sql
    DUMPFILE=datapump:test_export_ABC.dmp
    3. The sql script (test_imp_grant_only.sql) will be generated under datapump directory.
    Thanks!

  • How to import only "missing" E-Mails from backup?

    Hello everyone!
    I have a problem with mail. I set up a new MacMini (w/ Mavericks, i7, 2014) from a backup of an older MacMini (also Mavericks, i5, 2012). I used the migration client and it all looked just fine, when I first started working on the new system. First thing, which was odd: I had my project folder with LOTS of content lying on the desktop (some 14 GB, a few thousand files in multiple subfolders). I noticed, of those 14 GB 12 GB went missing. No problem - I just copied the files from my old system (which I still have and which still works).
    However, after I've been working with the new system for a couple of weeks, I noticed the same thing that happened to my project folder apparently happened to my (local) E-Mail folders. Again, the folder structure is still there, but tons of (mostly older) e-mails are missing. Since I've been working with the new system for quite some time now, the above-mentioned "delete and replace" approach is out of question, because all new e-mails, which I filed in the local folders would be lost.
    As I still have my old system as a backup, it is no problem for me to retrieve all old e-mails manually. But is there a way how I can import only those mails, I have lost during migration? Or in other words: How can I sync the new and the old mail folders while avoiding duplicates and keeping the folder structure as is?
    Every comment is highly appreciated! Thanks in advance..!

    Quit Mail. Force quit if necessary.
    Back up all data before proceeding.
    Triple-click anywhere in the line below on this page to select it:
    ~/Library/Mail/V2/MailData
    Copy the selected text to the Clipboard by pressing the key combination command-C. In the Finder, select
              Go ▹ Go to Folder
    from the menu bar. Paste into the box that opens by pressing command-V, then press return.
    A folder window will open. Inside it there should be files with names as follows:
              Envelope Index
              ExternalUpdates.storedata
    Move those files to the Desktop, leaving the window open. Other files in the folder may have longer names that begin as above. Move those files, if any, to the Trash.
    Relaunch Mail. It should prompt you to re-import your messages. You may get a warning that the index is damaged and that Mail has to quit. ClickOK. Typically, the process takes a few minutes, but it may take hours if you have gigantic mailboxes. In that case, you may be able to speed things up by temporarily adding your home folder to the Privacy list in the Spotlight preference pane. Remove it when Mail has finished importing.
    Test. If Mail now works as expected, you can delete the files you moved to the Desktop. Otherwise, post your results.

  • How to import only rows of tables from from a dump file

    Good day,
    I have impoted a schema from a dump files with option rows=n,(accordingly it should import only structure of the tables)
    now i want to import rows for these tables in that schema. Kindly guide me how to do that. I have used below syntax for import.
    imp userid=system/manager@testdb fromuser=abc touser=abc file=d:\abctest\
    abc.dmp log=e:\abc15.log buffer=100000000 ignore=y constraints=n grants=n statistics=none rows=n;
    Any help willbe much appriciated.
    Regards
    Ansh

    Hi Sybrand,
    Thanx for the suggestion. Actually it is my fault that I had not explained the whole scenarion.
    Let me explain it one by one...
    (1) First i was importing a schema with rows=y option and I was getting some constraints error(can not insert NULL value in 'not null' column of some particular table) and import was unsuccesful.
    (2) Then i desided to import only structure of the tables in that schema, and later disabled that constraint which was creating the problem.
    (3) Now I m willing to import the data in these tables using that .dmp file, using rows=y, and this was my question if i m doing it in a right way or do i need to do some further step.
    Hope this time i have made picture more clear.
    Thanx a lot Hans and Sybrand
    btw no wall around so can't bang my head :)

  • How to import only RAW files from camera?

    I also shoot with both RAW and JPEG, such that I have access to JPEGs to share with people immediately before post-processing.  But I only want to use RAW in my Lightroom flow.
    When pictures are already in Lightroom, I use filters in the library view to show only RAW, or only JPEG, or both (by applying a filter on the file extension).
    But how do I set a filter before importing?  I would like to import only the RAW pictures into lightroom, but I don't see a way of doing that using Lightroom's import from camera card features.  I either have to let lightroom  import all, and then remove the JPEGs, or use Windows explorer to copy over just RAW files and then use Lightroom to import.
    I would like to use Lightroom in just one step to import all RAW files (but only RAW files) from the camera card directly to the library.  A file filter in the import dialog seems like an easy feature to implement.

    Another reason to have a filter in import is then you can then apply a preset to the RAW files only. At present if I want to apply a preset to my RAW files on import I have to apply it to the JPEGs too as there is no way of being selective on import. I then have to remove the preset from the JPEGs, which is a pointless and unnecessary task, whilst LR is busy rendering the unwanted look.
    I shoot both file types on one cameras as the JPEG gives me a look that is very hard to replicate with the RAW files and on another camera I use a picture style to remind me of what I was looking for when shooting. Again as it's a custom style it's very hard to replicate the look in LR from the RAW file.
    Though a major reason I shoot both JPEGs + RAW is that I was asked by a client a few years back, when I only shot RAW for all the shots as JPEGs to select down from. As this was a 4 week feature film shoot it took several days constant rendering out of Photoshop to output the JPEGs. This was just before LR and even then, LR would still take considerable time to produce all those exported files, though a lot quicker than PS I would hope. So now I always shoot JPEGs as well so I never have to waste time outputting JPEGs for a client to do a rough select.

  • How to import only master files from iPhoto

    Hi,
    When I import an event or an album in Aperture from iPhoto, both the master and the corrected file are imported as a stack. But I would like in fact to have only the master file and rework (if necessary) the changes into aperture versioning system.
    So, is it possible (I do not see how) when importing to tell Aperture to import only the master?
    Otherwise, is it possible to ask Aperture to delete the corrected version only without having to do them one by one?
    Thanks

    Go to your Pictures Folder and find the iPhoto Library there. Right (or Control-) Click on the icon and select 'Show Package Contents'. A finder window will open with the Library exposed.
    Make an Alias to the Originals folder and drag the alias to the Desktop or whereever you want it.
    Now when you import, in the Import dialogue choose the Alias and it will bring you directly to the Originals Folder.
    Standard Warning: Don't change anything in the iPhoto Library Folder via the Finder or any other application. iPhoto depends on the structure as well as the contents of this folder. Moving things, renaming things or otherwise making changes will prevent iPhoto from working and could even cause you to damage or lose your photos.
    Regards
    TD

  • HT201302 How to import only the newest iPhone photos to iPhoto library/Mac

    I have an iPhone 4s and every time I connect my iPhone to my Mac it downloads all the photos.
    How do I import only the newest photos? To have to check what I already have in albums and select only the latest would be very
    time consuming. There must be an easier way.

    When iPhone is connected and selected in computer iTunes, in Photos tab >
    in Selected albums, Events, and Faces, and automatically include > select "the most recent Event"

  • How to import only RAW images from folder with RAW & JPEGs?

    My system is set up that I have both RAW & JPEGs in the same folder since I shoot JPEG+RAW. How can I import just the raw images without also sucking in the jpegs? There is no way to distinguish the difference in the Import box and also no way to easily separate the the two in the Import box. I've tried using the List View and separting them by File Size, but Aperture has a stupid bug here and it tells me that the JPEG file sizes are in the teens (like 17-18 megs) and they are still hard to separate from the RAW which are about the same size.
    Why can't Aperture do this basic thing?

    I'm not doing anything. What I wrote in my workflow example above is exactly what I'm doing. I've been trying some experiments to see if it was "A Better Finder Rename" that is causing the issue. So far, no go. I have taken just a couple of JPGs only and pointed Aperture's Import to the folder that contains them. Aperture is reading that there are only 2 jpegs (which is what there is) and their file size is right on the mark.
    Ok. I just narrowed it down to something. The flaw is showing up after the RAW files are converted to DNGs. The JPEGs do not show up in the Import box when there are camera raw files like NEFs or CR2s and the corresponding JPEGs. That is Aperture's normal behaviour. But, and this is a big BUT, when the raw files are converted to DNGs and they are in the same folder as the corresponding JPEGs, that's when Aperture pulls its shenanigans. It has something to do with the JPEGs and DNGs having the same name. Even though the files have different extensions, Aperture is doing something to the file size of the JPEGs that make them seem that they are much larger files than they actually are.
    I figured it out like this:
    I had 2 CR2 files and the corresponding JPEGs in a folder. Pointing Aperture's Import to that folder, Aperture did what it is supposed to do; it saw only 2 raw files (doesn't matter that the G9 CR2 files are not supported yet). So, I renamed all the files using A Better Finder Rename and Aperture still only saw 2 raw files.
    So far so good.
    Then, I converted just the 2 CR2 files to DNG and kept them in the same folder. Aperture saw 2 DNGs and 2 CR2 files. No jpegs were seen. Business as usual. Then I removed the CR2s and renamed the jpegs so they had the same names as the DNGs (except for of course different extensions) and that's when Aperture saw the jpegs as separate files and saw them with bogus file sizes.
    So I tested that by altering the jpeg names so that they were different from their corresponding DNGs and Aperture went back to seeing the jpegs with the correct file sizes.
    Therefore, Aperture is having some difficulty with two separate files, one JPEG and the other DNG, when they both have the same name (different extensions, of course).
    Try it if you have a moment. Take one raw file and convert it to DNG and place it in a folder with its corresponding jpeg. Rename both to the same name and different extensions (.dng + .jpg) and see what happens when you try to get Aperture to import. Chance are Aperture will show bogus file sizes for the jpeg.
    Let me know if that's clear.
    Antonio

  • How to import only sequences from one user to another user

    Hi...all,
    I want to import from one user to another user only sequences. Can anybody please guide me in this regard.
    Thanks in advance
    pal

    What DB version do you use?
    I don't know if dbms_metadata is present on oracle 9i but I'm quite sure that to_char(CLOB) is supported only on 10g, so you should find onother way to get the clob.
    You could also determine the extract ddl script with this script that runs on older versions as well:
    select 'CREATE SEQUENCE "'||USER||'"."'||
         SEQUENCE_NAME||'" MINVALUE '||MIN_VALUE||' MAXVALUE '||
         MAX_VALUE||' INCREMENT BY '||INCREMENT_BY||' START WITH '||LAST_NUMBER||
         DECODE(CACHE_SIZE,0,' NOCYCLE ',' CACHE '||CACHE_SIZE)||
         DECODE(CYCLE_FLAG,'N',' NOCYCLE ',' CYCLE ')||
         DECODE(ORDER_FLAG,'N',' NOORDER ',' ORDER ')||';'
    from user_sequences;What sql client did you use?
    I don't get empty rows with sql navigator and sql plus.
    Bye Alessandro

  • How to import only images from DSLR

    Friends,
    I sometimes shoot video on my DSLR.  Right now, I tell Aperture to import files and the program displays all of the images on the camera's card, still and video.  To import the stills only, I have to manually search the files.  Is there an easy way to import just the stills into Aperture without importing the videos?
    Thanks!
    Steve

    In the Import window enable the File Type brick and select the file types you want to import.

  • Importing only select images

    I'm new to iPhoto and can't figure out how to import only select photos from my digital camera when I connect. It automatically brings up an option to import all on my camera, but I only want to select a few. How do I do this?

    Scott,
    Thanks for the good information here. I had never noticed that the media readers were on the list of compatible cameras. That list does seem to be just the tip of the iceberg. Although Apple hasn't tested the SanDisk readers, others have reported that they work without a hitch. I'd be surprised if one didn't work.
    FYI, it's not really a troubleshooting issue that a Canon doesn't mount in the Finder as an external drive. They just aren't designed to do that. They function as intended in iPhoto and Image Capture. However, when you want to import only selected photos into iPhoto 6, it is necessary to have the memory card mounted on the Desktop. Since some camera's aren't designed to do that, the workaround is to use a card reader. Image Capture works as well, but I don't prefer the added steps.
    I viewed the iPhoto '08 tutorials, and it looked like iPhoto now allows you to select the photos directly from its import dialog. If I understand it correctly, that would be a great feature, long overdue. I won't find out for myself, though, because I have no desire to upgrade my G4 mini.
    Regards.

  • How can I import only jpeg and not jpeg plus RAW into Photos on iPad?

    I capture both on my camera.  I do post-shoot processing on computer (Lightroom/Photoshop) but want to see larger previews on iPad (the "new" version with retina display) than my camera LCD allows.  I am using the Apple hadware adaptor to load from an SD card.  The RAW files are taking up way too much memory on the iPad--it seems Photos imports both files at once.  I can't figure our how to tell it to import only the smaller JPEG files.
    If there is a better App than Photos for this, please advise.  Note I will not be doing any serious editing on the iPad.
    Thanks,
    Doug

    It doesn't matter what App you use it will copy all the photos from the SD card.
    But I have a workaround;
    All you do is import your JPEG+RAW images using the camera connection kit.
    Go to Albums in the Photo App, choose Change, Choose New Album, give name, choose Last import, choose Select all photos, choose Finish.
    Now go back into the photos app and delete all the photos from your "Last import" Album. It will say that it is going to delete them everywhere but really it doesnt because it leaves the JPEG in the new album. The result is that you will only have your JPEGs that you imported in your camera roll and the RAW images get deleted.
    First try out before you delete photos from SD card!

  • How to import RAW and JPEG, but see only one image?

    This is driving me crazy.
    I shoot sometimes RAW and sometimes JPEG on the same memory card. So some pictures have only a JPEG file, others (the ones I shot in RAW) have a RAW+JPEG pair (or at least, Aperture sees it that way when displaying the content of the memory card).
    What I want:
    - import only once
    - for JPEG files, JPEG is imported as master
    - for RAW files, RAW only is imported as master
    There seems to be no combination of the import settings that lets me do this?!?!?!?
    If, under the "RAW+JPEG Pairs" settings I select "RAW files only", all JPEG files DISAPPEAR from the import list. WHY? This setting should be for "RAW+JPEG Pairs" only, it should not affect images that only have a JPEG file. I want to import JPEG files as well, so I select "Both (RAW as master)". Now, in the imported project there are TWO images to deal with, which is not what I want.
    Even if I were to import twice, how can I exclude the duplicates?

    Please ignore my post. Aperture behaves correctly. I got confused because many pics look alike, but aren't really the same pic. Sorry for the confusion.

  • I have iphoto 6.  How do I only selecy certain photos from my camera when importing rather than all of them as show in the import page that loads

    I have iphoto 6.  How do I only selecy certain photos from my camera when importing rather than all of them as show in the import page that loads

    You use Image Capture (in your Applications Folder) for that job - or upgrade to a later iPhoto.
    Regards
    TD

Maybe you are looking for