Race condition with data value reference?

I'm having a problem that presents itself as a condition using DVR to pass data through a VI.  I had heard that the DVR has blocked concurrent access to the data reference.  I have a DVR from two places in my code, 1) I write a new value to the DVR, what happens when a user event and fires rarely and 2) that I read the DVR to access data and display them graphically in an update of loop at 2 Hz.  The DVR stores a large cluster of the elements, and in this case I can only access one of the cluster using the structure of the element 'In Place'.  I'm in trouble that on some occasions the DVR reads the old data, rather than the new set of data by the user event.  I've attached screenshots of the access screw and I use a Get/Set configuration that allows me to read/write an element unique cluster of the DVR.

I'd appreciate comments on structure I use, traps, or am I misunderstanding of the use of the RECORDER.

Thank you
Dan

To protect what is inside the structure of inplace DVR. Once outside, the Paris are open.

Sounds like you want a queue where there is only a value if send it awaiting it upward.

Ben

Tags: NI Software

Similar Questions

  • Can I use data value references with a functional overall?

    Can I use data value references with a functional global?  I am trying, but it causes problems:  I run the attached VI with "new DVR" selected.  Then I run it again with "return array" and I get the error 1556: "The reference is invalid. This error might occur because the reference has been deleted."  It seems to have forgotten the DVR, but I thought it should be stored in the shift register.
    
    Another odd thing:  In my VI, if I try to connect the wire shown in "something strange", then the type changes (from U16 array to DBL), i.e. it doesn't recognize the type referenced by the DVR.
    
    I want to pass a very large 4-dimensional array between parallel loops with a functional global.  To avoid memory problems, I want to use a DVR and in-place element structures.  If that's not allowed in Labview, I will try passing it through a user event or notifier.  Any problems with those alternatives?
    
    Thanks.
    

    I received a response from an engineer applications OR on this subject, and it seems that it is perhaps a problem with Labview.  They are working on it, so I'll go ahead and close this discussion.

    Thanks for the help,

    Allan

  • Using 'New data value reference' in a loop

    Hi all

    I just read on the data value references (DVR?) and I'm trying to use them with overall functional (see table).

    I don't think that I'm just doing.  The final goal is a producer/consumer nickname.  My concern is that I don't feel the implementation of the new primitive data value reference and re-stuffing the result in the FGV, should occur in each loop.

    Of course I could "spread" data with a single gueue element (where the queue of new data would take place each loop).  I just thought that I would play with them.

    Beavercreek wrote:

    I think that we defend the same point, but I can't seem to understand why this does not work the way I expected.  I discovered the DVR (and queues) as a pointer, simply a way that the other vi can know where the data is located.  The data that we are after is here.  So, why Ch1 does not work in the data_reader.vi?

    If we can get Ch1 to work data_reader without re-creating and re-writing of the reference in the FGV each pole (what does Ch2), we find no more what is wrong with my vI or I'm going to learn something that is still beyond me.  I hope to hit me in the head this afternoon still

    You are missing a fundamental idea: the function you call creates a reference that points to a specific value. To actually interact with this value (read/write), you need to use the structure of the International preliminary examination. At this time what you are creating a single reference for ch1 (which do you nothing with) and creation of multiple references to ch2 (where at each iteration that you replace the reference in the FGV, so you basically lose the old reference), so instead of having two DVRs, you really N + 1 DVR (where N is the number of iterations of the loop runs).

    For your code works the way you want, you only need to create two digital video recorders (probably before the loop), then bring them inside the loop and use the structure of the International preliminary examination with nodes in R/W DVR to set the value in the DVR.

    For example:

    Other problems with the code, but this deal the DVR issue.

  • Problems updating default_where with date values

    Hello

    I want to update the attribute default_where with date values. the form is initialized, the attribute default_where = Lieferdatum > =: AB2.von AND Lieferdatum < =: AB2. BIS
    Then, I select the query.
    by fireing the trigger when-click of the mouse, I want to select only the witch value content items: Lieferdatum

    declare
    v_bestellnr varchar (200);
    test varchar (200);

    Start

    v_bestellnr: =: k_falschgeladen_vw. Lieferdatum;
    test: = 'LIEFERDATUM =' | v_bestellnr;
    Set_Block_Property ('K_FALSCHGELADEN_VW' test, DEFAULT_WHERE),
    EXECUTE_QUERY;

    end;

    I get the message FRM-40505 query could not be reached

    Paper copy of the formdeveloper http://www.neusob.de/~RobertKoch/dok1-Dateien/image002.jpg

    so, how can I get good value in the default_where attribute

    I hope that the: k_falschgeladen_vw. Lieferdatum is date data type. If so, try the following:

    Set_Block_Property('K_FALSCHGELADEN_VW', DEFAULT_WHERE, 'LIEFERDATUM=TO_DATE(''' || TO_CHAR(:k_falschgeladen_vw.Lieferdatum, 'DD.MM.YYYY') || ''', ''DD.MM.YYYY'')');
    EXECUTE_QUERY;
    
  • Fill a table with date values with a fixed increment

    Hello

    I want to fill a table with a date column with the increment of a fixed value date values. The start date is selectable, the increment is selectable and the number of records is adjustable as well.
    For example
    start date is 1905-Jan-02, 15:00 (DD-MON-YYYY, HH24:MI:SS)
    increment is 1 hour and 5 minutes
    None. records is 10
    then the dates in the table must be
    REC 1 1905 - Jan - 02, 15:00
    REC 2 1905 - Jan - 02, 16:05
    REC 3 1905 - Jan - 02, 17:10
    ....
    REC 9 1905 - Jan - 02, 23:40
    REC 10 1905 - Jan - 03, 00:45:00

    We are working on 11 GR 2, the number of records can be between a few hundred and a few million and they must be ordered with Crescent of time (maybe to have a whole id).
    Any ideas how to fill this table (simple and fast?) using sql / plsql are welcome.

    Thanks, Hannes

    Something along the lines of:

    SQL> alter session set nls_date_format = 'YYYY-Mon-DD HH24:MI:SS';
    
    Session altered.
    
    SQL> select trunc(sysdate,'HH')+((rownum-1)*(1/24)*(65/60)) as dt
      2  from dual connect by rownum <= 20;
    
    DT
    --------------------
    2010-Aug-26 16:00:00
    2010-Aug-26 17:05:00
    2010-Aug-26 18:10:00
    2010-Aug-26 19:15:00
    2010-Aug-26 20:20:00
    2010-Aug-26 21:25:00
    2010-Aug-26 22:30:00
    2010-Aug-26 23:35:00
    2010-Aug-27 00:40:00
    2010-Aug-27 01:45:00
    2010-Aug-27 02:50:00
    2010-Aug-27 03:55:00
    2010-Aug-27 05:00:00
    2010-Aug-27 06:05:00
    2010-Aug-27 07:10:00
    2010-Aug-27 08:15:00
    2010-Aug-27 09:20:00
    2010-Aug-27 10:25:00
    2010-Aug-27 11:30:00
    2010-Aug-27 12:35:00
    
    20 rows selected.
    
  • How to write the condition with the value of the parameter

    Hello
    I'm working on siebel BI publisher report. I am able to display the value of the parameter in the report.

    Now, I wanted to do something logical based on the value of the parameter.

    for example: If the user changes the value of the parameter then I have to call A submodel if user don't past not any value then it should not display A submodel

    can someone tell me how to write that above logic?

    If the parameter exists then MODEL of APPEAL one another do not call MODEL A

    Kind regards
    JAG


    Dial a submodel

  • How to use the aggregate with Date function

    Hi all

    I have a Group date is it possible of Max and Min to date.

    I tried like this but its out errored <? MIN (current - group () / CREATION_DATE)? >.

    I also tried this, but it does not work
    <? xdoxslt:minimum (CREATION_DATE)? >

    Is it possible to use the function of aggregation with date values.

    Thanks and greetings
    Srikkanth

    You can use
    Ensure that the "date" is in canonical format

  • Pass data between applications value reference

    The issue is that data application reference value is local to the application instance, or can be transferred between different applications.

    I have a main application that acquires the table of 100 MB and I need to use these data in a dll. Obviously, I don't want to send table, reference would be better. Both applications are generated in labview 2011.

    The second question is whether reference data value can be converted to a string (type cast or flatten to a string) and back. For example with DAQmx tasks flatten to a string does not work.

    Alexander_Sobolev wrote:

    It's value application data reference is local to the application instance.

    Yes.

    or may be transferred between applications.

    Laughing out loud

    The second question is whether reference data value can be converted to a string (type cast or flatten to a string) and back.

    Yes, but only means something in the app instance appeared to reference.

    You will want to perhaps give more details on what are your real needs, but keep in mind that play with memory directly in LV is not so simple, as he does all he can to hide these details you.

    If you pass a pointer to an array to a DLL, you can configure the DLL for this call. If you want to get an accurate picture of LV in memory address and passing around, this isn't something LV supports and you shouldn't do that because the memory should not be controlled by more than one master at any time in time.

    LV has functions of memory allocation and to get the pointer back, but requiring explicit calls.

    Anyway, I have no real experience with this. If you want to read materials, there are at least two users here with much more knowledge on the subject and you can go through their messages or search and filter for their post - rolfk and nathand.

  • Inconsistent output in project values. Possible race condition.

    I have a big project and saw many. I recently made some changes to the highest VI (do not remember what the changes were however) which led to a very strange test results, from time to time. I have a VI sub entering the model number off the coast of the ASE and outputs of an enum. If the Subvi outputs 2, shall be read as a 2 to the topVI. About 20% of cases, it generates a 0. At the higher level, the output of the Subvi connects to a typedef cluster that contains the typedef enum.

    I thought about it. It turns out that it wasn't a race condition. Where I placed my probes and where I put breakpoints, it looked like the data that has been taken out of the subIV and the data in the top VI did not correspond to the top. It turns out that the DUT has a firmware which sometimes returns incorrect data.

  • Remove data with null value

    Hello

    I'm using Oracle 11 g. I have a table with an id of 3, node, the value column. Combination of the column id and node, that must be taken account for deletion on the registers.

    Here, I need to delete lines with the NULL value in the value column. If for a combination of id and node with non-null values, then I need to delete rows with a null value for this combination.

    If the combination of id, node is not null value then this records should not delete.

    Below table, I need to remove the second row, for which is a value not zero VOICE CAL '10' is there, so I need to delete the row with null values. (VOICE, CAL, NULL)

    Network, FL, there is no value is non-null then I should NOT delete this line.

    This table is to have 100 s of this association, we can delete data in a single delete query?

    Or how I can delete rows with nulls for this combination.

    Tab1

    VALUE OF THE NŒUD ID

    VOICE CAL 10
    VOICE CAL NULL
    NETWORK NULL FL

    Thank you

    Hello

    oradba11 wrote:

    Hello

    I'm using Oracle 11 g. I have a table with an id of 3, node, the value column. Combination of the column id and node, that must be taken account for deletion on the registers.

    Here, I need to delete lines with the NULL value in the value column. If for a combination of id and node with non-null values, then I need to delete rows with a null value for this combination.

    If the combination of id, node is not null value then this records should not delete.

    Below table, I need to remove the second row, for which is a value not zero VOICE CAL '10' is there, so I need to delete the row with null values. (VOICE, CAL, NULL)

    Network, FL, there is no value is non-null then I should NOT delete this line.

    This table is to have 100 s of this association, we can delete data in a single delete query?

    Or how I can delete rows with nulls for this combination.

    Tab1

    VALUE OF THE NŒUD ID

    VOICE CAL 10
    VOICE CAL NULL
    NETWORK NULL FL

    Thank you

    You can do this in a single DELETE statement (it is not a request), using an EXISTS or IN the subquery.  For example:

    REMOVE table_x m

    WHERE the value IS NULL

    AND THERE ARE)

    SELECT 0

    FROM table_x s

    WHERE s.id = m.id

    AND s.node = m.node

    AND s.value IS NOT NULL

    )

    ;

    If you would care to post CREATE TABLE and INSERT instructions for the sample data, and then I could test it.

  • Compare sysdate with date column value

    Hello

    I need to compare the current_date (sysdate) with the value of column date in the sql below.

    Current_date is sysdate in the sql below.

    Can someone please let me know if the below sql is correct.

    SELECT ZZ. ZIP_CDE

    CC. CITY_NAM

    CC. ST_ABBR

    ZZ. ZIP_CDE_TYP_CDE

    ZZ. ZIP_CDE_STRT_DTE

    OF MDMGEO. T_CITY CC

    MDMGEO. ZC T_ZIP_CITY

    MDMGEO. ZZ T_ZIP_CODE

    MDMSTGGEO. T_USPS_DETAIL_RECORD_distinct T

    WHERE CC. CITY_GNRTD_ID = ZC. CITY_GNRTD_ID

    AND ZZ. ZIP_CDE = ZC. ZIP_CDE

    AND ZZ. ZIP_CDE_STRT_DTE = ZC. ZIP_CDE_STRT_DTE

    AND CURRENT_DATE BETWEEN ZZ. ZIP_CDE_STRT_DTE

    AND ZZ. ZIP_CDE_END_DTE

    AND CURRENT_DATE BETWEEN ZC. ZIP_CITY_STRT_DTE

    AND ZZ. ZIP_CDE = T.DTL_ZIP_CDE

    AND CC. CITY_NAM = PRFRD_LST_LINE_CITY_ST_KEY_NAM T.

    AND CC. ST_ABBR = T.ZIP_ST_ABBR_CDE

    Thank you!

    I want to sleep... maybe too ZZ

    In any case, apparently. What is the problem if necessary?

  • The default value for a property with data of type boolean

    Hi all

    Is it a system preference setting, where the default value for a property with data of type boolean can be a Virgin? I want to keep the value by default in a vacuum, but every time I save the property even after empty selection, the default value changes to FALSE.

    Capture.JPG

    In this case Boolean doesn't help you, you mayneed to create a chain of ownership and have true/false / "" as your list of values

  • How can I add data file to an existing table on Oracle RAC ASM with no OMF? Thank you!

    How can I add data file to an existing table on Oracle RAC ASM with no OMF? Thank you!

    Hello

    So I guess you have some files in ASM, see your first existing file structure

    Select file_name

    from dba_data_files;

    and to add to an existing table, the example below (even if you're better sticking with OMFs!)-is that what you are looking for?

    SQL > create tablespace TEST1

    2 datafile '+ DATA' size 1 M;

    Created tablespace.

    SQL > select file_name in dba_data_files;

    FILE_NAME

    --------------------------------------------------------------------------------

    +Data/orcl2/datafile/users.259.859820983

    +Data/orcl2/datafile/undotbs1.258.859820983

    +Data/orcl2/datafile/SYSAUX.257.859820983

    +Data/orcl2/datafile/system.256.859820981

    +Data/orcl2/datafile/example.269.859821049

    +Data/orcl2/datafile/Test1.271.859843053

    6 selected lines.

    SQL > alter tablespace TEST1

    2 Add datafile ' + DATA / mynewfile01.dbf ' size 2 m;

    Tablespace altered.

    SQL > select file_name in dba_data_files;

    FILE_NAME

    --------------------------------------------------------------------------------

    +Data/orcl2/datafile/users.259.859820983

    +Data/orcl2/datafile/undotbs1.258.859820983

    +Data/orcl2/datafile/SYSAUX.257.859820983

    +Data/orcl2/datafile/system.256.859820981

    +Data/orcl2/datafile/example.269.859821049

    +Data/orcl2/datafile/Test1.271.859843053

    + DATA / mynewfile01.dbf

    Thank you

  • Updated with the values in the same table, for other records corresponding to conditions

    Hi Experts,

    Sorry do not provide the structure of the table (it is a simple structure)

    I have a requirement where I need to update the columns of a table based on the same table with some match empid and date values. If the date and empid match so I have these values to any other folder and update of one who is not having details of Office . I need the Update query

    Before the update my array of values is as below

    Sort_num Emp_id Bureau start_date

    1 101 AUS 01/01/2013
    2 101 01/01/2013
    3 101 15/01/2013
    4 103 USA 01/05/2013
    5 103 01/01/2013
    6 103 05/01/2013
    7 104 FRA 01/10/2013
    8 104 10/01/2013
    9 104 01/01/2013

    After update my table should be as below

    Sort_num Emp_id Bureau start_date

    1 101 AUS 01/01/2013
    2 101 AUS 01/01/2013
    3 101 15/01/2013
    4 103 USA 01/05/2013
    5 103 01/01/2013
    6 103 USA 01/05/2013
    7 104 FRA 01/10/2013
    8 104 FRA 01/10/2013
    9 104 01/01/2013

    Thanks in advance

    I don't have the time to create the table with the data, but basically, you should be able to code the following text

    update one table

    Office set = (select desktop in table b where b.emp_id = a.emp_id)

    and b.start_date = a.start_date

    and b.office is not null

    )

    where is ([as well as overall query])

    and a.office is null

    In my opinion, who will do the trick.

    HTH - Mark D Powell.

  • Spry form validation Date with default value error

    The spry form validation below was created with DW CS6

    I created an HTML form and displayed with PHP to a MySQL database.  One of the lines of form is to enter a date.  This line uses a 'out of the box' sprytextfield data validation without changes to its CSS or JS:

    HTML

    < span id = "sprytextfield1" >

    < label for = "servComDate" > Date beginning? < / label >

    < input type = "text" name = "servComDate" id = "servComDate" >

    < span class = "textfieldRequiredMsg" > a value is required. </span >

    < span class = "textfieldInvalidFormatMsg" > Invalid format. </span >

    </span >

    < script type = "text/javascript" >

    var sprytextfield1 = new Spry.Widget.ValidationTextField ("sprytextfield1", "date", {index: "00/00/0000", format: "mm/dd/yyyy"});

    < /script >

    On request, the form value is captured via PHP and date format is converted to a format of MySQL before entering in the database.

    PHP

    $servComDate = date ("Y-m-d", strtotime($_POST['servComDate']));

    It all works perfectly.

    Now, I created another page with a HTML form to change information.  First, PHP takes the field in the database and converts it to MySQL format to the format used in the sprytextfield above, in which it was created.

    PHP

    $servComDate = strftime ("% m/%d/%Y", strtotime ($row ["servComDate"]));

    Then the HTML form is filled with existing value

    HTML

    < span id = "sprytextfield1" >

    < label for = "servComDate" > if the Service is coming soon, do you know when the service will begin offered? < / label >

    < input type = "text" name = "servComDate" id = "servComDate" value = "<?" PHP echo $servComDate;? > ">"

    < span class = "textfieldRequiredMsg" > a value is required. </span >

    < span class = "textfieldInvalidFormatMsg" > Invalid format. </span >

    </span >

    By filling in the form with existing value appears with the right in the box format, it shows these 'mistakes ':

    value is required. Format invalid.

    As I said above, I have not changed the CSS or JS that is loaded with the Spry textfield, so I don't get that here.

    I'm obviously something wrong with pre-filling a Spry textfield with a default value.

    What is the real need have a default value on a Textfield of Date Validation Spry?

    Thanks in advance!

    Make sure that, in the page change the constructor looks like

    var sprytextfield1 = new Spry.Widget.ValidationTextField ("sprytextfield1", "date", {index: "00/00/0000", format: "mm/dd/yyyy"});

    The following works fine for me

    ">

    A value is required. Format invalid.

    GRAMPS

Maybe you are looking for