How can we tell if SQL*Loader is working on a TABLE?

We have a process that requires comparing batches with LDAP information. Instead of using an LDAP lookup tool, we get a nightly directory file, and import the two COLUMNs we want via SQL*Loader (REPLACE) into an IOT. Out of three cases, two just check the first COLUMN, and the third needs the second COLUMN as well.
We did not think of using External TABLEs, because we cannot store files on the DB server itself.
The question arises, what to do while the file is being imported. The file is just under 300M, so it takes a minute or so to replace all the data. We found SQL*Loader waits until a transaction is finished before starting, but a query against the TABLE only waits while it is actually importing the data. At the beginning of SQL*Loader's process, however, a query against the TABLE returns no rows.
The solution we are trying right now is, to have the process that starts SQL*Loader flip a flag in another TABLE denoting that it is unavailable. When it is done, it flips it back, and notes the date. Then, the process that queries the information, exits if the flag is currently 'N'.
The problem, is, what if SQL*Loader starts inbetween the check of the flag, and the query against the TABLE. How do we guarantee that it is still not being imported.
I can think of three solutions:
1) LOCK the ldap information TABLE before checking the flag.
2) LOCK the record that the process starting SQL*Loader flips.
3) Add a clause to the query against the TABLE checks that there are records in the TABLE (AND EXISTS(SELECT * FROM ldap_information).
The problem with 3) is that the process has already tagged the batches (via a COLUMN). It could, technically reset them afterwards, but that seems a bit backwards.

Just out of curiosity, are you aware that Oracle supplies a DBMS_LDAP package for pulling information from LDAP sources? It would obviously be relatively easy to have a single transaction that deletes the existing data, loads the new data via DBMS_LDAP, and commits, which would get around the problem you're having with SQL*Loader truncating the table.
You could also have SQL*Loader load the data into a staging table and then have a second process either MERGE the changes from the staging table into the real table (again in a transactionally consistent manner) or just delete and insert the data.
Justin

