Obtain Queue Data Type

I am working my way through my first Producer Consumer vi and have two questions. 
1. The data I am enqueuing is x,y,z acceleration samples of type Waveform. The snippet shows how I set the data type in Obtain Queue. It's rather ugly and disturbing even though it appears to work.  Is there a more elegant and beautiful way to set the data type?
2. The sample rate of the accelerometer is 5120 Hz.  The DAQmx Read buffer is of lenght 1024 samples.  Hence, it takes 200 [ms] to fill the buffer.  I've set the metronome to 100 [ms] to ensure that the Producer doesn't miss any samples.  That means the Producer While Loop will spend a good portion of its time waiting.  Right?  Does having wait cost anything?
In LabVIEW's ProducerConsumerExample.vi the sample rate is 10000.  The Read buffer size is 1000.  And the metronome is set to 100 [ms].  The sample rate of the device comes from the hardware device in the cDAQ.  The 100 [ms] interval comes from the PC.  Won't there be a mismatch?  I'd like to understand this before I set my metronome to 200 [ms].
Solved!
Go to Solution.

Arizona_Joe wrote:
So, can you shed some light on the behavior of the While Loop you mentioned that does not have a metronome and is is paced by DAQmx? I would think it would do a lot of spinning. 
It isn't spinning because it is waiting inside of the DAQmx Read for N samples to be gathered.  That is not an instant data request.  It takes time to gather those samples.  That length of time is dependant on your sample rate and how many samples you are requesting.  So because it is waiting inside of the DAQmx Read, there is no need to add an additional wait.  Let the DAQmx Read limit the loop rate.
It is actually just like the consumer loop for the Producer Consumer.  The reading of the queue will limit the rate at which that loop runs.  Therefore, it needs no wait.
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines

