best way to get documents that are NOT in another table

I have two large tables in oracle. An array of account that has millions of rows. Each account can be registered in a particular program and can therefore also to the Enrollment table, also with millions of rows. I am to find the most optimal way to find all accounts into ACCOUNT which are NOT in the Enrollment table.

I did something like this:

Select / * + index (ACCOUNT idx_acct_no) * /.
a.Acct_No
one account
If a.acct_no not in (Select e.acct_no from e REGISTRATION);


It takes a long time to run, even though I'm using the index.

I even tried to use the PK on the ACCOUNT dashboard, as is a FK on the ENROLLMENT table as such:

Select a.acct_no
one account
Where a.id not in (Select e.id of e REGISTRATION);

too, it takes too much time to recover (if any).

Is there a better way to make this choice please?

+
Try this:

SELECT a.acct_no
  FROM ACCOUNT a
 WHERE NOT EXISTS (SELECT '?'
                     FROM ENROLLMENT e
                    WHERE e.acct_no = a.acct_no);

: p

Tags: Database

Similar Questions

  • A way to show items that are not used in the sequence

    Hello world

    is there a way to display items that are not used in the sequence.

    in order not to forget the "rushes" in the Assembly?

    my best,

    Turn on the use Audio and video columns in the sandbox and then sort by those.

  • Smartphones blackBerry [9700 "Bold"] how to get emails that are not gmail, yahoo,...?

    Hi guys,.

    I saw a small company and goes to buy a Blackberry Bold 9700. I read a lot of forums and boards, but I have still not found an answer to the question: "is it possible to get e-mails from accounts that are not google or yahoo etc."?

    I have a clean online store or the domain and so my email address is something like info @.com

    I am currently using Thunderbird on my laptop to get and send e-mails via pop3/smtp.

    So, it is possible to have access to e-mail via a pop3 server and send emails using smtp on a Blackberry 9700 Bold?

    Greetings,

    Marco.

    Yes, you can access most of the protocols POP3 or IMAP mail server.

  • way to find vm that are not removed from disk

    Is it possible that I can find, vm that are not removed from disk

    That is to say that "take inventory" but I forgot to remove the disc.

    Thank you

    If you only need a report, you can do it like this (I've made a few changes to your script).

    $unregistered = @)

    foreach ($Datastore in (Get-Datastorecluster xxxx |)) Get - Datastore)) {}

    # Collect .vmx paths of virtual machines stored on the data store

    $registered = @ {}

    Get - VM - Datastore $Datastore | %{

    $_. Extensiondata.LayoutEx.File | where {$_.} Name - like "*.vmx"} | % {$registered. Add ($_.) Name, $true)}}

    # Set up the search. VMX files in the data store

    New-PSDrive-name TgtDS-site $Datastore - PSProvider VimDatastore-Root '-' | Out-Null

    $unregistered += (@(get-ChildItem-Path TgtDS:-Recurse |)

    where {$_.} FolderPath - notmatch ".snapshot" - and $_. Name - like "*.vmx" - and! $registered. ContainsKey ($_.) DatastoreFullPath)} |

    Select DatastoreFullPath))

    Remove-PSDrive-name TgtDS

    }

    $unregistered | Export Csv c:\temp\vm-unregister.csv - NoTypeInformation - UseCulture

  • The columns appear in the data store that are not in the table

    Hi guru,.

    I have a table that I built in Oracle and added to ODI by refactoring it, but when I add it as a source to my interface, it contains columns that are not physically in the Oracle table that I can look into a TOAD. I dropped the prior of the table deleted-> interface-> reverse engineering table but I get an additional column. Y at - it an explanation for that? I have the table listed in a stored procedure - should I delete this step as well before reverse engineering, or is something else.

    Thanks in advance.

    Mike

    Yes. There is a possible explanation. How do you are engineering it? If you use Oracle RKM, you may be using a customized version of this KM which adds a column of your table name...

  • I get emails that are not addressed to me.

    I get emails from advertising a lot, a lot who are not addressed to me.  Where the FROM and TO, and the SUBJECT line is theTO is NOT MY e-mail address.  Why is this and how to stop it?

    You can set up a message rule where if the message isn't to you, then move to a junk mail folder.  You can then the screen junk folder and delete what is really undesirable.
     
    Steve
     
    "TerriMcCool" wrote in message News: b2f6f65c-aab3-4d5a-94ee-46120336fa07...

    I get emails from advertising a lot, a lot who are not addressed to me.  Where the FROM and TO, and the SUBJECT line is theTOis NOT MY e-mail address.  Why is this and how to stop it?

  • What is the best way to get the minimum or maximum of a table of numbers value?

    Let's say I have a table of numbers: [2,3,3,4,2,2,5,6,7,2]

    What is the best way to find the minimum or maximum value in the table?

    Now, just get the maximum, I'm a loop in the table and reset a variable to the value if it is greater than the existing value:

    What I ended up doing was sorting table (descending to MAX) upward for MIN and then grabbing the first element of the array. Works like a charm in very few lines of code.

    Thank you.

  • delete records that are related to another table

    I want to delete records from a table (A), these recordings has a relationship with another table (B)

    using a query to set these records is that I want to delete

    with B as
    (
    f select '2', '3' l double
    Union of all the
    f select '2', '3' l double
    Union of all the
    f select '4', '4' l double
    )


    Select * from A, B
    where B.f() > 3 and b. > 3
    and A.f. = B.f()
    and A.l = b.

    Oracle Database 11 g Enterprise Edition Release 11.1.0.7.0 - 64 bit Production


    Thanks in advance!

    Hello

    Here's one way:

    DELETE     a
    WHERE     f     > 3
    AND     l     > 3
    AND     (f, l)     IN (
                   SELECT  f, l
                   FROM     b
                     )
    ;
    
  • Is there a way to remove "bootstrap" features that are not in use?

    Is there a way to remove "bootstrap" functions that are not currently in use of the css 'bootstrap' or is it necessary?

    You can customize the Bootstrap in the link below by choosing only the components/css to use, but unless you know what you're doing the Bootstrap default css file is best left alone. The extra css that you do not use does not really hurt.

    http://GetBootstrap.com/customize/

    I assume that you use the correct workflow - bind to Bootstrap css by default and then file if you want to avoid linking to your own css default css stylsheet. If you do this the default bootstrap css works without danger in the background. Yes, because of course, I understand what you say - why the hell have a zillion redundant css selectors that are related to the page if you use only a few dozen.

  • Tried to open the Excel spreadsheet in Sharepoint, but get the message "cannot open the window because it contains the following features that are not supported by Excel in the browser: sheet Protection.

    I tried to open this Excel spreadsheet in Sharepoint and received the following message.

    "Cannot open the window because it contains the following features that are not supported by Excel in the browser:

    -Protection plate

    You want to try to open the message in Excel? »

    Learn more about the unsupported features.

    YES                       NO

    When I type 'Yes', I had then the second message.

    "To open this workbook, your computer must have a version of Microsoft Excel is installed and your Web browser must support opening files directly from Excel in the browser".

    What should I do?

    Original title: sharepoint excel files

    Tommy:

    I have 64 bit explore.  So I guess that the thought is that the error message was generated by the incoming file, as I have other files Excel I can access in Sharepoint with no problem?  I sent the file Outlook e-mail and was able to open it with no problem at all.  .

    Thanks for the information,

    Jim

  • I'm looking for the best way and the best way to get a product key for my windows 7 Edition family.

    Hello.  I'm looking for the best way and the best way to get a product key for my windows 7 Edition family.  Thanks Bob

    Original title: product windows keys 7

    The cheapest option is the OEM System Builder for Windows 7 Home Premium license, but has some license restrictions:

    Amazon.com: Windows 7 Home Premium 64 - Bit System Builder...

    The OEM of Windows 7 versions are identical to the versions commercial full license with the following exception:

    -OEM versions don't offer any free direct support from Microsoft technical support Microsoft

    -OEM Licenses are tied to the computer first you install and activate it on

    -OEM versions allow all hardware upgrades except for an upgrade to a different model motherboard

    -OEM versions does not move directly from an older Windows operating system

    What is OEM software? :
    http://support.Microsoft.com/GP/oemsupport_1/en-GB

    Licensing FAQ:
    http://www.Microsoft.com/OEM/en/licensing/sblicensing/pages/licensing_faq.aspx

    OR

    A detail that does not have these restrictions:

    Where can I still get Windows 7?

    Full version - Microsoft Windows 7 Home Premium

    Version upgrade - Microsoft Windows 7 Home Premium Upgrade

    Family Pack: Upgrade of Microsoft Windows 7 Home Premium Family Pack (3 users)

  • What is the best way to get a comp from AE 2014 to Flash Professional CC?

    I created a training video for 10 minutes for a customer who wants this video for an interactive flash presentation now. Now that the XFL export is no longer an option for AE, what is the best way to get all of the animations in Flash without having to rebuild the entire project?

    The XFL format was not much more than what I mean. The files are huge and for a project that I built in AE by using export, time would have been better spent just making the whole project in Flash.

    In addition, if you are only working in Flash, you can create projects that work on mobile devices and use HTML 5 instead of the traditional Flash Player. And in my never humble opinion the SWF format is dead.

  • Best way to get the content of the 1 page in a lot?

    Hi everyone - I just wanted to check with experts on the best way to get information from 1 html page.  For example, I have a page that shows every 1 '' Ribbons that we have in stock to be used on sandals, belts, bags, etc. dog collars;  (http://elizab.com/eb-1-inchribbons.html) I can do an iframe to pull this html page 1 to all others?  What is the best way to do it?

    Basically I just have to update only one page html (tapes 1 ") and then it is good on all other pages, instead of having me to go through and to update every page that uses ribbons 1" :-)

    I'm not sure what is always taken in charge and what is not recommended on this!

    Thank you-

    Use an SSI. Server Side includes. It's better than an iframe. Google for server-side includes.

    Usually, I use php for inclusions on server side, but your server must support php. If not, you can use .shtml server-side includes.

    You need only to update and download only one file when you want to make changes. So on what page/s you have included the SSI these pages updated as well.

    Although I am a little confused because your field of design takes a page in its entirety. How do you intend to include all of the information on other pages without doubt that contain other information as well?

    I guess that if you only have a small area in which to display all the different designs on your pages, then an iframe is probably the best solution for your because you can define its dimensions.

    Personally I would get really "upset" if I have to keep scrolling left and right and top and bottom, then maybe if you go the route iframe you can arrange at least all the vertical stripes so we don't have to scroll up and down or break designs down into smaller categories to its more manageable for the end user.

  • Opening documents that are in a book (CS4, JS)

    Hello

    Just had a look through the ESTK object model, and I couldn't see a way to open a document that is in a book, through the book (so the script action no would be to open the book file, then by double-clicking the document in question). Can I obivously get the path of the file of a document in the book and open it another way, but I try to avoid the triangle "modified outside the book"document"error during processing and registration of documents that are in a book.

    If anyone has any pearls of wisdom, I'm all ears.

    Thank you.

    Murral wrote:

    ... Can I obivously get the path of the file of a document in the book and open it another way, but I try to avoid the triangle "modified outside the book"document"error during processing and registration of documents that are in a book.

    What I'm missing here? If you have an open book and you can check what are the documents it contains (using BookContents), and possibly to open, you can also edit and then save these docs. No triangles signaling - because the book is also not openen, and you will notice some changes.

    Only if you do something unexpected, as open book, open a document from the book, then close the book before validate your changes... it will earn its triangle of Sue. But then again, he would do the same if you do this manually.

  • Read VeriStand channel from inside the custom device that are not part of the custom device?

    Is it possible to read VeriStand channels from within a custom device VeriStand (RT Driver) that are not part of this custom device?

    For example, suppose I want to be able to configure a channel in my custom device to always be twice the value of a string of material that my user selects (I know, better/more simple ways to do this, but this is just a simple example ).  Can I do this from the device custom without programmatically create a mapping of the system? (I've done this before and it is messy and VERY prone to error of the user).

    Thank you!

    good point

    the channel ID (U64s) are not the same in the engine config of vs. Instead, you must set 'references to dependent item' in the config and then get these references in the engine.

    See the source jarrod linked, which makes it

Maybe you are looking for

  • Your 'change the fonts and colors... '. "Statement said" click (3 horizontal bars) and chose 'options' (in a box)... can not do without this box appears. "

    Due to vision problems, a long time ago I changed the background color for the yellow poster like stark not white. The old system of color choice was fairly easy to change, and one time in a whike I let the colors of the site work like some things we

  • Problems with the registration M Razr on bike rack

    Anyone else having this problem. Whenever I try to register the product it does not. The phone does not appear and if I change it in my Forums profile it just goes back to the Maxx. Any assitance be great!

  • Ex3700 please help at 5 GHz does not

    I've set up ex3700 extender and the face of it seems all connected. However, the connection of 5 GHz said that there is no internet connection. Also, how should I use this optimality. I.e.so my devices select the best connection between 5 GHz or 2 GH

  • activation of VDM 2009 RTE

    I have a machine for development with LabView 2009 PDS and VDM 2009-see screenshot. My understanding is that VDM 2009 comes with a VDM RTE for a computer. I just accidentally enabled this RTE on the NILM development machine, where I don't need. I nee

  • XPS 9100 and 3 TB HARD drive

    This seems to be a common problem, but I can't seem to find a solution that works for me. My system: Win7 x 64 Intel I7 920 8 GB of memory BIOS has been simply upgraded to A04 Intel Matrix Storage Manager v.9.6, A01 installed Intel Matrix Storage Con