Similar Messages

  • How Can I Run a SQL Loader Job from Schedular

    How Can I Run a SQL Loader Job from Schedular , So that It Runs every Day.

    Depends on a couple of factors.
    If you are on a UNIX platform, you can create a shell script and schedule it with cron.
    If you are on a Windows platform, you can create a batch file and schedule it with the Windows scheduler.
    Or, if you are on Oracle 9i or 10g, you could use the external table feature instead of SQL*Loader. Then you could write a stored procedure to process the external table and schedule it using the Oracle scheduler (DBMS_JOB). This would probably be my preference.

  • My macbook pro no longer connects to my TV with the mini dvi to hdmi adapter. A while ago the computer fell down and hit the cable. How can I tell if the computer is working ok. Doesn't show mirroring any more.

    My macbook pro no longer connects to my TV with the mini dvi to hdmi adapter. A while ago the computer fell down and hit the cable. How can I tell if the computer is working ok. Doesn't show mirroring any more. Was working while watching a movie but when I pulled it out from the computer and put it back in the system would no longer mirrorr the screen on the TV.

    The best option is an appointment at an Apple store genius bar.  The evaluation will be for FREE!
    Ciao.

  • How can I write a SQL statement which checks if a table exists?

    How can I write a SQL statement which tells me whether a table exists?

    execute an sql query: select * from <tablename>
    catch the exception n check whether the erroe code
    matches the one that occurs for table doesn't exist
    that's itHow is your answer any different from the one given in the first reply?
    It isn't.
    As WorkForFood says DatabaseMetaData has a bunch of methods for getting information about tables but this is more useful when you don't know the names of any of the tables.. it sounds like you do so I would concur SELECT from table is probably the quickest way to go. If it helps the Xopen error should be either S1000 or 42S01 (I think) but I would try and see if there is a specific vendor code for table not found/not exists error and check for that.

  • [p7-1240] How can I tell which graphics cards will work with my motherboard?

    I recently went through the nightmare of trying to install a Gigabyte GTX 650 in my PC. After a few days of struggling and scouring the internet for answers, I discovered that it is incompatible with the BIOS on my motherboard, and HP does not offer BIOS updates. I returned the card and am now looking for a new one, but I am unsure of which cards will work now, since my computer met all of the system requirements for the graphics card, and It stil ldid not work. Since GPU manufacturers do not list BIOS specs under system requirements, how can I tell if a graphics card will work with my sytem?
    My computer is a p7-1240 with an upgraded 520W PSU and approximeately 11" of room to install the card.
    This question was solved.
    View Solution.

    Thexn, welcome to the forum.
    The problem is, many of the newer video cards require the computer to have a full UEFI BIOS.  HP began using one in mid-October, 2012.  Before this date the BIOS is Legacy.  This is why the video card didn't work with your computer.
    I don't know what you want to spend for a card, but MSI makes a GTX 750ti that has a hybrid VBIOS.  It has a switch to change to Legacy or UEFI.  There is a video link directly below the picture of a card.  Paul from Newegg gives a full description of the card.
    I like EVGA cards the best.  Their Tech Support has given me a lot of information about their cards.  However, you have to go back to a GT 640 card to find one of their cards that doesn't require the UEFI BIOS.  They do have some updates for their BIOS'es that solve the problem, but you have to call them for the exact cards.
    Please click the "Thumbs up + button" if I have helped you and click "Accept as Solution" if your problem is solved.
    Signature:
    HP TouchPad - 1.2 GHz; 1 GB memory; 32 GB storage; WebOS/CyanogenMod 11(Kit Kat)
    HP 10 Plus; Android-Kit Kat; 1.0 GHz Allwinner A31 ARM Cortex A7 Quad Core Processor ; 2GB RAM Memory Long: 2 GB DDR3L SDRAM (1600MHz); 16GB disable eMMC 16GB v4.51
    HP Omen; i7-4710QH; 8 GB memory; 256 GB San Disk SSD; Win 8.1
    HP Photosmart 7520 AIO
    ++++++++++++++++++
    **Click the Thumbs Up+ to say 'Thanks' and the 'Accept as Solution' if I have solved your problem.**
    Intelligence is God given; Wisdom is the sum of our mistakes!
    I am not an HP employee.

  • How can I only install Sql loader tools in my compupter?

    Hi all,
    I don't have sql loader in my computer and I just want to install sql loader in my computer without affect my computer's setting (oracle),how can I do this?
    Thanks

    Install Oracle Client in another Oracle Home.

  • How can I invoke a sql loader from oracle form?

    I'm got a problem on invoking sql loader command from oracle form where the sql loader product has been installed in Window NT.
    Thanks for your help!

    U can use HOST procedure with NO_SCREEN option.
    this will go like
    Host('d:\orant\bin\SQLLDR80 USERID=username/password@connect CONTROL=contril_file.CTL LOG=log_file.LOG discard=discard_file.dis bad=bad_file.bad', NO_SCREEN);
    Hope this will Work
    Good Luck :-)
    Naren

  • How can I tell if the ssd is working properly?

    I suppose to have a 32gb mSata SSD.
    How can I check to see if I have it and how do I check to see if it's functioning properly?

    Hello xmarine, welcome.
    What is the make and model of your HP computer, operating system?
    Let us know,
    Thanks!

  • How can I tell if my cluster is working?

    This seems like a question I should know the answer to, but I set up a quickcluster and can't tell if both machines are actually processing the job or if only one machine is.
    In the old version of compressor, I had qmaster in the bar which turned green if it was working.

    I should mention that on my laptop (connected via ethernet and both machines are talking to each other), which is the secondary machine, when I open the Share Monitor, it can "see" the batch via the cluster.
    It just doesn't really seem like it's doing anything else.

  • How can I tell if my ram is working in duel mode?

    I would I be able to tell if ym ram is working in duel mode? My system is in my sig

    You can use CPU-Z. When you boot up look at the post screen, hit the Pause key to, well, pause the process so you can read it. It'll say dual liner mode, I believe.

  • How can I tell if Firefox Sync is working?

    I'm not certain Sync is working. How can I check?

    I should mention that on my laptop (connected via ethernet and both machines are talking to each other), which is the secondary machine, when I open the Share Monitor, it can "see" the batch via the cluster.
    It just doesn't really seem like it's doing anything else.

  • Pls any one can tell about sql loader in linux?

    Pls any one can tell about sql loader in linux

    Hi,
    I don't think it matters which OS, sqlloader works the same for all OS. If you want more information, read first the manual: http://download.oracle.com/docs/cd/E11882_01/server.112/e16536/ldr_concepts.htm#i1005437
    Herald ten Dam
    http://htendam.wordpress.com

  • How can I tell what is "Auto Launching"

    User's (me) tech background:
    Fairly technical user here, but getting pretty rusty. In a past life (late '90s) I was a network administrator as well as server admins for NT 4, Novell (up to 4.11), AIX, and HP-UX servers. Used to be really good at a command prompt ($ or #) in AIX and HP-UX as well as MS DOS. I do have ROOT enabled on my Macs and I am not afraid to use it. However, I know how severe the consequences can be (trashed a customer's AIX server once using a -R switch in the root directory), so I am extremely cautious and must be confident of the instruction. Can probably fix most anything with some guidance........
    Here is the problem........ I have recently developed an error on boot, say within the last couple of weeks, where it tells me that some Vista application won't run because VM Ware will not initialize. The problem is VM Ware is not loaded on this computer (15" MBP model 8.2, i7 processor, 16MB of RAM, OS 10.7.4........ bought as a "refurb", never had a problem, have used this workstation for several months now). Boot Camp is not configured on this machine either. Nothing is in the Dock that would knowingly trigger this. When I go into System Information, I find nothing set as a "Startup Item" (screen shot attached) , making me think that I am looking in the wrong place. Where should I be looking?
    Interesting enough, when I go to System Information, and look under "Applications", I do see a lot of Vista items, including apps from an older MBP that I do not connect to (on same network, they have "rights" to connect, I just never do as there is nothing on there I need). I have attached a screen shot of this as well.
    Please, someone, can you give me some advice here?
    How can I tell where this auto loading of this Vista app is coming from
    How do I get rid of it
    Why did it happen "suddenly"?
    Can I go into System Info/Applications and delete any Vista or VM Ware apps?
    If I cannot do this via "System Info" can I remove (rm OR mv) the files from whichever system directory stores this data?
    This is puzzling and quite concerning. I would be deeply grateful if there is a "Yoda" out there that knows how to fix this.......
    Thanks in advance,
    Bill

        Managing your data usage is very important Bag02231958. I would like to thank ttipgem for the great suggestion to see what is using data on your phone. However, when you access the internet, social media apps, stream data, videos, music, etc. that uses data on your phone. Unfortunately, we do not have a list of what specifically is being accessed on the device to incur data. You do have the ability to view data records and time frames online via My Verizon http://bit.ly/xB4iTc
    Thank You,
    MichelleL_VZW
    VZW Support
    Follow us on Twitter @VZWSUPPORT

  • How can I tell if a sound is playing in Flex application?

    Hi All,
    Simple question but I can't seem to find an answer to. How can I tell if my Flex application is currently playing sounds from a SWF file?
    What I'm trying to do is load a SWF file dynamically into my Flex app. However, these SWF files have sounds in them and they don't seem to stop even after I unload the SWF files.
    I'm trying to get around this by stopping all sounds using the flash.media.SoundMixer.stopAll() but it's getting called too early, before the SWF files are fully loaded and rendered in the application.
    I searched around and it seems like many people are having issues with this. Maybe someone can help me find a solution.
    Thanks,
    Colin

    In player 10 you can use unloadAndStop()
    Alex Harui
    Flex SDK Developer
    Adobe Systems Inc.
    Blog: http://blogs.adobe.com/aharui

  • How can we tell if a VI is already running before calling Start Asynchronous Call?

    The new Start Asynchronous Call node is awesome for spawning multiple instances of reentrant VIs.  However, I've stumbled a bit in using it for non-reentrant VIs.  The old practice of using the "Run VI" method would allow us to check the Execution.State of the VI before invoking the method to run it.  That way if the State was Running or Run Top Level, we could skip the invoke node and just use a property node to open its front panel.  WIth the Start Asynchronous Call node, it looks like we have to use a strictly typed static VI reference, and when we open the VI reference, the VI gets reserved and its Execution.State = Running.  So, how can I tell if it is not just reserved by the thread but actually executing before making a redundant Start call?
    By the way, the redundant Start has interesting behavior.  It will actually cause the targeted VI to be executed again after it stops.  Even if you hit the Abort button on the target VI, it will immediately execute again and again equal to the number of times the Start Asynchronous Call node was run.  There's nothing wrong with that, and I suppose the simple answer is to just go back to using the old "Run VI" method.  It's just that the ability to wire up those inputs directly to the connector pane is so nice.  Perhaps I am missing something obvious.  Oh, I am referring to the Call and Forget mode (0x80).
    Thanks,
    Dan
    Solved!
    Go to Solution.

    Just throwing it out there, I know I'm a year.5 late on this but if it's a psuedo-modal dialog or some other window that you only want a single instance visible at one time, you can check the FP.State property on the strictly typed vi reference. If it's loaded and visible to the user it will be "Standard", if it was closed or not opened prior then the state will be "Closed".
    I think the standard behavior of serializing execution on another thread would be great for doing a pre-set number of iterations with a sub vi in a non-blocking sort of way but for sub vi's meant for UI interaction checking FP.State works.
    Philip
    CLD

