Problem addition thanks to a For loop

I have the following diagram, set up to make the amount of a fourier series, given the tables containing the coefficients.  The coefficients are determined externally, loaded into a table, then "n" is changed for each iteration and the results, summed up with any other "n" 1 to 5 now.

Everything looks good, but the loop isn't adding up the results.  Can someone point me in the right direction to solve this problem?  All this is in a case at the moment structure so that I can run the vi, the load factors, and then run the loop for.

ben64 wrote:

Thus, the feedback node must be avoided as much as possible.

Sometimes I disagree with this statement (and feeling).  I don't 'avoid' a lot of things in LV, not same inhabitants.  I understand the options and apply to one that works at any given time.  It happens that the inhabitants are not the best option in almost all cases.  Comment nodes are much more useful than the locals, and you lack much avoiding them.  They must be respected, understood, but not to fear.  In the case of ease of use, they can often be traded for a quarter of the common register and LV will do for you.  Comment nodes have other important features which make them useful in some cases.  The ability to exist without the loop, so no more single iteration while loops just to hold a registry change is a good example.  Initialization with a table is another.  More help and some topics of the forum for a discussion.

In this case, the fundamental flaw is that the FN must be inside the loop.  Fixing ben64 example shows how it's done.

No difference between SR and FN in this case, but no reason to avoid it.  In fact, in most of the new code I write I tend to favour the FN since they often shorten wiring and everything I can do with an SR can I do with a FN but not vice versa.

Tags: NI Software

