Jump to content

Neil Pate

Members
  • Posts

    1,185
  • Joined

  • Last visited

  • Days Won

    110

Everything posted by Neil Pate

  1. Hmm still not really making any progress with this. My DB definitely has millisecond data in it. I have a table t1 with a single column of type DATETIME and have two records in this table, both with millisecond precision. If I execute the query from the server I get back the milliseconds, but the same query from within LabVIEW drops the milliseconds. It seems this is an issue with the OBDC driver, but I am not sure how to solve this. It has been suggested to perform an on-the-fly conversion to text as per my previously linked thread, but I cannot get this query to work properly. Any ideas?
  2. This is exactly the same method I use. I use it to dynamically launch single instance of VIs that are never expected to be re-entrant, and also re-entrant clones. The only difference for the re-entrant clones is the flags used to open and the VI itself needs to be set to re-entrant. The two flags in the VI below are just the 0x80 and 0x40 flags.
  3. Using the standard DB toolkit I cannot yet retrieve the fractional part using, but this could just be me doing something wrong as I have seen threads (like this) which states it should be possible. I have now confirmed using the mysql tools on the server that I can insert and retrieve fractional seconds using the DATETIME(n) type where n is the number of decimal places. Will do some more digging tomorrow.
  4. Finally upgraded and of course the command to create the table did not work... because I had a mistake in. CREATE TABLE t1 (t dt DATETIME(6)); The "t" above was the remname of another column I had deleted from my query to simplify it, but obvsiously did not delete enough of it. Should be: CREATE TABLE t1 (dt DATETIME(6)); Still don't know if this has worked but getting somewhere slowly.
  5. Update: looks like my LAMP VM appliance is actually shipping with MySQL 5.5 which does not supprt fractional timestamps.. Updating at the moment...
  6. Hi guys, I need to be able to insert and retrieve a timestamp into an SQL database with miliisecond precision (ideally three digits of precision). Complicating the issue is that my final system is going to be hosted in a MS-SQL (so T-SQL) DB, but I am testing locally using a LAMP stack. I have done quite a bit of digging, it seems T-SQL would like me to use datetime2 type, but this is not available in MySQL. Apparently I can should use DATETIME(3) as the type. I am struggling to create a table with this as a valid column. I am using a LAMP VM appliance which I believe is running the a version of MySQL that supports fractional timestamps, but the SQL statement to create the table is failing. CREATE TABLE t1 (t dt DATETIME(6)); Any ideas what I am doing wrong? Secondly, it looks like the NI DB Toolkit has very primitive support for timestamps, and people prefer to use strings? Can anybody share their current "best practice after having done it wrong a few times" with me? Beer on me for solutions Thanks
  7. Filipe, I do not see NI getting into the business of suing the end users of LV FPGA. Not that I disagree with your points, I just think it is unlikely NI would go after anybody other than the obvious primary culprit. Now, even having said that, I am still not going to expose my company (or my clients) to this risk and will choose NI officially sanctioned products over questionably legitimate offerings.
  8. Yeah but haven't EULAs been proven to be pretty much worthless?
  9. Could it be something to do with the fact that those two funny looking icons are expandable XNodes at edit time and expect to be redrawn on the diagram?
  10. But they are kinda ByVal as you wire into an indicator to actually display the image. You cannot just make that association once and then assume it will automatically get updated.
  11. Bingo! Thanks James. So Image refs are just plain old normal U64 size refs? I sometimes wish there was a way to see refs as native "pointers" in a probe rather than the special type (i.e. the image). I suppose I could create a custom probe and just display the U64...
  12. More strangeness (probably just me not getting something). Why are all four Image references the same?
  13. Hi gang, Simple question, can I treat a Vision Images ref just like any other U32 ref with all the rules applicable like forking wires etc? It seems to me that there is some kind of special stuff going on with Vision Image refs. Another related question, in my particular use case I have a piece of code generating a user event with an image as the data at some arbitrary fast rate. The act of Generating the user event creates the a copy, right? Some other code wants to process some of these frames (at a slower rate) and then I use IMAQ Copy to make a local copy, is this IMAQ Copy necessary or could I just hold onto the "Image" reference coming in from the user event? In the code below Images is just a local buffer I plan on using. The reason I ask is I am getting some weird behaviour whereby destroying my Images refs as shown in Capture3.jpg kills my acquisition code as well. (I presume because I am forcing all images to be destroyed, but I am surprised this is happening)
  14. I think you are trying to bite off more than you can chew here. DVRs, LVOOP and especially Dynamic dispatch is not really the first thing you want to learn on your LabVIEW journey.
  15. I recently ran a simple vision application with a single camera that ran perfectly smoothly on a desktop CPU but absolutely choked on an Atom tablet. Nothing fancy going on either...
  16. Perhaps not the greatest way to ask for help.
  17. Peter, have you tried accessing the Excel worksheet by index instead of name?
  18. Thanks. I think I am mostly on the same page as everybody here.
  19. I did not need to do as you documented, it was sufficient for me to just re-select the broken method call inside the offending RGT VI . If memory serves me correctly it was the "SaveAs" method of the _Workbook object. All I had to do was reselect the method and it then was no longer broken. I think I noticed that the new method had an additional input. But as I mentioned, although this worked fine on my PC it was broken on the target PC which had a much older version of Excel, so in a panic I uninstalled Office 365 and installed Office 2010 and everything then worked fine.
  20. I have flip-flopped with this issue for like forever. Say I have a simple dialogue that can be cancelled by the user, is it more sensible to return the cancelled status or the ok status? I have always done it by returning a Cancelled status, I am just curious as to what others think is sensible.
  21. I do not have an answer to your problem but can only share something that happened recently which is probably not related to your issue but I will say anyway. I have an Office 365 subscription and one of the more recent updates broke the report generation toolkit as the ActiveX interface to Excel changed. I was able to manually relink the ActiveX component in the code and everything worked fine on my PC after that, but the executable would then not run on my target machine which had an older version of Excel on it.
  22. As far as I can tell a Matrix is just a typedef to a 2D double, there is nothing at all special about it.
  23. Normally if I have multiple 1D numeric arrays if I want to combine them into a 2D array to display as a table or write to file or whatever I used to Build Array and then transpose the 2D array, however I have discovered that the Build Matrix prim is actually configurable and defaults to assembling by columns. Hooray! This is probably old news to some people, but I share anyway for those that don't know
  24. I would second what smithd wrote. What is your experience with OO in LabVIEW? Certainly trying to refactor an application to OOP is not a good place to start your journey I think.
  25. Ok good. Don't worry about the cluster for now. How did you generate that array, did you do it from code or manually?
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.