the speed of the analysis of data VI

Hello

I wrote a labview vi to help me analyze some rather large data sets. The vi works however its very laggy and uses a lot of memory. Hoped someone could take a look at my code and give me some ideas on how I can modify it to improve the speed in which it runs. I have attached my labview vi. I hope someone can help.

Best regards, R

Things I see wrong.

1. you are constantly re-read the same files in a loop.  Don't expect the files to edit?  Files must be read before the loop and data manipulated inside the loop.  I think that this is your primary problem.

2. the abuse of local variables.  You have many copies of AllRows for example.  You should have a single wire coming out of reading the file in spreadsheet on your terminal and direction that, whenever you need it.  Many other controls are duplicated unnecessarily with local variables.

3. a lot of code dupliated.  You do the same operations on many charts.  You can probably simplified by putting that into a Subvi and replicate the Subvi.  You can probably all this to wrap in a loop For.

4. your cursor property nodes appear to be back.  You're the X readling current position before you set the active cursor.  That and a race condition with the property of other parallel means node not sure which X value read you corresponds to what slider.  Read the two sliders in a single node and in the order appropriate like this:

5. other things as well as become more evident once the big objects above are supported.

I recommend you watch the LabVIEW tutorials online
LabVIEW Introduction course - 3 hours
LabVIEW Introduction course - 6 hours

Tags: NI Software