Similar Questions

  • Problems for additional download BB JRE for Eclipse plug-ins, JDE

    Hello

    I already posted my problem in another thread, but I don't have all the answers. As it is very important to me, I wanted to try with a new thread.

    I downloaded the BlackBerry JDE Plugin for Eclipse and now I tried to download additional JRE of BB. So I added the URL http://www.blackberry.com/go/eclipseUpdate/3.5/java repository. When you try to download the "JRE 5.0.0" I get prompted for a user name and password. This I tried several times with the username and password of the BB Developer Zone, but it does not work. He always tells me that the connection information is incorrect. What could be the problem? What I do use other connection information, or do I have to register somewhere else?

    Thanks in advance for your answer!

    Concerning

    jtr87

    Hello

    Thanks again for your response. I solved the problem URL I used was bad. I found the URL in another thread here and it seems that it is just out of date. So far, I have used the URL

    http://www.BlackBerry.com/go/eclipseUpdate/3.5/Java

    to download additional JRE of but the right URL is for Version 1.3

    http://www.BlackBerry.com/go/eclipseUpdate/3.6/Java

    Thanks again for your help!

    Concerning

    Roland

  • Problem on the out of the loop For of Cluster

    Hello!  I'm using Labview 2009.

    I have a problem in the transmission of the indexed number of a loop through function array-cluster to a cluster. Please check my attachment... The problem is, he always says the number of items in the numbers indexed is 9, any number of loops, I input for loop.

    This problem has been solved before? I could not find any related post here...

    Raymond

    Hey Vg,

    You have to right click on your table to the cluster, goto 'Size of Cluster' function and select, in this case, 2.

    RGS,

    Lucither

  • for loop in formula node does not

    Hello

    I; m trying to use for loop in the node of the formula, but it is does not work. I want the output (y1) product value in certain range (a and d, and of course one is smaller than d). I ' do not use primitive labview since a and d are keep changing (both are variable). I tried to put "return 0;" after the y1 equation but the error popup.

    The issue of the loop works not because it gives the last value (I average would be ""). It does not begin with an (initial) value.

    Please help me how to solve this problem...

    Pls ignore other variables not used in the equation. Thank you!! A lot

    Your code works.

    But why you use loop?
    You get the last value, so you can get it in a single step with x correct;

    Also why you say that can not use primitives?
    If you use wire instead of terminals or local variable States values constant.

    Y1, y1_2, y1 3 is the same values calculated differently.

  • parallel for loops does not

    Hello.

    I'm learning the multi - thread programming. To start, I use "parallel for loops" and I was surprised that it does not work. One - thread loop work a few times faster (depending on settings) that multi - thread. I don't know why, and it is my request to correct my Vi to work properly.

    Lenovo, G580, Windows 7, 64-bit computer

    Intel Core i7 3632QM
    Ivy Bridge
    Specification Intel (r) Core i7-3632QM CPU @ 2.20 GHz
    Package (platform ID) Socket 988 B rPGA (0x4)
    Number of hearts 4
    Number of threads 8

    LabView 2011.

    Altenbach says:

    Gibbon wrote:

    What was 'strange' behavior?  In "linia dluga" when inside the loop is on '1' of the "spreed up' between one and multi-fil is about 3 times, when I put it in '20' this grow to 6.2. It was strange form me, becourse I expect a similar value.

    A parallel FOR loop has an overhead for parallelization (split the problem, then go back the results, etc.). If the code is very fast, the overhead is proportionally larger. If the Subvi takes a long time to complete, the overhead of parallelization is insignificant. It is often not worthwhile to parallelize the loops with a very simple and fast code.

    Gibbon wrote:

    Altenbach - I have another question if you can help me - how did you "seconds relative high resolution." VI "? -I want to say how did you know that there is this 'vi '. And thanks a lot for your modyfications.

    You can find it in vi.lib\utilities. It is well known.

    Maybe not well known enough!  the 'Hidden gems' package adds to your palattes.  It has also been considered by a nugget of the community

  • Creating tables in a nested for loop

    Hi all.

    I was stuck in this problem for quite a while now and I still don't know how to continue. Some outside the entrance would be greatly appreciated!

    I'm doing the following:

    -Take an array of numbers, to check if they are within a certain range (e.g. between 2 and 4)

    -Build two new arrays: one with all the numbers that are inside the beach and the other with the rest.

    An additional condition is that the amount and value of the range conditions will change (for example, it could be between 2 and 4 only / 2, 4 AND 6 and 7 according to the entry)

    To treat this, I created two nested for loops - one that goes on a table that contains conditions of the beach and inside that actually go and check if the values are in the range. I think I did that part successfully, but the next part is confusing to me - how to actually create the tables separated within two loops for?

    My apologies if I did not explain it well. Another method to support this problem is I want to translate following LabVIEW:

    Ranges of table / / [1 5 7 10] exodus-> This means we want to divide numbers based on those who are in (1,2) and (4.5) against those who are not

    Table of values / / [2 3 6 11 3]

    EndOperationDelegate table / / array of values within the range
    Table outValues / / Array of values out of range

    for m = 1:size (ranges)

    for n = 1:size (values)
    If (THE NUMBER IS on the INSIDE of EACH RANGE)
    EndOperationDelegate = [EndOperationDelegate NEWNUMBER]
    on the other
    outValues = [outValues NEWNUMBER]
    end

    end
    end

    Sounds easy enough, but it gets so chaotic with Labview that I don't know what to do. I have attached a reference image - insertion in the array function is not in fact add to the table, it creates a new table. How can I save that for when the nested for the ends of the loop?

    I have seen a few examples with shift registers which lie in a loop and I couldn't successfully that transfers in my block diagram.

    Any help/direction would be greatly appreciated.

    Hello!

    See the following example to understand how you can create a table in the loop For

    In your case, you also can uce conditional terminal to create a table only when then located nearby. It makes the code much cleaner that the structures of the case

    Hope this helps, if not, let me know if I can help you!

    Marcin

  • jump on a for loop

    Hi guys,.

    I have the impression that this is a stupid problem and know the solution if probably obvious, but I can't seem to find it

    I have a loop with several inputs and outputs in a Subvi.  When the Subvi is run all entries are read, the loop is skipped, and the outputs are sent.  Does anyone have any idea why the for loop is ignored?  Everything seems to be wired corretly?...

    The vi is attached.

    Thank you!
    Christopher

    I can't open your code due to my having LabVIEW 2009, but here's one thing to check: do you have automatic indexing on at all?  Perhaps, he does not run the expected amount of time due to a table being wired like 'auto-index' to your loop for?

    Another thing to check is try to place an indicator on the output of the variables 'N' and 'i' of the loop (letters of blue boxes that appear automatically).  That should tell you the "N" land of shadow of time it will perform an iteration and the value of the current 'i' reiteration.

    When you use the execution to highlight, you see it execute the code inside the loop?  If so, how many times?  And how did you expect?

  • Capture of sequences of images - issues with nested for loops

    Hi all

    I've written a vi. to capture a number of images ("Image") and save these images, sent to a folder of my choice.  Each image is identified sequentially.  However, I would like to make a number of iterations ("run") of this capture sequence, such that each image file name would be "Filename (Run) _(Image_No).png", for example run 5, image 10 'Filename 5_10.png.  I tried a nested for loop for this but I have an error message 'Current asynchronous i/o Operation' (I have attached a printscreen).

    Can someone help me solve this problem?  Please find attached my vi.

    Sincere greetings and thanks,

    Miika

    Hi toto26,.

    Thank you for your response.  I solved the problem by using a sequence structure flat - file in the first image and all the treatment in the second.

    Kind regards

    Miika

  • Parallel for loop 2D table

    Hello

    I don't have any experience with parallel for loops, so I need your help.

    Goal: To do a calculation (average, average) on the rows (or columns) table 2D as quickly as possible. The calculations are independent of each other and I would get a table 1 d with the results.

    I read a few posts on parallel for loops and I would like to find an example for my trivial problem, but I can't.

    Could you help me, it is possible is improve it the effectiveness of the calculation on lines with parallelism in LabVIEW? and it is, could you post an example how to do?

    Thank you

    If the speed issues, do not write your own "average." First of all, it already is in the range of statistics, but then you must be inline your average VI or do the calculation explicitly (as shown below). the size of the array never changes for the duration of the loop, it seems redundant to get the size of the array on each iteration.

    Here's what you could do.

    On my bench, it's much faster than the use of 'mean.vi' of the palette. Average a overhead, Subvi (1) (2) needs to get N with each call and (3) is also an unnecessary error checking.

    (Sorry, I have 32 processors, so the number of instances is set a little high. Modify if needed).

  • Windows XP: I have 448 MB of RAM available. What happened to the 64 MB of RAM lack and how can I solve this problem. Thank you

    I am trying to install application constant guard Internet Security of Comcast.  After trying to download and install the product, I get and RAM error message indicating I need 512 MB of RAM to install this product, and I only have 448 MB of RAM available.  What happened to the 64 MB of RAM lack and how can I solve this problem.  Thank you

    The only way to see more of RAM is to install a graphics card and disable the onboard graphics of your motherboard. If you do this, you should be able to see all the 512 MB of it.

    That being said, I will repeat what I said before...
    You can always buy more RAM and install it on your motherboard. Go to crucial.com for more information.
    In addition, you should review install 'Internet Security' application or suite. They are not necessary (you can easily configure Windows so that it is very safe) and they often ruin the performance of a PC.
    If you want advice in "hardening" your PC security, let know us.
  • Create a directory tree: how to call a global function from inside a for loop

    Hello

    I am trying to create a workflow that will create a directory tree in vCenter.

    Concept:

    Basically, I am trying to execute nested for loops for each level of the tree to the caller a global tree.

    Problem:

    The 1st loop for works and creates the file 'Dev '.  The second loop for does not work with error message:

    [19:16:16.219 2013-06-27] [I] building Dev folder
    [19:16:16.474 2013-06-27] [I] directory Built: Dev
    [19:16:16.476 2013-06-27] [I] the records building servers
    [19:16:16.480 2013-06-27] [I] TypeError: cannot find the createFolder function in dev object. (Workflow: TEST_TNG_New_Site_Folder_Structure / Scriptable task (item2) #36)

    I think it has to do with JavaScript not being not able to call a global function in a nested object (I'm not a programmer and don't know JavaScript, so don't shoot me on that :)

    Code: (will clean this up once I do work)

    var folderBase is ['Dev', 'DMZ', 'Prod', 'UAT'];.

    var folderT1 = ["servers", "Jobs"];

    var folderT2 = ['Window', 'Linux'];

    var folderT3 is ["Repo2', 'Repo3', 'Repo1', 'Repo4'];.

    var folderT4 is ["T1", "T2", "T3"];.

    Create the files folderBase level

    for (var i = 0, l = folderBase.length; i < l; i ++) {}

    var rootFolder = parentFolder;

    buildFolderTree (folderBase [i]);

    Create the files folderT1 level

    for (var j = 0, l = folderT1.length; j < l; j ++) {}

    var rootFolder = folderBase [i];

    buildFolderTree (folderT1 [j]);

    Create the files folderT2 level

    for (var k = 0, l = folderT2.length; k < l; k ++) {}

    var rootFolder = folderT1 [j];

    buildFolderTree (folderT2 [k]);

    Create the files folderT3 level

    for (var x = 0, l = folderT3.length; x < l; x ++) {}

    var rootFolder = folderT2 [k];

    buildFolderTree (folderT3 [x]);

    Create the files folderT4 level

    for (var y = 0, l = folderT4.length; y < l; y ++) {}

    var rootFolder = folderT3 [x];

    buildFolderTree(folderT4[y]);

    }

    }

    }

    }

    }

    function buildFolderTree (folderName) {}

    System.log ("Building folder" + folderName);

    rootFolder.createFolder (folderName);

    System.log ("directory of frame:" + folderName);

    }

    Any help will be appreciated.

    Thank you

    B

    Hello

    The createFolder() method returns the object VcFolder to the folder just created, for the new file to be used immediately.  Here is how I modified the code:

    Create the files folderBase level
    for (var i = 0; i)
    var newBaseFolder = buildFolderTree (parentFolder, folderBase [i]);
    Create the files folderT1 level
    for (var j = 0; j)
    var newT1Folder = buildFolderTree (newBaseFolder, folderT1 [j]);
    Create the files folderT2 level
    for (var k = 0; k)
    var newT2Folder = buildFolderTree (newT1Folder, folderT2 [k]);
    Create the files folderT3 level
    for (var x = 0; x)
    var newT3Folder = buildFolderTree (newT2Folder, folderT3 [x]);
    Create the files folderT4 level
    for (var y = 0; y)
    var newT4Folder = buildFolderTree (newT3Folder, folderT4 [y]);
    }
    }
    }
    }
    }

    function buildFolderTree (parentFolderObj, folder_name) {}
    System.log ("Building folder" + folderName);
    var newFolder = parentFolderObj.createFolder (folderName);
    System.log ("directory of frame:" + folderName);
    return NewFolder;
    }

  • PLSQL cursor for loop - no_data_found exception

    Hi all

    Please, could you help me. I start to learn PL/SQL, so please be pattient.

    the very simple block. Base table emp (for Oracle), he sucks with more then 5000 large salary. I thought that the result would be "aaa", but result is actually empty.

    declare
      cursor c1 (v_num number) is
        select ename,sal
        from emp
        where sal > v_num;
    begin
      for rec in c1(5000) LOOP
        begin
        dbms_output.put_line('Employee: ' || rec.ename || ' has a salary of ' || rec.sal);
      exception
      WHEN NO_DATA_FOUND THEN
        dbms_output.put_line('aaa ');
      end;
      END LOOP ;
    end;
    /
    
    

    How can I solve this problem?

    Thank you much for the help.

    With the help of a cursor for loop will never throw an exception no_data_found.

    Despite everything, you try to catch all exceptions thrown by dbms_output.

  • Nested for loops error

    Hi all members of the community, I am experiencing problem with pulling the attributes of an xml I created. I use nested for loop. Please kindly help me to solve this problem...

    Thanks in advance...

    Here's the code & xml...


    import flash.events.Event;
    import flash.events.EventDispatcher;
    import flash.events. *;
    flash.net import. *;

    var myXML:XML;

    var voiceOver: String;
    var startOffset:Number;
    var slideData:Array;
    var id_cont_array:Array = new Array();
    var id_textfield_array:Array = new Array();
    var id_image_array:Array = new Array();

    var myXML_Container_Length:Number;
    var myXML_textField_Length:Number;
    var myXML_images_Length:Number;

    var loader: URLLoader = new URLLoader();
    Loader.Load (new URLRequest ("dynamic.xml"));

    loader.addEventListener (Event.COMPLETE, processXML);

    function processXML(e:Event):void
    {
    slideData = new Array();
    myXML = new XML (loader.data);

    loader.removeEventListener (Event.COMPLETE, processXML);
    loader.removeEventListener (IOErrorEvent.IO_ERROR, loadError);

    myXML = new XML (e.target.data);
    voice-over = myXML. @ voice_over;
    startOffset = myXML. @ start_offset;

    for (var i: uint = 0; i < myXML.*.length (); i ++)
    {
    trace (myXML + 'slide');
    }


    myXML_List = myXML.children ();
    myXML_Container_Length = myXML.children () .length ();
    trace (myXML_Container_Length + "is myXML_Container_Length")
    myXML_textField_Length = myXML.containerss [0] .children () .length ();
    myXML_images_Length = myXML.children () .length ();
    trace (myXML.Child ("containerss") [3]. @ id.toXMLString () + "== myXML.containerss [0].") @ id; ») ;
    trace (.textfield myXML.containerss [0] [0]. @ id + "== myXML.slide.containerss [0].") ("@ id");
    trace (myXML.containerss [0] .textfield [1]. @ id + "== myXML.slide.containerss [1].") ("@ id");
    trace (myXML.containerss [3] [0] image. @ id + "is image [0]");
    trace(myXML.containerss[0].) Children() + "== myXML.containerss [0] .children ()"); "."

    for (var j: Number = 0; j < = myXML_Container_Length; j ++)
    {
    id_cont_array.push (myXML.containerss [j]. @ id);
    trace (myXML.containerss [j]. Children () .length () + 'is j');
    myXML_textField_Length = myXML.containerss [j] .children () .length ();
    trace (myXML_textField_Length + "is myXML_textField_Length");
    for (var k: Number = 0; k < = myXML_textField_Length-1; k ++)
    {

    id_textfield_array.push (.textfield myXML.containerss [j] [k]. @ id);
    id_image_array.push (image of [k] myXML.containerss [j]. @ id);
    trace (id_textfield_array [k] + "== id_textfield_array [k] ==" + k + "--j ==" + j);
    trace ("== id_image_array" + id_image_array [k]);
    }
    trace(id_textfield_array[j]+"==id_cont_array[j]");
    }

    trace (myXML_List.length () + "= myXML_List");

    }

    function loadError(e:IOErrorEvent):void
    {

    trace ("loadError");
    }

    XML is as below...

    < drag direction = "VERTICAL" voice_over = "Slide1.mp3" start_offset = "0" margin ="" > "

    < set id = "0" direction = "HORIZONTAL" padding = "10" margin = "10" x = "10" y = "160" width = "200" height = "150" >
    < textfield id = "Text1" text = "textfieldText1" padding = "10" margin = "10" x = "10" y = "160" / >
    < image id = "img1" text = "" padding = "10" margin = "10" x = "10" y = "160" / > "
    < textfield id = "Text2" text = "textfieldText2" padding = "10" margin = "10" x = "10" y = "160" / >
    < / define >
    < set id = "1" orientation = "HORIZONTAL" padding = "10" margin = "10" width = "200" height = "200" x = "10" y = "160" >
    < textfield id = "Text3" text = "textfieldText3" padding = "10" margin = "10" x = "10" y = "160" / >
    < image id = "img2" text = "" padding = "10" margin = "10" x = "10" y = "160" / > "

    < / define >
    < set id = "2" orientation = "VERTICAL" padding = "10" margin = "10" width = "200" height = "150" x = "10" y = "160" >
    < textfield id = "Rem5" text = "textfieldText5" padding = "10" margin = "10" width = "200" height = "150" x = "10" y = "160" / >
    < image id = "img3" text = "" padding = "10" margin = "10" x = "10" y = "160" / > "
    < textfield id = 'Text6"text ="textfieldText6"padding ="10"margin ="10"x ="10"y ="160"/ >
    < / define >
    < set id = "4" orientation = "VERTICAL" padding = "10" margin = "10" width = "200" height = "150" x = "10" y = "160" >
    < textfield id = 'Text7"text ="textfieldText7"padding ="10"margin ="10"width ="200"height ="150"x ="10"y ="160"/ >
    < image id = "img4" text = "" padding = "10" margin = "10" x = "10" y = "160" / > "
    < textfield id = "Texte8" text = "textfieldText8" padding = "10" margin = "10" width = "200" height = "150" x = "10" y = "160" / >
    < / define >
    < / slide >

    The analysis is totally false. You operate processXML() should be like this:

    function processXML(e:Event):void
    {
              slideData = new Array();
              loader.removeEventListener(Event.COMPLETE, processXML);
              loader.removeEventListener(IOErrorEvent.IO_ERROR, loadError);
              myXML = new XML(e.target.data);
              voiceOver = myXML.@voice_over;
              startOffset = myXML.@start_offset;
              myXML_Container_Length = myXML.children().length();
              var node:XMLList;
              for (var j:Number = 0; j <= myXML_Container_Length - 1; j++)
              {
                        id_cont_array.push(myXML.containerss[j].@id);
                        node = myXML.containerss[j].children();
                        myXML_textField_Length = node.length();
                        for (var k:Number = 0; k <= myXML_textField_Length - 1; k++)
                        {
                                  switch (node[k].name().toString())
                                  {
                                            case "textfield":
                                                      trace(node[k].@id);
                                                      id_textfield_array.push(node[k].@id);
                                                      break;
    
                                            case "image":
                                                      id_image_array.push(node.@id);
                                                      break;
                                  }
                        }
              }
    }
    
  • How to set a variable in a table to grid 'for' loop

    I'm afraid I'm stuck again!

    The next step in the animation I'm working on, is to set up a Boolean value, 'pierced = false', so that all instances of the attachMovie ("openCircle") have a Boolean "drilled = false' associated with them." Then when someone clicks on one of the instances of the attachMovie ("openCircle"), the Boolean value becomes "pierced = true', but only for that instance was clicked."

    What I've done is to set the (Boolean) variable (highlighted in bold below) in the two 'for' loops through the table in the grid, but it returns an undefined value. Do I need to configure a separate table? (see code below):-

    set up the grid for solid table

    spacing: var number = 5.75;

    Var CDL: number = 20; the number of columns in the grid

    var rows: number = 20; number of grid lines

    var leftMargin:Number = 154;

    var topMargin:Number = 169;

    depth: var number = 100; starting point for the depth

    var drilled: Boolean;

    for (i = 1; I < = lines; i ++) {}

    for (j = 1; j < = cols; j ++) {}

    drilled [rows, cols] = false;

    trace (drilled);

    current = attachMovie ("openCircle_mc", "openCircle_mc" + i + "_" + j, depth ++);

    Current._x = leftMargin + ((i-1) * (spacing + current._width));

    Current._y = topMargin + ((j-1) * (spacing + current._height));

    Current.Row = i;

    Current.Col = j;

    Current.Oil = Math.floor (Math.random () * 1.1);  about 1/10 objects have oil = 1, 9/10 oil = 0

    Open the circle initially invisible, visible on rollover

    Current._alpha = 0;

    {current.onRelease = function ()}

    trace (this.row + "" + this.col);

    current.drilled = true;

    }

    current.onRollOver = function() {}

    This ._alpha = 100;

    }

    current.onRollOut = function() {}

    This ._alpha = 0;

    }

    }

    }

    I would be grateful for any help. Thank you.

    Then, create a two dimension table named drilled so that it exists when you try to fill...

    var drilled: Array = new Array (new Array();

    There might be a problem that you're missing setting the values of the [0, #] components of the table - paintings begin with an index of 0.

  • Problem with "select * from table" for dynamic IN the list

    I have a 'for loop' based a query that does not work. The query is supposed to return the name of the table, the data type and the name of the column in the columns poses a number of name filters. The problem I have is when I run the query into a TOAD with:

    schema_list value SCOTT, MED and the clause of 'in' as ' to (select * from table (DATAPUMP_UTIL.in_list_varchar2 (:schema_list))))»

    The query returns the expected lines.

    When I have it in my code as shown below it returns no rows. I don't know what hurts me, but any help would be great! I'm on Oracle 11.1.0.6.0.
    PROCEDURE export_schema_ondemand (schema_list VARCHAR2, encrypt_file NUMBER default 0, mask_sensitive_data NUMBER default 0) IS  
        ...
        schema_list_t := my_package.in_list_varchar2(schema_list);
        ... 
        for c1 in
           (
            with ok_to_mask as (
            select 
                owner,
                table_name, 
                column_name
            from   
               all_tab_columns
            where
                owner in (select * from table(schema_list_t))
            minus
            (SELECT 
                c.owner,
                p.table_name,
                cc.column_name
            FROM 
                all_cons_columns cc, 
                all_constraints p,
                all_constraints c
            WHERE 
                c.owner in (select * from table(schema_list_t))
                c.constraint_type = 'R'
                AND p.owner = c.r_owner
                AND p.constraint_name = c.r_constraint_name
                AND cc.owner = c.owner
                AND cc.constraint_name = c.constraint_name
                AND cc.table_name = c.table_name
            UNION ALL
            SELECT 
                c.owner,
                cc.table_name,
                cc.column_name
            FROM 
                all_cons_columns cc,
                all_constraints p,
                all_constraints c
            WHERE
                p.owner in (select * from table(schema_list_t))
                AND p.constraint_type in ('P','U')
                AND c.r_owner = p.owner
                AND c.r_constraint_name = p.constraint_name
                AND c.constraint_type = 'R'
                AND cc.owner = c.owner
                AND cc.constraint_name = c.constraint_name
                AND cc.table_name = c.table_name))
            select 
                atc.table_name as mask_tab, 
                atc.column_name as mask_col, 
                atc.data_type as mask_type
            from   
                all_tab_columns atc,
                ok_to_mask otm
            where
                atc.owner = otm.owner
                and atc.table_name = otm.table_name
                and atc.column_name = otm.column_name
                and atc.owner in (select * from table(schema_list_t))
                and 
                (
                atc.column_name like '%LAST%NAME%'
                or atc.column_name like '%FIRST%NAME%'
                or atc.column_name like '%NAME_LAST%'
                or  atc.column_name like '%NAME_FIRST%'
                or  atc.column_name like '%ENAME%'
                or atc.column_name like '%SSN%'
                or atc.column_name like '%DOB%'
                or atc.column_name like '%BIRTH%'
                )
                and atc.column_name not like '%PHYSICIAN_%'
                and atc.column_name not like '%DR_%'
                and atc.column_name not like '%PROVIDER_%'
                and atc.column_name not like 'PRESCRIBER_%'     
           )
          loop
             ...
    
    FUNCTION in_list_varchar2 (p_in_list  IN  VARCHAR2)  RETURN VARCHAR2_TT is
    
        l_tab   VARCHAR2_TT := VARCHAR2_TT();
        l_text  VARCHAR2(32767) := p_in_list || ',';
        l_idx   NUMBER;
            
    BEGIN
        LOOP l_idx := INSTR(l_text, ',');
            EXIT WHEN NVL(l_idx, 0) = 0;
            l_tab.extend;
            l_tab(l_tab.last) := TRIM(SUBSTR(l_text, 1, l_idx - 1));
            l_text := SUBSTR(l_text, l_idx + 1);
        END LOOP;
    
        RETURN l_tab;
            
    END in_list_varchar2;
    Published by: BluShadow on June 29, 2011 16:11
    addition of {noformat}
    {noformat} tags.  PLEASE READ {message:id=9360002} TO LEARN TO DO THIS YOURSELF.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    

    Hello

    If you have a query that works well when you launch it directly, and that breaks down when you start with a procedure, this can be a problem of privileges.

    Points of view ALL_ * shows only the objects you have access, but using a procedure, privileges must be granted directly to the user and not with a role.

    You should check the SELECT privileges to your user through roles and give them directly to the user.

    Hope this will help.

    Sylvie

Maybe you are looking for

  • Is it OK to put an iMac to sleep if he doesn't serve immediately?

    Is is ok to put an iMac to sleep, or a user do completely off if he won't serve in a few hours? Is

  • Why should I connect to iTunes Store so frequently?

    My iPhone running iOS 9.3.1 and before 9.3 frequently and apparently random applications that I have 'connect to iTunes Store. This warning window appears in various applications and sometimes, I get a notification on the lock screen. How will I know

  • How reformat Portege M750 (PPM75A-OR904L)?

    Hello my laptop has been infected with a Mallware virous doctor and I don't think that it is completely clean. I want to reformat, I just finished my other XP disktop and not, it's the turn of laptop. How can I do since I have not a windows 7 CD into

  • Merger of Apple ID

    Is it license or possible to merge two Apple ID?

  • SystemDialog in long running headless app

    Hello 10.3.1 I have a use case where I need to display a popup when a condition is met. The app may not run at the time when the condition could be filled. I looked at the following statement of the documentation «Apps headless supports dialog boxes