Maybe you are looking for

  • My mac wont recognize any of my devices

    I have recently updated my phone from a 4 to iphone5 and was in the process of trying to transfer pics from old phone to mac. Now my mac will not recognize any of my devices finder, image capture, iphoto....it does however show up in itunes when plug

  • Problem in putting the query condition for negative stocks.............

    Hi, I am applying condition to display negative stocks. Situation is like In the columns , I have key figure stock quantity and stock status(QI , blocked etc) Accordning to the stock status column is created and all the materials are displayed for th

  • SLD to SMSY synchronization - Which product version do we have to choose ?

    Hello, We do have a CPP system running on SAP ECC 6.0 version. 1. In SLD, we do have the list of all "Software Components" used in CDP.     We do not have the "PRODUCT VERSION" of the managed system. 2. With job SAP_SLD_DATA_COLLECT (RZ70), all data

  • Primavera P6 R8.3 DBSETUP BLANK WINDOW

    Hello, I have a configuration problem: While installing P6 R8.3 database I can not see the information inside the "Configuration Window" (the 5th step after "Create SQL Server User" I should see "Application User", "Load sample data" and "Currency".

  • I am unable to email pdf files. Cant print them either

    I am unable to email PDF files or print them. This happened after i upgraded my Adobe. I have deleted the program and reinstalled several times.