Similar Questions

  • the analysis of data from a legacy in the form of bytes bluetooth

    Hi, Iam execution of java for MYGlucoHealth code monitor. I have to catch the bluetooth through my application data and analyze format. (later I store in the SQLite database). But according to the specification of the Protocol had, I do not understand how to read and analyze. I know how to pair the device to my request. But I do not know how to parse the bytes of data according to the Protocol of the device specification.

    Can someone tell me how to do this. All done with this kind of coding?

    Thnaks in advance,

    -Cissokho

    Published by: 798686 on November 2, 2010 02:38

    798686 wrote:
    Ok.. Thank you

    Tips for the facilitator: don't double post. I've locked the new thread.
    the analysis of data from a legacy in the form of bytes bluetooth
    Please continue here.

    DB

  • the analysis of data and to help to cite a delimiter

    I found this code large piece that is almost what I want (see below).
    Can someone tell me what I need to do in order to change the delimiter from "," to "' (use
    an apostrophe a delimiter. Is there some sort of escape sequence I need to do in the service?

    To ease this function, I would probably want to be able to spend in any delimiter character
    delimiter instead of coding hard within the service.


    An example on how to change would be greatly appreciated

    create or replace the get_token function)
    la_liste varchar2,
    number of the_index,
    DELIM varchar2: = ', '.
    )
    return varchar2
    is
    number of start_pos;
    number of end_pos;
    Start
    If the_index = 1 then
    start_pos: = 1;
    on the other
    start_pos: = instr (la_liste, delim, 1, the_index - 1);
    If start_pos = 0 then
    Returns a null value.
    on the other
    start_pos: = start_pos + length (delim);
    end if;
    end if;

    end_pos: = instr (la_liste, delim, start_pos, 1);

    If end_pos = 0 then
    Return substr (la_liste, start_pos);
    on the other
    Return substr (la_liste, start_pos, end_pos - start_pos);
    end if;

    end get_token;
    /


    Select
    get_Token('foo,bar,baz',1),-"foo."
    get_Token('foo,bar,baz',3),-'baz '.
    --
    get_Token('a,,b',2),-"(null)
    get_Token('a,,b',3),-'b '.
    --
    get_Token('a|b|c',2,'|'),-'b '.
    get_Token('a|b|c',4,'|') -"(null)
    Of
    Double

    You can pass the delimiter to the function like this:

    create or replace function get_token(
    the_list varchar2,
    the_index number,
    delim VARCHAR2
    )
    

    and then call it using single quote as a delimiter. (Note that you must type two single quotes to escape):

    select
    get_token('foo''bar''baz',1, ''''), -- 'foo'
    get_token('foo''bar''baz',3, '''')  -- 'baz'
    FROM dual;
    
  • Groovy Script to find the difference between Dates

    I am trying to build a script that takes a date from a RequestField and calculates the number of days between this date and the current date (from session).

    So far, I have a problem, the analysis to-date from the RequestField chain. I found this code but it doesn't seem to work...

    date = new Date().parse('yyyy/MM/dd', '1973/07/09')
    

    I get the following error...

    Error Message: groovy.lang.MissingMethodException: No signature of method: java.util.Date.parse() is applicable for argument types: (java.lang.String, java.lang.String) values: {"yyyy/MM/dd", "1973/07/09"}
    

    Any help would be greatly appreciated.

    Hello

    What version of server? The extract you have here works fine on mine (563).

    This also works for me

    new java.text.SimpleDateFormat('yyyy/MM/dd').parse('1973/07/09')
    

    See you soon

    Nils

  • How do 9229 trigger by analysis of data

    Since 9229 (USB casing) has no external analog trigger; the signal lasts 12 seconds.

    I need to scan data collection the long, until the trigger threshold voltage is detected, then beginning to collect 12 seconds signal.

    But after the detection threshold, some data may already lost when the start of collection time 12 seconds.

    Also ' How do make a scan ", the scan to read th data should be in a loop. If set the duration for each big loop, then maybe the loss of data, but if too samll, then can make the Windows.

    Any suggestion how to read the analysis of data from the device. Thank you.

    Hi Turbot,

    You can just continuously sample and store the data in the table.

    If the size of the data is greater than 12 second pad just outside, and the threshold is reached, use the subset of table data to select just 12 second part.

    You can see my attached sample for more information.

    Sincerely, Kate

  • What is the speed of data transmission when using the dashboard of data?

    Hello, everyone, I've seen it doesn't matter if an iphone or a Chinese tablet is used, the speed of transmission of data with the shared Variables and dashboard of data is almost the same and is at reduced speed. Does anyone know how I could measure this baud rate? Thank you in advance.

    Hello there;

    The rate of updating the dashboard data for 1.0 is set to 1 second of webservices and 0.2 second for variable network shared, of course depends on the amount of information on the network continuously. On the second version of the dashboard of data, you can specify your update frequency within a range

    You can find this info in this KB

    Hope this info helps.

    See you soon

  • The analysis of the data of a string of series

    Alert LabVIEW Express 7

    Sorry, all I have to work with and there is no budget at the moment to upgrade.

    Hello, I am in phase 1 (data transfer reliable to labview) 24/7 of my small Miettinen, who is to display and record data environmental Lab 24/7 our Fisher 02-403 digital barometer that has a serial port. In fact, it came with the software, but no one here seems to like use it so I'll try to find something more intuitive. I can't find any info at all about I/O with this device, so I'm reverse engineering. I'm sure that you cannot write anything to this device only read.

    I started with the connection of the device and the interface with NOR measure and automation and received the following string: P,43,1019,44,31,01,0023.0\r\n.

    I tried to use the Labview 7 Express e/s Companion Instrument, selected 1 COMM, changed the timeout to 5000 (trial and error), added a step reading and analysis, ran and received the following string: P, 43,0999, 44,41, 01,0018.0, XX. After well guess, I determined that the values I have in bold change with the environment and the other 3 are always the same idea 9no what they represent). Alphabetical 1 in bold represents the tendency of climate S sunny = P = C sunny cloudy = etc., the value 2 is the atmospheric pressure in hPa, the 3rd is % relative humidity and the last is the temperature in Deg. C.

    At first, I tried to create simply chips for data I want and operation loop the wizard of e/s in awhile, but often error messages obtained suggesting that I need to define all the tokens in the string. I did it and it worked, then I opened the front panel to access the underlying schemas whence I came with the attached VI. I left this race for more than 24 hours, no error, seems good.

    My question on this forum is, can I simplify this VI losing a part of the analysis of the data that I don't need at this point?

    Please let me know if you can not access this VI maybe I can do a screenshot or something.

    Thank you

    Doug

    Yes, it can be simplified to just a bit.

    Since you are new to LabVIEW, you can start with the basic tutorial.

  • the analysis of string data

    Hi all

    I got the series communation data string in this format:

    Bridge of fuse HtrPwrV VDispV/C PAO V/C DTM V/C DiffC NC
    OK VALIDATES 1.80 0.95 3.16 0.53 537 29.6
    369 647 110

    And I want to extract some value from it. I realized that they are separated with spaces between them. So I thought about transfer them into an array and then extract some lines/columns there. But I don't know how to do.

    Could you give me an idea. Or if you have a better way, then please show me!

    Thank you

    Here is a way.

  • Single SQL query for the analysis of the date of customs declaration under the table of Stock codes

    Dear all,


    Please tell us a single SQL query for the below,

    We have a Table of Stock as shown below,

    STOCK_TABLE

     

    ITEM_CODE

    (item code)

    BAT_NO

    (lot no.)

    TXN_CODE

    (transaction code)

    DOC_NO

    (number)

    BOE_DT

    (date of the customs declaration)

    I1

    B1

    I1

    I2

    I3

    B70

    I4

    B80

    I5

    B90

    T102

    1234

    JULY 2, 2015

    I6

    B100

    We have to find the date of customs declaration (i.e. the date when the items have come under this particular table) for items that are not attached to any document (that is, who have TXN_CODE, DOC_NO and BOE_DT fields with a NULL value).

    For each item in the table of actions, which is not attached to any document, the customs declaration date is calculated as follows.

    1. If (code section, lot number) combination is present under HISTORY_TABLE, the date of customs declaration will receive the UPDT_DT, the transaction code (TXN_CODE) is an IN or transactions (which can be analyzed from the TRANSACTIONS table).

    2. If (code section, lot number) combination is NOT currently at the HISTORY_TABLE (or) the transaction code respective to item - batch number combination code is an operation then customs declaration date will be the date of the document (DOC_DT) that we receive from one of the 3 tables IN_TABLE_HEAD that contains the element of that particular lot.

  • If the case 1 and case 2 fails, our customs declaration date will be the last date of document (DOC_DT) that we receive from one of the 3 tables IN_TABLE_HEAD containing that particular item and the BAT_NO in expected results will be that corresponding to this document, as appropriate, to another NULL.

  • If the case 1 or case 2 is successful, the value of the last field (in the output expected, shown further below) BATCH_YN will be 'Y', because it fits the lot. Otherwise it will be 'n'.
  • HISTORY_TABLE

     

    ITEM_CODE

    BAT_NO

    TXN_CODE

    DOC_NO

    UPDT_DT

    I1

    B1

    T1

    1234

    JANUARY 3, 2015

    I1

    B20

    T20

    4567

    MARCH 3, 2015

    I1

    B30

    T30

    7890

    FEBRUARY 5, 2015

    I2

    B40

    T20

    1234

    JANUARY 1, 2015

    TRANSACTION

     

    TXN_CODE

    TXN_TYPE

    T1

    IN

    T20

    OFF

    T30

    ALL THE

    T50

    IN

    T80

    IN

    T90

    IN

    T60

    ALL THE

    T70

    ALL THE

    T40

    ALL THE

    IN_TABLE_HEAD_1

     

    H1_SYS_ID

    (primary key)

    TXN_CODE

    DOC_NO

    DOC_DATE

    H1ID1

    T1

    1234

    JANUARY 1, 2015

    H1ID2

    T70

    1234

    FEBRUARY 1, 2015

    IN_TABLE_ITEM_1

     

    I1_SYS_ID

    H1_SYS_ID

    (foreign key referencing H1_SYS_ID in IN_TABLE_HEAD_1)

    ITEM_CODE

    I1ID1

    H1ID1

    I1

    I1ID2

    H1ID1

    I100

    I1ID3

    H1ID2

    I3

    IN_TABLE_BATCH_1

     

    B1_SYS_ID

    TXN_CODE                DOC_NO

    (now in IN_TABLE_HEAD_1)

    BAT_NO

    B1ID1

    T1

    1234

    B1 / can be empty

    B1ID2

    T70

    1234

    B70

    IN_TABLE_HEAD_2

     

    H2_SYS_ID

    (primary key)

    TXN_CODE

    DOC_NO

    DOC_DATE

    H2ID1

    T30

    4567

    FEBRUARY 3, 2015

    H2ID2

    T60

    1234

    JANUARY 3, 2015

    IN_TABLE_ITEM_2

     

    I2_SYS_ID

    H2_SYS_ID

    (foreign key referencing H2_SYS_ID in IN_TABLE_HEAD_2)

    ITEM_CODE

    I2ID1

    H2ID1

    I1

    I2ID2

    H2ID1

    I200

    I2ID3

    H2ID2

    I2

    IN_TABLE_BATCH_2

     

    B2_SYS_ID

    I2_SYS_ID

    (foreign key referencing I2_SYS_ID in IN_TABLE_ITEM_2)

    BAT_NO

    B2ID1

    I2ID1

    B30 / null

    B2ID2

    I2ID2

    B90

    B2ID2

    I2ID3

    B60

    IN_TABLE_HEAD_3

     

    H3_SYS_ID

    (primary key)

    TXN_CODE

    DOC_NO

    DOC_DATE

    H3ID1

    T50

    1234

    JANUARY 2, 2015

    H3ID2

    T80

    1234

    JANUARY 3, 2015

    H3ID3

    T90

    1234

    JANUARY 4, 2015

    H3ID4

    T40

    1234

    AUGUST 5, 2015

    IN_TABLE_ITEM_3

     

    I3_SYS_ID

    H3_SYS_ID

    (foreign key referencing H3_SYS_ID in IN_TABLE_HEAD_3)

    ITEM_CODE

    BAT_NO

    I3ID1

    H31D1

    I2

    B50

    I3ID2

    H3ID2

    I4

    B40

    I3ID3

    H3ID3

    I4

    I3ID4

    H3ID4

    I6

    There is no IN_TABLE_BATCH_3

    Please find below the expected results.

    OUTPUT

     

    ITEM_CODE

    BAT_NO

    TXN_CODE

    DOC_NO

    BOE_DT

    BATCH_YN

    I1

    B1

    T1

    1234

    JANUARY 3, 2015

    THERE

    I1

    B30

    T30

    7890

    FEBRUARY 5, 2015

    N

    I2

    B60

    T60

    1234

    JANUARY 3, 2015

    N

    I3

    B70

    T70

    1234

    FEBRUARY 1, 2015

    THERE

    I4

    T90

    1234

    JANUARY 4, 2015

    N

    I6

    T40

    1234

    AUGUST 5, 2015

    N

    Controls database to create the tables above and insert the records.

    CREATE TABLE stock_table()item_code VARCHAR2()80),bat_no VARCHAR2()80),txn_code VARCHAR2()80),

    doc_no VARCHAR2 (80), boe_dt DATE );

    INSERT EN stock_table

       VALUES ('I1', 'B1', '', '', '');

    INSERT EN stock_table

       VALUES ('I1', '', '', '', '');

    INSERT IN stock_table

       VALUES ('I2', '', '', '', '');

    INSERT EN stock_table

       VALUES ('I3', 'B70', '', '', '');

    INSERT EN stock_table

       VALUES ('I4', 'B80', '', '', '');

    INSERT EN stock_table

       VALUES ('I5', 'B90', 'T102', '1234', '02-JUL-2015');

    INSERT EN stock_table

       VALUES ('I6', 'B100', '', '', '');

    SELECT *

    FROM stock_table




     

    CREATE TABLE history_table()item_code VARCHAR2()80),bat_no VARCHAR2()80),txn_code VARCHAR2()80),

    doc_no VARCHAR2 (80), updt_dt DATE );

    INSERT IN history_table

       VALUES ('I1', 'B1', 'T1', '1234', '03-JAN-2015');

    INSERT IN history_table

       VALUES ('I1', 'B20', 'T20', '4567', '03-MAR-2015');

    INSERT IN history_table

       VALUES ('I1', 'B30', 'T30', '7890', '05-FEB-2015');

    INSERT IN history_table

       VALUES ('I2', 'B40', 'T20', '1234', '01-JAN-2015');

    SELECT *

    FROM history_table




     

    CREATE TABLE transaction1()txn_code VARCHAR()80),txn_type VARCHAR()80));


    INSERT INTO transaction1

       VALUES ('T1', 'IN');


    INSERT INTO transaction1

       VALUES ('T20', 'OUT');

    INSERT INTO transaction1

       VALUES ('T30', 'ALL');

    INSERT INTO transaction1

       VALUES ('T40', 'ALL');

    INSERT INTO transaction1

       VALUES ('T50', 'IN');

    INSERT INTO transaction1

       VALUES ('T60', 'ALL');

    INSERT INTO transaction1

       VALUES ('T70', 'ALL');

    INSERT INTO transaction1

       VALUES ('T80', 'IN');

    INSERT INTO transaction1

       VALUES ('T90', 'IN');

    SELECT *

    FROM transaction1




     

    CREATE TABLE in_table_head_1()h1_sys_id VARCHAR2()80) PRIMARY KEY,txn_code VARCHAR2()80),

    doc_no VARCHAR2 (80), doc_dt DATE );

    CREATE TABLE in_table_head_2()h2_sys_id VARCHAR2()80) PRIMARY KEY,txn_code VARCHAR2()80),

    doc_no VARCHAR2 (80), doc_dt DATE );

    CREATE TABLE in_table_head_3()h3_sys_id VARCHAR2()80) PRIMARY KEY,txn_code VARCHAR2()80),

    doc_no VARCHAR2 (80), doc_dt DATE );

     

    INSERT IN in_table_head_1

       VALUES ('H1ID1', 'T1', '1234', '01-JAN-2015');

    INSERT IN in_table_head_1

       VALUES ('H1ID2', 'T70', '1234', '01-FEB-2015');

    INSERT IN in_table_head_2

       VALUES ('H2ID1', 'T30', '4567', '03-FEB-2015');

    INSERT IN in_table_head_2

       VALUES ('H2ID2', 'T60', '1234', '03-JAN-2015');

    INSERT IN in_table_head_3

       VALUES ('H3ID1', 'T50', '1234', '02-JAN-2015');

    INSERT IN in_table_head_3

       VALUES ('H3ID2', 'T80', '1234', '03-JAN-2015');

    INSERT IN in_table_head_3

       VALUES ('H3ID3', 'T90', '1234', '05-JAN-2015');

    INSERT IN in_table_head_3

       VALUES ('H3ID4', 'T40', '1234', '05-AUG-2015');




     

    CREATE TABLE in_table_item_1()i1_sys_id VARCHAR2()80) PRIMARY KEY,

    h1_sys_id VARCHAR2 (80) REFERENCES in_table_head_1()h1_sys_id),item_code VARCHAR2()80));

    CREATE TABLE in_table_item_2()i2_sys_id VARCHAR2()80) PRIMARY KEY,

    h2_sys_id VARCHAR2 (80) REFERENCES in_table_head_2()h2_sys_id),item_code VARCHAR2()80));

    CREATE TABLE in_table_item_3(i3_sys_id VARCHAR2(80) PRIMARY KEY,

    h3_sys_id VARCHAR2 (80) REFERENCES in_table_head_3()h3_sys_id),item_code VARCHAR2()80),

    bat_no VARCHAR2 (80));

     

    INSERT IN in_table_item_1

       VALUES ('I1ID1', 'H1ID1', 'I1');

    INSERT IN in_table_item_1

       VALUES ('I1ID2', 'H1ID1', 'I100');

    INSERT IN in_table_item_1

       VALUES ('I1ID3', 'H1ID2', 'I3');

    INSERT IN in_table_item_2

       VALUES ('I2ID1', 'H2ID1', 'I1');

    INSERT IN in_table_item_2

       VALUES ('I2ID2', 'H2ID1', 'I200');

    INSERT IN in_table_item_2

       VALUES ('I2ID3', 'H2ID2', 'I2');

    INSERT IN in_table_item_3

       VALUES ('I3ID1', 'H3ID1', 'I2','B50');

    INSERT IN in_table_item_3

       VALUES ('I3ID2', 'H3ID2', 'I4','B40');

    INSERT IN in_table_item_3

       VALUES ('I3ID3', 'H3ID3', 'I4','');

    INSERT IN in_table_item_3

       VALUES ('I3ID4', 'H3ID4', 'I6','');

    SELECT *

    FROM in_table_item_1

    SELECT *

    FROM in_table_item_2

    SELECT *

    FROM in_table_item_3




     

    CREATE TABLE in_table_batch_1()b1_sys_id VARCHAR2()80) PRIMARY KEY,

    txn_code VARCHAR2 (80), doc_no VARCHAR2 (80), bat_no VARCHAR2 (80));

    CREATE TABLE in_table_batch_2()b2_sys_id VARCHAR2()80) PRIMARY KEY,

    i2_sys_id VARCHAR2 (80) REFERENCES in_table_item_2()i2_sys_id),bat_no VARCHAR2()80));

     

    INSERT IN in_table_batch_1

       VALUES ('B1ID1', 'T1', '1234', 'B1');

    INSERT IN in_table_batch_1

       VALUES ('B1ID2', 'T70', '1234', 'B70');

    INSERT IN in_table_batch_2

       VALUES ('B2ID1', 'I2ID1', 'B30');

    INSERT IN in_table_batch_2

       VALUES ('B2ID2', 'I2ID2', 'B90');

    INSERT IN in_table_batch_2

       VALUES ('B2ID3', 'I2ID3', 'B60');

    Please advise a solution for the same.

    Thank you and best regards,

    Séverine Suresh

    very forced (question subfactoring used to allow easy testing/verification - could work with these test data only)

    with

    case_1 as

    (select s.item_code,

    s.bat_no,

    h.txn_code,

    h.doc_no,

    h.updt_dt boe_dt,

    cases where s.bat_no = h.bat_no then 'Y' else ' n end batch_yn.

    cases where h.txn_code is not null

    and h.doc_no is not null

    and h.updt_dt is not null

    then 'case 1' '.

    end refers_to

    from (select item_code, bat_no, txn_code, doc_no, boe_dt

    of w_stock_table

    where bat_no is null

    or txn_code is null

    or doc_no is null

    or boe_dt is null

    ) s

    left outer join

    w_history_table h

    On s.item_code = h.item_code

    and s.bat_no = h.bat_no

    and exists (select null

    of w_transaction1

    where txn_code = nvl (s.txn_code, h.txn_code)

    and txn_type in ('IN', 'ALL')

    )

    ),

    case_2 as

    (select s.item_code,

    NVL (s.bat_no, h.bat_no) bat_no.

    NVL (s.txn_code, h.txn_code) txn_code.

    NVL (s.doc_no, h.doc_no) doc_no.

    NVL (s.boe_dt, h.updt_dt) updt_dt.

    cases where s.bat_no = h.bat_no then 'Y' else ' n end batch_yn.

    cases where h.txn_code is not null

    and h.doc_no is not null

    and h.updt_dt is not null

    then 'case 2'.

    end refers_to

    from (select item_code, bat_no, txn_code, doc_no, boe_dt

    of case_1

    where refers_to is null

    ) s

    left outer join

    w_history_table h

    On s.item_code = h.item_code

    and exists (select null

    of w_transaction1

    where txn_code = nvl (s.txn_code, h.txn_code)

    and txn_type in ('IN', 'ALL')

    )

    and not exists (select null

    of case_1

    where item_code = h.item_code

    and bat_no = h.bat_no

    and txn_code = h.txn_code

    and doc_no = h.doc_no

    and updt_dt = h.updt_dt

    )

    ),

    case_31 as

    (select s1.item_code,

    NVL (S1.bat_no, W1.bat_no) bat_no.

    NVL (S1.txn_code, W1.txn_code) txn_code.

    NVL (S1.doc_no, W1.doc_no) doc_no.

    NVL (S1.updt_dt, W1.doc_dt) updt_dt.

    cases where s1.bat_no = w1.bat_no then 'Y' else ' n end batch_yn.

    cases where w1.txn_code is not null

    and w1.doc_no is not null

    and w1.doc_dt is not null

    then "case 31'.

    end refers_to

    from (select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn, refers_to

    of case_2

    where refers_to is null

    ) s1

    left outer join

    (select i1.item_code, h1.txn_code, h1.doc_no, h1.doc_dt, b1.bat_no

    of w_in_table_item_1 i1

    inner join

    w_in_table_head_1 h1

    On i1.h1_sys_id = h1.h1_sys_id

    inner join

    w_in_table_batch_1 b1

    On h1.txn_code = b1.txn_code

    and h1.doc_no = b1.doc_no

    ) w1

    On s1.item_code = w1.item_code

    ),

    case_32 as

    (select s2.item_code,

    NVL (S2.bat_no, W2.bat_no) bat_no.

    NVL (S2.txn_code, W2.txn_code) txn_code.

    NVL (S2.doc_no, W2.doc_no) doc_no.

    NVL (S2.updt_dt, W2.doc_dt) updt_dt.

    cases where s2.bat_no = w2.bat_no then 'Y' else ' n end batch_yn.

    cases where w2.txn_code is not null

    and w2.doc_no is not null

    and w2.doc_dt is not null

    then "case 32'.

    end refers_to

    from (select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn, refers_to

    of case_2

    where refers_to is null

    ) s2

    left outer join

    (select i2.item_code, h2.txn_code, h2.doc_no, h2.doc_dt, b2.bat_no

    of w_in_table_item_2 i2

    inner join

    w_in_table_head_2 h2

    On i2.h2_sys_id = h2.h2_sys_id

    inner join

    w_in_table_batch_2 b2

    On i2.i2_sys_id = b2.i2_sys_id

    ) w2

    On s2.item_code = w2.item_code

    ),

    case_33 as

    (select s3.item_code,

    w3.bat_no,

    NVL (S3.txn_code, w3.txn_code) txn_code.

    NVL (S3.doc_no, w3.doc_no) doc_no.

    NVL (S3.updt_dt, w3.doc_dt) updt_dt.

    cases where s3.bat_no = w3.bat_no then 'Y' else ' n end batch_yn.

    cases where w3.txn_code is not null

    and w3.doc_no is not null

    and w3.doc_dt is not null

    then "case 33'.

    end refers_to

    from (select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn, refers_to

    of case_2

    where refers_to is null

    ) s3

    left outer join

    (select i3.item_code, h3.txn_code, h3.doc_no, h3.doc_dt, i3.bat_no

    of w_in_table_item_3 i3

    inner join

    w_in_table_head_3 h3

    On i3.h3_sys_id = h3.h3_sys_id

    ) w3

    On s3.item_code = w3.item_code

    )

    Select item_code, bat_no, txn_code, doc_no, boe_dt, batch_yn

    of case_1

    where refers_to is not null

    Union of all the

    Select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn

    of case_2

    where refers_to is not null

    Union of all the

    Select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn

    from (select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn,

    ROW_NUMBER() over (partition by item_code of updt_dt desc order) rn

    from (select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn

    of case_31

    where refers_to is not null

    Union of all the

    Select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn

    of case_32

    where refers_to is not null

    Union of all the

    Select item_code, bat_no, txn_code, doc_no, updt_dt, batch_yn

    of case_33

    where refers_to is not null

    )

    )

    where rn = 1

    ITEM_CODE BAT_NO TXN_CODE DOC_NO BOE_DT BATCH_YN
    I1 B1 T1 1234 JANUARY 3, 2015 THERE
    I1 B30 T30 7890 FEBRUARY 5, 2015 N
    I2 B60 T60 1234 JANUARY 3, 2015 N
    I3 B70 T70 1234 FEBRUARY 1, 2015 THERE
    I4 - T90 1234 JANUARY 5, 2015 N
    I6 - T40 1234 AUGUST 5, 2015 N

    Concerning

    Etbin

  • Analysis of the gaps in dates

    Hello

    Oracle 10.2.0.4

    Red Hat Linux

    We have a report that is not scaling as the company increases in size and I am looking for some advice to setting / better approaches to a problem.

    The report needs to find employees who while working in a dangerous environment (high / low temperature, wet conditions, etc.) did not have relevant qualifications.

    The report creates a temporary table containing the EMP_ID, start date in a dangerous environment, and the end date in this environment.  There are also about 200 bytes of other areas.

    Then look for any day during this period where there is not a comprehensive relevant qualification / certification.  Certifications are stored in a simple table, containing the EMP_ID, the ID of the qualification, a dt start and an option end dt.  If the end dt is null, then the qualification is supposed to be in place forever.

    CREATE TABLE EMP_DANGER AS

    SELECT A.EMP_ID

    , to_date('01-JAN-2005','dd-mon-yyyy') 'START_DT '.

    , to_date('01-JAN-2016','dd-mon-yyyy') 'END_DT '.

    , 'FILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLERFILLER' 'FILLER '.

    OF (to_char (rownum) SELECT 'EMP_ID' from dual connect by level < = 100000) has

    /

    CREATE TABLE EMP_QUAL AS

    SELECT A.EMP_ID

    B.QUAL_ID

    , to_date('01-JAN-2005','dd-mon-yyyy') 'START_DT '.

    , to_date('01-JAN-2016','dd-mon-yyyy') 'END_DT '.

    OF (to_char (rownum) SELECT 'EMP_ID' from dual connect by level < = 100000) has

    , (SELECT DECODER (ROWNUM, 1, 'A', 2, "B", "C", 3, 4, has ', 5, 'E') 'QUAL_ID' from dual connect by level < = 5) B

    /

    DELETE FROM EMP_QUAL WHERE EMP_ID = '3' AND QUAL_ID = 'B '.

    /

    UPDATE EMP_QUAL SET END_DT = 1 January 2013 "where EMP_ID = '3' and QUAL_ID = 'A'

    /

    UPDATE EMP_QUAL SET START_DT = 3 January 2013 ' where EMP_ID = "3" AND QUAL_ID = "C".

    /

    ENGAGE

    /

    -Assuming for the moment that the A, B or C skills are necessary if we're working in a dangerous environment

    -You can see that EMP_ID 3 does not have a valid qualification for January 2, 2013.

    -For the moment, we have a few SQL that performs

    SELECT A.EMP_ID, B.DATE_SCAN, "no qualification valid."

    OF EMP_DANGER HAS

    , (SELECT to_date('01-JAN-1980','dd-mon-yyyy') + rownum 'DATE_SCAN' from dual connect by level < = 10000) B

    WHERE B.DATE_SCAN BETWEEN A.START_DT AND A.END_DT

    AND NOT EXISTS (SELECT 1 C EMP_QUAL

    WHERE C.EMP_ID = A.EMP_ID

    AND C.QUAL_ID IN ('A', 'B', 'C')

    AND B.DATE_SCAN > = C.START_DT

    AND (B.DATE_SCAN < = C.END_DT OR C.END_DT IS NULL))

    -BUT - now we have a society where people who have worked since the 1980s, the Cartesian join near the DATE_SCAN

    -really starts to make the system grind slowly through the scans.  Any suggestions?

    Hello

    According to you, the actual data, it could be much faster:

    WITH coverage AS

    (

    SELECT emp_id

    , DATE ' 1979-12-31' AS start_dt

    , start_dt - 1 AS end_dt

    Of emp_danger

    UNION ALL

    SELECT emp_id

    end_dt + 1 AS start_dt

    , DATE ' 9999-12-30' AS end_dt

    Of emp_danger

    UNION ALL

    SELECT emp_id

    start_dt

    , NVL (end_dt, DATE ' 9999-12-30') AS end_dt

    Of emp_qual

    WHERE qual_id IN ('A', 'B', 'C')

    )

    got_gap_length AS

    (

    SELECT emp_id

    , start_dt - 1 AS gap_end_dt

    , start_dt - (MAX (end_dt) OVER (PARTITION BY emp_id

    ORDER BY start_dt

    RANGE BETWEEN UNBOUNDED PRECEDING

    ET.5 PRECEDING

    )

    + 1

    ) AS gap_length

    Covered UNDER warranty

    )

    SELECT d.emp_id - or whatever it is you want the columns

    , g.gap_end_dt - (g.gap_length

    -1

    ) AS gap_start_dt

    g.gap_end_dt AS gap_end_dt

    OF got_gap_length g

    JOIN emp_danger d.emp_id d = g.emp_id

    AND d.start_dt<=>

    AND d.end_dt > = g.gap_end_dt - g.gap_length

    WHERE gap_length > 0

    ORDER BY emp_id

    gap_end_dt

    ;

    This produces a line of output for each group of consecutive days of risk not covered for each emp_id.  With your sample data:

    EMP_ID GAP_START_D GAP_END_DT

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

    3 January 2, 2013 January 2, 2013

    If you want to have a clean line of output for every non-covered day, he can adapt easily to the above query.

    Solomon and I seem to disagree on your needs.

  • The analysis of the non-numeric characters in a string

    Hello

    I am communicating a robot to LabVIEW (2013) via TCP/IP and sockets. The robot is the server, and LV is the customer.

    I start with the target data in this format (in a string):

    "[0 ~ 100 ~ 0] ~ [0.96593 ~-0.25882 ~ 0 ~ 0] ~ [1 ~ 0 ~ 0 ~ 0] ~ [150 ~ 50]."

    [X, Y, Z], [Q1, Q2, Q3, Q4], [C1, C4, C6, Cx], [TCPVel, OrientVel] except replacement ',' (comma) with a ' ~ ' (tilde) because I load the target data in a spreadsheet which is a comma-delimited file.

    In LV, I take this string, the analysis of the chain and split individual items. I then pulled the singular elements as unique, 32-bit of real numbers. I take each one and convert them individually to a string, concatenate them and send them to the robot. The robot decompresses these raw bytes individually and converts them to a target of robot (position in space).

    I train (BT) check if the user has sent a bad character (non-digital) in the target data. Example of this is:

    [- 50 ~-150 ~ 0] ~ [0.96593 ~-0 ] [B2has5D882 ~ 0 ~ 0] ~ [1 ~-1 ~ 0 ~ 0] ~ [150 ~ 50]

    Now in BT, when I'm scanning the chain, these bad character becomes the entire element to zero and everything else then to zero as well. See attachment for example screen similar.

    My question is, my VI, I can analyze all non-numeric characters (that are inside the parentheses and characters that are NOT a ' ~ ' (tilde))? In this way, I can always get this item numbers and do not have this element or other items turn to zero?

    Thanks in advance for any help!

    Sorry for the question of the test

    SM


  • accelerate the backup of data received through series

    Hello

    I hope you can give me some advice. So far, I have not found a solution.

    I have a sensor connected by USB-serial converter to the computer (COM 2). After the beginning of the measure, the sensor sends continuously data as a string. The sensor is able to operate at different speeds and it is controlled through strings sent to the device.

    Now, I have programmed a small piece of code to read and evaluate the data from the sensor. There is no problem while looking at live data in several locations. But as soon as I try to save the data, I have speed issues. The loop is not fast enough to receive the data, because it is provided by the sensor. Temporarily remove the plots and so on, don't help not, therefore the problem is data backup. As far as I know, I should use the tables that I did and I don't think that editing bays should be the bottleneck, because they should be able to manage data in general much faster.

    In the Hyperterminal with windows, the unit works fine.

    I use VISA series with a timeout of 2 s and a buffer of 128. Baud rate is set to 460800.
    The real VISA read command is set to read 50 bytes max or stop a tank of termination (line break).
    After initialization, and sending the command start for the sensor, the device starts to send its data...
    The different speeds are:
    1 - 4 strings per second
    2 - 10 per second
    3 - 100 per second
    4 - 500 per second

    Each line gets cut, evaluated and plotted. Each value is also stored in a table (which could be saved after the program stops).

    In the photo, I deleted several commands sent to the probe, because they are not relevant and it doesn't matter (of failure) if I remove them in the program or not. It goes the same for plots. After setting the device at the higher speed, the program fails, because there is more data than labview bed. (I have already said, that without the tables it works very well, I do not have it?).

    So, what can I do? I'm doing something completely stupid? Is there a faster way to collect data with labview? I mean, 500 HZ, which must be nothing.

    Thanks for your help.

    Kind regards

    HD

    PS I'm continues LabVIEW 8.6

    Computer: Intel Core2 Duo E8500 3.16 GHz with 3 GB of RAM

    SW: Windows XP SP3

    You use insert into table with each iteration and forcing LabVIEW to keep reallocation memory for the berries. It is not very effective. Instead, I advise you to use the architecture of producer/consumer and transmit data back to the consumer loop where you write the data. Shift registers and who would skip all the functions to insert it in the table. You also use local variables and property nodes. Neither one of those who are very fast either. Can't tell from the picture why those are used. Also, consider using a structure of the event for these Booleans wired for the structures of the case. Do you really need those who questioned all the time and run the code with each iteration, or do you just need them to run once when the Boolean value changes?

  • The analysis table of Boolean in FPGA

    Hi all

    Although I programmed in LabVIEW several times, I am quite a novice when it comes to programming on an FPGA, and I learned that I will (which, so far, has worked with little problem).  However, I have solved my most recent problem and more I read on the FPGA, less certain I am that what I try to do possible.

    The task is to read in a number of bits of the digital input/output lines of the FPGA and the analysis of these bits in specific words / "bytes."  For the application of the VI that I have attached, I rigged reading in a certain number of bits by providing three words of 26 bits (for a total of 78 bits) that have been defined on the front panel.  After providing the bits specified, I try to analyse the bit array in the specific words that are given by the following logic:

    1. find a start bit of 0 (false bit).

    2. once the start bit of 0 (false bit) is the word that seeks to analyze is the next 10 bits.

    3. after the start bit and 10-bit of data is a 1 (true bit) stop bit.

    4. Repeat steps 1-3, five times.

    The logic above, should be six words analyzed in total for the provided VI.  Unfortunately, I can not simply take 12 bits (1 start bit, 10 data bits, and 1 stop bit) at a time, as the number of bits of padding between successive words is variable.  The VI I provided is a version of how I proposed to perform the logic above, but I can not compile the project/VI, I get constantly mistakes "Tables to be fixed size."  To my knowledge, all the tables in the VI have been allocated in advance, and seems to be deterministic.

    If anyone has any suggestions as to why this VI is not compiled, I would greatly appreciate.  Thank you in advance for taking the time to look at it, and I look forward to resolving this issue.

    With gratitude,

    Gregory

    Unfortunately, you'll have to rework this VI to run on an FPGA.  You cannot move tables in memory in an FPGA the way you can on a PC.  You have an array of variable size as the exit to remove the table, because the entry of length is not fixed at compile time.  In addition, two-dimensional arrays are not allowed.  Remember when coding for an FPGA you actually write the material - each value in a table is basically a circuit (that's my oversimplified understanding).  The compiler cannot affect the right number of sons to carry a table if it cannot determine the size of the array.  The table is not in memory, so there is no way to reorder running.

    There are two ways you can work around this problem, which will require an iteration through each element of the input array.  You could use a FPGA FIFO and just put the values in the FIFO which are given (that is to say, in a loop until what you have touched a start bit, putting the next 10 values in the FIFO).  Then across the FIFO, possibly in a separate loop, read 10 bits at a time to get your words out of data.  Another approach is to reorganize the table as you go.  Keep track of the current location in the input array.  When you hit a start bit, away from the 10-bit (you may need to do this one at a time) to the current location in the input array, incrementing the current location every time.  When you have completed all entries, all data will be at the beginning of the table in units of 10 bits, which you can split out as needed.

  • problem with the vista updates, dates back to December 2008

    In December 2008, I had remote access, now have broadband services. have family vista premium with service pack 1, the problem started when I tried to install the December 2008 windows updates. checked all updates essential etc. then let problem execution, not finished, then computer rebooted as it always does, is gone on the screen, then rebooted, saw the windows bar downstairs and then (as would normally go to LOG IN) it went to black screen and then off, the thing windows tried to start and check the disc and other programs of repair but kept saying could not start. Looked at this time comes to say has encountered an unknown error and could not fix, end was to use the F keys as an administrator login and do a system restore to 5 December and then worked well, have run the check disk and defrag and virus scans etc... now, my pc works fine, but I have not installed updates since December 2008, as know that it will happen if I do. However, I want to keep my vista up-to-date. I think that may be corruptions in the updates in a temporary folder somewhere, but don't know where it is. is - it there anyway to remove the files that can be corrupted or is there another solution, looked everywhere for answers in the forums and helpdesk there were several other people in the same question. My computer work fine, but I wonder if I will ever be able to install an update again. I have to be clear that I can run windows update without issue, it lists later and everything but when it's this thing to reboot it goes back to square one as shown above. Something in the updates is messing up my system and even widows classes as unknown error.

    Annanimo,
    Thank you for visiting the Microsoft Answers community.

    To test your corrupt file system, run the System File Checker:
    To run the System File Checker tool, follow these steps:
    Click Start and type cmd in the box start the search.
    Right click on cmd in the list programs, and then click Run as administrator.
    If you are prompted for an administrator password or a confirmation, type your password or click on continue
    At the command prompt, type the following line and press ENTER:
    sfc/scannow
    When the analysis is complete, test to see if the problem you are experiencing is resolved.

    Let us know what that discoveries and if we are to advance, support.
    Thank you
    Gloria
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

  • Drive CD/DVD not visible in BIOS, Device Manager or Windows Explorer - only during the analysis of the system.

    Until a few days ago, this problem didn't exist - I know.  My CD/DVD drive is no longer recognized in Windows Explorer, BIOS or Device Manager.  It doesn't, however, appears briefly in Windows Explorer in the analysis of the security of the computer.  It allows to open/close, etc.  and when it is visible, I am able to open the drive and see the contents of the CD.  Then it disappears again.  The light flashes indicating that he works and I can hear it trying to read the CD.  I uninstalled iTunes because I read somewhere that this may have been the issue - but that didn't work.  I tried the system restore, registry cleaners, removal of upper/lower case filters from the registry, used the program Fixit found on the site Web of Microsofts etc and still no luck.  Any ideas?  The computer is a gateway SX2850 (?) with Windows 7 Home Premium installed.

    Hello

    Follow these steps to remove corruption and missing/damaged file system repair or replacement.

    Start - type in the search box - find command top - RIGHT CLICK – RUN AS ADMIN

    sfc/scannow

    How to fix the system files of Windows 7 with the System File Checker
    http://www.SevenForums.com/tutorials/1538-SFC-SCANNOW-Command-System-File-Checker.html

    Then run checkdisk (chkdsk).

    How to run check disk in Windows 7
    http://www.SevenForums.com/tutorials/433-disk-check.html

    ==========================================================

    After the foregoing:

    References to Vista also apply to Windows 7.

    Step 1: Please do all the same underneath if you did some before as is often total
    a process that solves the problem.

    Try this - Panel - Device Manager - CD/DVD - double click on the device - driver tab.
    Click on update drivers (this will probably do nothing) - RIGHT click ON the drive - uninstall.
    RESTART this will refresh the default driver stack. Even if the reader does not appear to continue
    below.

    Then, work your way through these - don't forget the drive might be bad, could be a coward
    cable or slight corrosion on the contacts (usually for a laptop) and other issues.

    Your CD or DVD drive is missing or is not recognized by Windows or other programs
    http://support.microsoft.com/kb/314060 - a Mr Fixit

    Try this fix manually if the Fixit 314060 does not work
    http://www.pchell.com/hardware/cd_drive_error_code_39.shtml

    Your CD or DVD drive is missing or is not recognized by Windows or other programs-
    a Mr Fixit
    http://support.Microsoft.com/kb/982116

    The DVD player does not work after installing Windows 7
    http://support.Microsoft.com/kb/975270/

    The CD drive or the DVD drive does not work as expected on a computer that you upgraded to
    Windows Vista
    http://support.Microsoft.com/kb/929461

    When you insert a CD or a DVD, Windows Vista may not recognize the disc
    http://support.Microsoft.com/kb/939052

    Your CD or DVD drive cannot read or write media - A Mr Fixit
    http://support.Microsoft.com/GP/cd_dvd_drive_problems

    CD/DVD drive does not appear in Windows Vista, or you receive this error during Windows Vista
    Setup after booting from the DVD (AHCI)
    http://support.Microsoft.com/kb/952951
    Drive CD - R or CD - RW Drive is not recognized as a recordable device
    http://support.Microsoft.com/kb/316529/

    Hardware devices not detected or not working - A Mr Fixit
    http://support.Microsoft.com/GP/hardware_device_problems

    Another possibility is that the cables are loose. Remove ALL power, then make sure that the cables in both
    ends. Remove and replace, do not just tight. For laptops, you can often clean power and
    contacts data with a pencil eraser.

    Some DVD players do not use the Windows default drivers so check with the manufacturer of system and
    manufacturer of device to see if there is a firmware or drivers for your drive if necessary.

    ===============================

    Step 2: You have disc problems as the CD/DVD is actually 4 discs in 1 case (CD & DVD
    Burn and CD and DVD read). So it is not unusual for 1 or 2 operational so that other parts
    do it right.

    Did you follow the Troubleshooting Guide for the reader who still does not work? There are
    the entries in registry that the troubleshooter does not solve and those who "might" be the cause.

    Check with your Maker system and a device for the two possible firmware updates and the
    correct registry entries for your car.

    Here are the keys that I of course are those in question - for the subkeys of the CD/DVD drive
    as there will be other subkeys in these keys. Do not forget to ask specific keys involved as well as
    the parameters.

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\IDE

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Hardware Profiles\0001\System\CurrentControlSet\Enum\IDE

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Class\ {4D36E965-E325-11CE-BFC1-08002BE10318}

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

    You can probably find more info here and maybe even the exact registry settings for your
    CD/DVD drive someone with the same model.

    Forums - a lot of expert real help
    http://Club.myce.com/

    CD/DVD units
    http://www.myce.com/storage/

    Use DevManView to locate the CD/DVD in the registry (be careful and do a prior Restore Point)
    nothing change) - find the DevManView device and then make a right click on it free in RegEdit.

    DevManView - free - an alternative to the standard Windows Device Manager, which displays
    all devices and their properties in flat table, instead of the tree viewer
    http://www.NirSoft.NET/utils/device_manager_view.html

    I hope this helps.