Similar Messages

  • Typecasting message queue data for DQGoop Inheritance

    I made a test typecasting message queue data type and tried to access and modify my datas.
    It works in one way but when I try to copy something into my data labview crash...
    I guess labview realocates my data space.
    Does anybody have an idea how to outpass that thing?
    Pierre
    Attachments:
    Test DQ Inh NoCrash.vi ‏62 KB
    Test DQ Inh Crash.vi ‏62 KB

    Your example crashed for me. I suggest you should use flattened strings instead of type cast. I made an example of how to use flattened strings for upcasting and downcasting class member data elements. After I made the example I noticed that it doesn't work with LV 7.1 since flatten to string has different functionality. I also managed to make virtual function calls.
    So the LV 8.0 example of data structure that can be used to implement class inheritace are attached.
    Also the broken 7.1 version is attached. The rest of the binary string terminal of the Unflatten From String in the middle of the vi should be connected to the unconnected terminal of the Concatenate Strings.
    Tomi
    Tomi Maila
    Attachments:
    Inheritance_Example.zip ‏19 KB
    inheritance_example_71.zip ‏17 KB

  • Is it possible to get the element data type of a Queue from itself?

    Hi everyone,
    i have a Q that has a cluster as element data type.
    now when i want to enqueue
    i'll use bundle-by-name
    and for that i'd have to have my data-type present
    (long cable from whereever (possibly from where i obtained the Q).
    my question is,
    whether there is a method/property-node/something that allows me to
    wire the Queue Refnum into it and receive the element-data-type,
    so i can then input into the top of bundle-by-name?
    (i really dont want to have that cable all over the place)
    the reason i ask here is that
    the help for the outgoing Queue Refnum from the Obtain Queue method,
    shows the element-data-type and so i hope there might be a solution.
    thx for your time
    and cheers
    j
    Solved!
    Go to Solution.

    If I understand your question correctly, the answer is "Yes, it's very easy ..."
    The answer is "Preview Queue".  Here I create a Queue of some mysterious type (it's a cluster having a Thing and a Center, but you don't know that yet).  I take the Queue reference from whereever I can find it and pass it into Preview Queue Element.  I take the output and use it to define my cluster in Bundle by Name.
    Two caveats.  This copies the first element of the Queue into the cluster, so you probably need to be sure to define all of the elements of your cluster.  But what if the Queue is empty (as mine is, above, as I just Obtained it) -- well, that's why 0 is wired into the TimeOut input, since I do not want to wait "forever" (-1) for the empty Queue to have an element!  Turns out that even in this case, you still get the correct Cluster elements!
    Neat, huh?
    Bob Schor

  • Liquid data type updates

    Hi everyone,
    With the next release (to go out on Monday) we're adding proper date format support in liquid for all modules. Besides all the improvements and additions made available with this release, one important note, which requires you to do some updates after the release, is that we're breaking backwards compatibility for liquid date tags by outputting the dates in ISO 8601 format ("yyyy-MM-ddTHH:mm:ss") instead of current format(“yyyy-MM-dd”).
    Here is a brief overview of the changes:
    All module fields which represent date or date times are now passed to Liquid as date time objects (previously they were passed as strings). This brings the following benefits:
    Comparison between date time objects works correctly
    It is possible to compute the difference between two date time objects using the minus filter. Example: {% assign dateDiff = Globals.Site.DateNow| minus: myDate %}
    We added the means for obtaining the current date time: Globals.site.dateNow. The returned date is in the site’s time zone.
    By default, when no filter is applied, all date variables will be output in the following ISO 8601 format: “yyyy-MM-ddTHH:mm:ss”. For example {{ myDate }} would output something similar to: “2014-12-12T07:19:49”. (Note: this is a backwards compatibility breaking change, as previously we outputted dates using the following format: “yyyy-MM-dd”. The breaking change only affects Liquid tags). Following the release, you should update your sites using the provided date filters to format the dates as you need.
    The output of date time variables can be formatted using the following filters:
    date (with no parameters)– displays a nice to read string representing just the date part from the date time variable. The date is formatted in the site’s culture. This compatible with the way older BC tags display dates. For example {{ myDate | date }}, in the English US culture will output a string similar to: “12-Dec-2014”.
    datetime (new filter) – displays a nice to read string of the date time variable using the site’s culture. This compatible with the way older BC tags display date time. For example {{ myDate | datetime }}, in the English US culture will output a string similar to: “12-Dec-2014”.
    date “format” (existing filter, nothing updated, mentioned here just for consistency) – displays the date in the site’s culture using a format specified by the format variable. The list with the available formats is available here: http://msdn.microsoft.com/en-us/library/8kb3ddd4%28v=vs.110%29.aspx. Note that the date filter can also be used to format objects that result as a difference between two date time objects, however, in this case the format string will respect a different set of rules as defined here: http://msdn.microsoft.com/en-us/library/ee372287%28v=vs.110%29.aspx. The following example demonstrates how to display just the number of days in the difference between two dates: {{ Globals.Site.DateNow| minus: myDate| date: "%d" }}
    We added the Convert filter which can be used for converting variables to a certain type. The syntax is: variable | convert: “type”. Below are the values supported by the type parameter:
    “date” – converts a variable to a date time instance. We only support the following formats for strings that are converted to date time: “yyyy-MM-ddTHH:mm:ss” and “yyyy-MM-dd”.
    “number” – converts a variable to a number instance. If converting from string, only period “.” is supported as a decimal separator. This filter will probably be most useful when trying to convert GET query parameters: {% assign pageNumber = Globals.get.pageNumber | convert: “number” %}. The previous example assumes that URL that loaded the page contains a parameter named pageNumber. The convert numeric filter is an alternative to the rather hack-ish approach of converting to numbers using mathematical operators: {% assign myNumber = variable | plus: 0 }. Please note that it is not recommended to use the convert numeric filter just to assign numeric constants. For example, this approach is not recommended: {% assign myNumber = “3.14” | convert: “number” %}. Use the following approach instead: {% assign myNumber = 3.14 %} (note the lack of quotes around 3.14 in the second example).
    “boolean” – converts a variable to a boolean instance. Please note, that just as it is the case with numerics, it is not recommended to use the “boolean” filter for declaring a boolean constant. For example this is not recommended: {% assign myBool = “false” | convert: “boolean” %}. Use the following syntax instead: {% assign myBool = false %}
    “string” – converts a variable to its string representation.
    We added implicit casting to the most relevant type in comparisons and inside filters representing mathematical operations (plus, minus, times, divide, modulo). With implicit casting, if one of the two operands is of type string and the other is of a different type (for example numeric or date time), we will attempt to convert the string operand to the type of the other. The conversion will fail if the string is not in an appropriate format for the type it is converted to (same rules as in the Convert filter are applied). In comparisons, if the implicit casting fails, the comparison is made with both operands converted to strings. Additional notes:
    Implicit casting allows using date time literals directly in comparisons if the other operand is of date time type. For example, this will work correctly since "2015-01"15" will automatically be converted to date time before making the comparison: {% if myDate > "2015-01-15" %}Some message{% endif %}
    Date parts obtained using the date filter can be used directly in comparisons with numerics. For example:
             {% assign daysDiff = Globals.Site.DateNow| minus: myDate| date: "%d" %}
              {% if daysDiff < 10 %}
                A message
              {% endif %}
    With the implementation of implicit casting we also fixed some rather funny bugs related to comparisons and mathematical operations. For example, previously, 5 < 5.5 was evaluated as false, but 5.5 > 5 was evaluated as true. Also the result of 5| plus: 5.5 was 10, but the result of 5.5| plus: 5 was 10.5 (now 10.5 is the result of both operations, as expected).
    As a potential caveat, note that implicit casting will bring the operands to the relevant type only if one of them is actually of that type. If both operands are of type string, the comparison is made as of between strings. This means that following condition is evaluated as false {% if "3" < "15" %}, because as a string "15" is smaller than "3".
    Implicit casting from string to numeric only works if the string represents just a numeric. If the string contains additional characters, like a currency symbol, the conversion will fail. For example, this will not work correctly {% "$15" < 20 %}. Our goal, in the next releases, is to update all modules containing price related tags to have them in plain numeric format.
    We added the following filters for easily formatting numeric values representing prices.
    number - displays numbers with a fixed number of two decimals using the decimal separator appropriate to the site's culture. For example, in the English US culture, {{ 99| number }} will display 99.00
    currency - displays numbers in the same way as number but also inserts the currency symbol at the beginning of the returned value. The currency symbol respects the site's culture. For example, in the English US culture, {{ 99| currency }} will display $99.00
    In the next release or releases, we're going to focus on fixing the remaining data types for modules.
    Cristinel

    Liam, the server date isn't helpful for converting timezones. We would need a direct date filter. With a filter for UTC and one for the user we should be able to do quite a bit from there.
    The most powerful things that could be implemented for date time are the following:
    • moment.js and Moment Timezone built into the filters.
    • the ability to add time info into date time fields
    But I know that's a tall order.

  • Table for dates in date-type in transaction

    Hi,
    Can anybody tell me the table inwhich the dates saved in the different date-types  ( which are part of date-profile) are stored for the transaction type.
    This date profile is assigned to transaction type( LEAD).
    thanks and regards,
    PD

    Hi Prashant,
    Use Table: BAD_APPOINTMENT
    Field: ORDERADM_H_GUID contains guid of Lead transaction obtained from table CRMD_ORDERADM_H.
    Field: APPT_TYPE contains information for Data Types.
    Best Regards,
    Pratik Patel
    <b>Reward with Points!</b>

  • Convert values in loop to correct data types

    I need to convert the values in a loop to the correct data types. It compiles, but I get an error. It says,
    Exception in thread "main" java.lang.NumberFormat Excepton: A
    at java.lang.Integer.parseInt(Unknown Source)
    at java.lang.Integer.parseInt(Unknown Source)
    at ExtFile.main(ExtFile.java:22)
    Here is the code:
    import java.text.* ;
    import java.io.* ;
    class ExtFile
    public static void main (String args[]) throws IOException
    // Open the external file whose file name was provided as a
    // command line program invocation argument.
    ExternalFile dataFile = new ExternalFile(args[0]);
    String dataLine = dataFile.getLine();
    char candidate;
    int curPrecinct;
    String precinctIn;
    while (!dataFile.havehitEOF())
    precinctIn = dataFile.getLine();
    candidate = dataLine.charAt(0);
    curPrecinct = Integer.parseInt(dataFile.getLine());
    // Get data line to process
    dataLine = dataFile.getLine();
    System.out.println(dataLine);
    } // EndWhile
    // Close the data file
    dataFile.close();
    } // EndMain
    } // Endclass ExtFile
    What does this exception mean and how might I fix it??

    Hello,
    The line of code:
    curPrecinct = Integer.parseInt(dataFile.getLine());accepts a String (stored in a file) and produces an int (an integer representation of the String). However, if you pass it a String which doesn't represent a integer an exception is thrown. For example, if you want to obtain an integer from the String "123a", an exception will arise because you can not parse "123a" into an int because 123a is not an int, that is, it has a letter 'a' in it - and ints do not.
    To correct this you must pass (make the line in the file) represent an int.
    I hope this works.

  • Auto number as a data type?

    Hello,
    Is it possible in Oracle to use an auto number (integer) to automatically give a number for a column such as ID whenever a record is created or inserted? This would be similar to MS Access.
    TIA.

    There has been some debate (both within NI and with customers) about whether or not the flattening/unflattening solution is actually desirable. After all, if NI made the shared variable support classes, to do the writing to the variable, the object would be flattened to a string and then unflattened when the variable is read. In other words, having the shared variable support classes does not actually remove any work that the program has to do, so having the shared variable do this behind the scenes is just syntactic sugar. The negatives crop up with the issues that Phillip raised -- suddenly the shared varible is reporting a number of errors that it did not support previously, whereas by separating the (un)flattening into a separate node, it is easier to tell where an error is arising -- was it a failure to read a shared variable or was it a failure to unflatten the data therein? By keeping the shared variable ignorant of such complex data types, it is easier to swap out the communication mechanism used -- shared variables might get support for LV classes, but TCP/IP prims might not, or whatever other communication protocol comes along in the future (i.e., the network stream primitives that are brand new in LabVIEW 2010 -- effectively queues that are usable over the network).
    Users may choose to create a custom string format for objects, one that can be unflattened by any system that uses the shared variable -- including CVI and MeasStudio. Having shared variables support classes directly does not get in the way of this, but consideration of exactly what private fields actually need to be exposed in that very global global variable might be encouraged if users are consciously aware of the serialization taking place.
    I'm not pro or con this feature at this point... this post is merely to document debate I've heard about any intermachine communications protocol handling LV classes directly.

  • Date type-specific Customizing missing for date type ACTActPln

    Hi all.
    I'm using a Web Service obtained by copying the CRM 7.0 built-in WS APPTACTCRTRC.
    I'm using it to create Appointments using an Adobe Interactive Form.
    It goes everything fine (a Date is created in the system, with all the input data properly set) excepted the dates...
    The WS uses two TIMESTAMPS, TIMESTAMP_FROM for StartDateTime and TIMESTAMP_TO for EndDateTime, whereas the GUI transaction to create Dates accepts dates and times in separated fields.
    Going in Debug I can see that the execution ends with the following error, referred to the involved entity (CRM_APPOINTMENT):
    Date type-specific Customizing missing for date type ACTActPln
    CRM_APPOINTMENT uses date profile 0000000001 with three possible date types: ORDERACTUAL, ORDERPLANNED and ORDERPROPOSED and I cannot find anywhere date type ACTActPln (just to add it in customizing).
    Is anyone able to enlight me?
    Thank you in advance!
    Alessandro
    PS I've years of experience in Java programming but I'm quite new to the SAP world. Maybe the problem is not a problem at all, but it seems to me as such. Even if it has a trivial solution, please let me know. Thx!

    Hi,
    Well I was about to write that you should enter date in decimal format. but you already did that as mentioned in How to set a date in a Form where the bound date format is a decimal?
    In response to following from above thread (copied for others to understand my response)
    Hi all.
    I'm successfully using the LiveCycle Designer and I've managed to remotely create Appointments using a CRM Web Service (a mere copy of APPTACTCRTRC).
    The only problem I'm encountering is that I'm not able to set the dates/times (start and end of the appointment).
    Dragging each of the two fields from the WSDL based Data Connection I obtain a Decimal Field limited to 15 digits.
    How can I write a date and time in such a field?
    I've tried with a retroverse date as YYYYMMDDHHmmss (for example, 20100301124500) but it does not work
    (the appointment is indeed created, but with the start date and time fields filled with
    the current date/time and the end date and time fields filled with the current date and time plus 10 minutes).
    The retroverse date above is only 14 digit long, so, maybe, this is the problem.
    But, given the field definition, I'm not able to fill a blank space between the date and the time.
    I'm not able to put a dot either.
    What should I do?
    Any suggestions?
    Thank you in advance.
    Alessandro
    15 digit in UTC time format here is fraction of second so you should enter 201003011245000 (add one more zero).
    14th Oct 2010 16:00 should be written as 201010141600000, so just try it and and see if it works, I guess if you do not supply end time then by default it will be starttime + 10 min but this is just guess.
    Regards,
    Gourav

  • Alter mount database failing: Intel SVR4 UNIX Error: 79: Value too large for defined data type

    Hi there,
    I am having a kind of weird issues with my oracle enterprise db which was perfectly working since 2009. After having had some trouble with my network switch (replaced the switch) the all network came back and all subnet devices are functioning perfect.
    This is an NFS for oracle db backup and the oracle is not starting in mount/alter etc.
    Here the details of my server:
    - SunOS 5.10 Generic_141445-09 i86pc i386 i86pc
    - Oracle Database 10g Enterprise Edition Release 10.2.0.2.0
    - 38TB disk space (plenty free)
    - 4GB RAM
    And when I attempt to start the db, here the logs:
    Starting up ORACLE RDBMS Version: 10.2.0.2.0.
    System parameters with non-default values:
      processes                = 150
      shared_pool_size         = 209715200
      control_files            = /opt/oracle/oradata/CATL/control01.ctl, /opt/oracle/oradata/CATL/control02.ctl, /opt/oracle/oradata/CATL/control03.ctl
      db_cache_size            = 104857600
      compatible               = 10.2.0
      log_archive_dest         = /opt/oracle/oradata/CATL/archive
      log_buffer               = 2867200
      db_files                 = 80
      db_file_multiblock_read_count= 32
      undo_management          = AUTO
      global_names             = TRUE
      instance_name            = CATL
      parallel_max_servers     = 5
      background_dump_dest     = /opt/oracle/admin/CATL/bdump
      user_dump_dest           = /opt/oracle/admin/CATL/udump
      max_dump_file_size       = 10240
      core_dump_dest           = /opt/oracle/admin/CATL/cdump
      db_name                  = CATL
      open_cursors             = 300
    PMON started with pid=2, OS id=10751
    PSP0 started with pid=3, OS id=10753
    MMAN started with pid=4, OS id=10755
    DBW0 started with pid=5, OS id=10757
    LGWR started with pid=6, OS id=10759
    CKPT started with pid=7, OS id=10761
    SMON started with pid=8, OS id=10763
    RECO started with pid=9, OS id=10765
    MMON started with pid=10, OS id=10767
    MMNL started with pid=11, OS id=10769
    Thu Nov 28 05:49:02 2013
    ALTER DATABASE   MOUNT
    Thu Nov 28 05:49:02 2013
    ORA-00202: control file: '/opt/oracle/oradata/CATL/control01.ctl'
    ORA-27037: unable to obtain file status
    Intel SVR4 UNIX Error: 79: Value too large for defined data type
    Additional information: 45
    Trying to start db without mount it starts without issues:
    SQL> startup nomount
    ORACLE instance started.
    Total System Global Area  343932928 bytes
    Fixed Size                  1280132 bytes
    Variable Size             234882940 bytes
    Database Buffers          104857600 bytes
    Redo Buffers                2912256 bytes
    SQL>
    But when I try to mount or alter db:
    SQL> alter database mount;
    alter database mount
    ERROR at line 1:
    ORA-00205: error in identifying control file, check alert log for more info
    SQL>
    From the logs again:
    alter database mount
    Thu Nov 28 06:00:20 2013
    ORA-00202: control file: '/opt/oracle/oradata/CATL/control01.ctl'
    ORA-27037: unable to obtain file status
    Intel SVR4 UNIX Error: 79: Value too large for defined data type
    Additional information: 45
    Thu Nov 28 06:00:20 2013
    ORA-205 signalled during: alter database mount
    We have already checked in everywhere in the system, got oracle support as well without success. The control files are in the place and checked with strings, they are correct.
    Can somebody give a clue please?
    Maybe somebody had similar issue here....
    Thanks in advance.

    Did the touch to update the date, but no joy either....
    These are further logs, so maybe can give a clue:
    Wed Nov 20 05:58:27 2013
    Errors in file /opt/oracle/admin/CATL/bdump/catl_j000_7304.trc:
    ORA-12012: error on auto execute of job 5324
    ORA-27468: "SYS.PURGE_LOG" is locked by another process
    Sun Nov 24 20:13:40 2013
    Starting ORACLE instance (normal)
    control_files = /opt/oracle/oradata/CATL/control01.ctl, /opt/oracle/oradata/CATL/control02.ctl, /opt/oracle/oradata/CATL/control03.ctl
    Sun Nov 24 20:15:42 2013
    alter database mount
    Sun Nov 24 20:15:42 2013
    ORA-00202: control file: '/opt/oracle/oradata/CATL/control01.ctl'
    ORA-27037: unable to obtain file status
    Intel SVR4 UNIX Error: 79: Value too large for defined data type
    Additional information: 45
    Sun Nov 24 20:15:42 2013
    ORA-205 signalled during: alter database mount

  • OSB JCA Adapter - Enqueue - BLOB Oracle data type

    Hi,
    I am tring to enqueue a message into oracle advacned queue using JCA AQ adapter of OSB. The message in the Q has BLOB data type.
    I used AQ Adapter enqueue operation for this, and an opaqueue schema in the adapter wsdl. I created a business service out of the adapter service and tested it using
    OSB. I am able to enqueue, but then if i go and see in the data base payload the value of the BLOB column is JUNK... some funky values..
    Any help on this. Appreciate your suggestions.

    This has been resolved

  • How to  obtain last date of accounting period mmyyyy

    how to  obtain last date of accounting period mmyyyy.
    for ex: 31 st is the last date then output should be mm/31/yy.

    hi use this ....
    REPORT  ZTESTS.
    data: date1(4),
          date2(2),
          date3(2),
          date type sy-datum,
          output(8).
    parameters:p_date type sy-datum.
    CALL FUNCTION 'JVA_LAST_DATE_OF_MONTH'
      EXPORTING
        year_month               = p_date+0(6)
    IMPORTING
       LAST_DATE_OF_MONTH       =  date.
    output0(2) = date4(2).
    output+2(1) = '/'.
    output3(2) = date6(2).
    output+5(1) = '/'.
    output6(2) = date2(2).
    write:/ output.
    regards,
    venkat.

  • Oracle-specific data types vs Connection pool

    Hi, using Oracle-specific data types such as
    ArrayDescriptor and create it by a connection to an Oracle database from a WebSphere datasource throw a ClassCastException. There is no problem using these Oracle-specific data types when the connection is obtained via the DriverManager. WebSphere cannot fix the problem because these data types are
    not part of the JDBC specification.
    Some reply from Oracle?
    Thank you very much.

    Thank you but I there is no solution in that thread.
    Also, I know that WebLogic from BEA has a way around this issue... No Websphere work around ?
    No Oracle fixing ?
    Thanks.

  • QRFC - How to read queue data

    When we debug a queue from <b>SMQ1</b> transaction, control will take us to remote system and we can debug the remote function module.
    The data in the queue are stored in Raw format, through debug LUW the data is converted into actual format and it is passing the data to function module.
    My question is which program or Function module is converting queue data into actual format. I want save the queue data into an excel file.
    Please suggest me the program name/ Function module name to read the queue data into actual format.

    RSTRFCDP program will display the outbound queue data in char format,other than charecter type values it is displaying the data in special charecters.
    When we debug LUW control will go to remote system and data is converted to actual format and pass to function module. I need the program/function module which is responsible for converting queue data into actual format.

  • Shared Variables should support LVOOP as a data type

    Almost all LabVIEW data types can currently be sent through a shared variable without any hassle.  The notable exceptions are native LabVIEW classes, which cannot be selected as the data type for a shared variable.  This causes a problem for anyone who wishes to send objects across a network.  They are forced to rethink their use of LabVIEW classes, use a communication method other than shared variables, or flatten and unflatten the object on either side of the shared variable communication.  The use of classes is growing more common with every version of LabVIEW, so I think it is time for these two prominent LabVIEW features to work together seamlessly.

    There has been some debate (both within NI and with customers) about whether or not the flattening/unflattening solution is actually desirable. After all, if NI made the shared variable support classes, to do the writing to the variable, the object would be flattened to a string and then unflattened when the variable is read. In other words, having the shared variable support classes does not actually remove any work that the program has to do, so having the shared variable do this behind the scenes is just syntactic sugar. The negatives crop up with the issues that Phillip raised -- suddenly the shared varible is reporting a number of errors that it did not support previously, whereas by separating the (un)flattening into a separate node, it is easier to tell where an error is arising -- was it a failure to read a shared variable or was it a failure to unflatten the data therein? By keeping the shared variable ignorant of such complex data types, it is easier to swap out the communication mechanism used -- shared variables might get support for LV classes, but TCP/IP prims might not, or whatever other communication protocol comes along in the future (i.e., the network stream primitives that are brand new in LabVIEW 2010 -- effectively queues that are usable over the network).
    Users may choose to create a custom string format for objects, one that can be unflattened by any system that uses the shared variable -- including CVI and MeasStudio. Having shared variables support classes directly does not get in the way of this, but consideration of exactly what private fields actually need to be exposed in that very global global variable might be encouraged if users are consciously aware of the serialization taking place.
    I'm not pro or con this feature at this point... this post is merely to document debate I've heard about any intermachine communications protocol handling LV classes directly.

  • How to invoke a class at run-time for primitive data types?

    Hi,
    I am trying to invoke classes at run-time.
    I am using Class.forName("className") for that where the "className" is also obtained at run-time .
    The problem I am getting is when the "className" is "int" or "char" etc. the call to Class.forName("int") etc. fails giving ClassNotFound error. It works fine for "className" is "java.lang.String" or "java.lang.Integer" etc.
    How can I correct this?
    thanks in advance-
    kg

    Hi,
    Thanks all for the valuable inputs.
    I have created a hashtable of primitive data types in the form of "int" as key and "Integer.TYPE" as the object in that element of the hashtable.
    Now there is another problem I am facing and that is of 'Casting at run-time'.
    Problem is there when the Database type is 'NUMBER' which returns me a "java.lang.BigDecimal" when I do a ResultSet.getObject("XXX") for that whereas the method in the javabean expects an "int" type.
    This causes "java.lang.IllegalArgumentException: argument type mismatch"
    So I want to cast it at runtime. How can I do it?
    Here is the code I am trying (which generates the above exception)
    public static void setBeanField(Class pCls,Object pObj,String pMethodName ,Object pColumnValue,Class
    pColumnTypeClass){
    try{
    if(pColumnValue!=null){
    Class[] paramTypes = new Class[]{pColumnTypeClass};
    Object[] args = new Object[]{pColumnValue};
    Method meth = pCls.getMethod(pMethodName,paramTypes);
    meth.invoke(pObj,args);
    }catch(Exception e){
    System.out.println("Exception in TestInrospection.setBeanField " + e);
    thanks in advance-
    kg

Maybe you are looking for

  • I can't edit overset text in InDesign CS4

    I have spent the last several hours trying to fix the overset text.  Every time I click on the little red overset text in the lower right hand corner, another text box pops up.  I have deleted it at least 150 times.  I just cannot get it to work.  I

  • ASPX File Upload

    Does anyone know how to check the size of a file before its uploaded to the server? My problem is if someone tries to upload a file that exceeds the max limit an exception is thrown before any kind of server side validation can be performed. asp.net

  • Formula column in XML publisher report

    Hi I need to include formula column in my XML publisher report, please any one guide me on this. Thanks in advance

  • CSSD does not start during root.sh execution

    hi, I am using oracle10gR2 on solaris 9 sparc. when i start root.sh script it stops at following point. Running Oracle10 root.sh script... The following environment variables are set as: ORACLE_OWNER= oracle ORACLE_HOME= /u01/app/oracle/product/10.2.

  • No resultSet with preparedStatement

    Hi, been reading many topics on this but I just dont get away with the solutions posted. I'm quering MSSQL-server 7.0 with a java-application with the following code snippet:           String s = "SELECT e.[value] FROM experiment_data e INNER JOIN "+