Maybe you are looking for

  • Noisy fan with 10 Windows using Portege Z30 - B

    I have my Toshiba Portege Z-30 b for the last 7 months. He received with Windows 8 pro. installed, all played very well. I have upgraded to Windows 10 about 5 months ago, after the upgrade, the fan ran constantly at a high unacceptable noise. Toshiba

  • HP Pavilion a6000n desktop: adding false graphic RAM and freezes start.

    Well, I'm back with the same machine as the previous assignments.  I ordered the recovery of Surgeons of the computer disks and that they were unnecessary because the computer does not see any cd/dvd I have to install.  Finally gave up and ordered a

  • Deactivation of the elements of the Interface

    I want to disable an interface once you press the stop button. Logically for me, based on the experience of baseline programs, it should work. However, LabVIEW does not interpret it as such. No idea where I am going wrong? Joined the program

  • How can I avoid hotmail and restore my msn account?

    My computer crashed so I got a transfer of data to a new computer.  When the transfer has been completed, I got Hotmail, but can't access my MSN.com account.  It is the only account that I use to send and receive e-mails.  The (deleted), (deleted) us

  • cannot start the window 8 dvd...

    I'm trying to install window 8... I put the dvd in the drive... and restart... and I pressed f9 and choose internal cd dvd rom... After pressing enter the window normally starts... no installation of window screen 8... I used f.f. bootable too, but h