Data logging on date basis

I am working on a project, in that project i am logging data in text file, based on date. when date will change file will be change.
there is a condition , if month change than i have to delete text file of previous month one bye one from 1st to 30,31st.........
along with this query i am sending image of my logging vi
please give me the solution.............
Prashant Soni
LabVIEW Engineer
Attachments:
1.png ‏22 KB

If i well understood your problem, I think the solution can be found in the vi "check if file exists".
You're writing a file which name is based from the date of the month. For exemple june2010.txt.
You check if the file exists :
If yes, you store your datas with control of size.
If this file doesn't exists, you create a new one, with initialization.
Hope it will help you.
V-F

Similar Messages

  • How to data log graphs using front panel data logging?

    Hello I have a VI that collects data from DAQmx thermocouple readings and graphs the temperature vs time using a while loop to collect data and graph. I have 9 control operators that define the correction factor of the thermocouples.
    I want to create a datalogging using the option under Operations>Data Logging
    When I retrieve the data the only information that is present are the control operators correction factors that I defined. The graphed data that was created is not retrieved.
    Is there a solution to show the graphed data plots that were created on the front panel? They remain unchanged from the last run of the VI or blank if I open the VI without having ran the program.
    Thank you.

    This is expected for the Data Logging in LabVIEW. If you want to record the signla data, use the Write to Measurement File Express VI.  Here's a link with a walk-through:
    http://www.ni.com/academic/students/learn-daq/data-logging/
    The Data Logging from the Operate Menu is for recording front panel control(s), as you have observed.
    Mark P.
    Applications Engineer
    National Instruments
    www.ni.com/support

  • Log changed data in tables

    hi
    I want to hold change data information.
    For example I have table student and one row is inserted.
    Then somebody else changed the name of the student name and phone number.
    I want to hold the changed columns when an update query is executed.
    I looked at change data capture but I think it is about data warehouses and there are 2 databases in that case.
    I do not want to write triggers for all tables.
    I looked at fine grained auditing but I can take the update statement only, I do not know how can I find the changed columns, column's last data and new data.
    How can I do it? Which topic should I research?
    Can you lead me?
    Good Works

    [Flashback Query|http://www.oracle-base.com/articles/9i/FlashbackQuery.php] may be possible. but, There are some restrictions for Flashback query.
    [http://www.oracle-developer.net/display.php?id=210]
    [http://www.dbasupport.com/oracle/ora9i/flashback_Query.shtml]
    [http://www.dbasupport.com/oracle/ora9i/flashback_Query2.shtml]
    [http://www.dbasupport.com/oracle/ora9i/flashback_Query3.shtml]
    Last option is log Minor.

  • General data logging failure

    I have been receiving this error message over the past week on our Lookout 5.0 setup. After this message, no data logging happens for any logged point, not just the alarmed point! This is shown in the default alarm window that comes out of the box with Lookout.
    Lookout has v5.0 latest fixes file installed (as of mid 2006), Citadel was updated around the same time also. OS is W2K, SP4. Any ideas. Lookout and Citadel are the only things running on this box. Application is a typical base station talking to 45 remote sites. This is an example of the data logging failure alarms that I get on the alarm screen.
    //basestation/Modbus045.43107: General data logging failure (0x800045005)
    where the object name = '....Modbus045.43107' and the alarm description is 'General data logging failure (0x800045005)'
    I have several of these alarms for various sites and tags (elevation, amperage, etc.).  I've noticed that when I get this error the computer doesn't log data and I can't clear the alarms. This has happened before but I cannot seem to replicate, seemly happens randomly. Sometimes several times a day, other times it will go for weeks or months. The only way to previously get out of it is to click OK, then restart computer. Checked OS processes prior to shutting down, lookout.exe and the ldcitdl.exe, ldads.exe, and ldtsrv.exe are all running, but at 0% CPU usage.
    This last week, restarting the computer does not work anymore. System gives these types of errors after a restart. This system has been providing data consistently since its been placed in operation and lots of disk space left.
    Any suggestions on where to start debugging?

    I suggest you to create a new database.  In Max, right click "Historical Data", select Create New...
    And then in Lookout, log data to this new one.  File->Modify process, uncheck "use default vaue" and select the new database.
    If the new database works fine without the "logging failure " alarm, I think the database you are using may be corrupted.
    Ryan Shi
    National Instruments

  • How can I display only the Data Logging pull down menu on my LV front panel?

    Is it possible to hide all unused pull down menu on my front panel vi like File, Edit, View etc.. and only
    display the pull down menu for the Data logging?!
    best regards
                          Norick

    Hey,
    You can build your own runtime menu (Edit>runtime menu) and then e.g. only display the application items you want to.
    Christian

  • How can I perform data logging for a specific time??

    hello everyone,
    I am quite new in labview and I have a basic question regarding data logging. Currently I am using a cRIO9074 and doing some data logging for my test. The data logging it self works ok so far.
    But my problem is I would like to write my datas in a text file either for a specific time interval (ex)10 seconds) or for a specific amounts of data (ex)500 Samples). Can anyone give me some help regarding my problem?? Attached you can find my RT.vi 
    I would appreciate for anyhelp!
    Regards
    Yun 
    Attachments:
    BP250 Encoder Position & Velocity (Host).vi ‏92 KB

    Run your loggging program for that time. When your program terminates then it will write all the logged data so far in text file.
    Kudos are always welcome if you got solution to some extent.
    I need my difficulties because they are necessary to enjoy my success.
    --Ranjeet

  • How do I control a data log session with period and sample time?

    I need a data logging system where the operator can select 2 logging parameters: Log Period and Sample Time. I also need a START and STOP button to control the logging session. For example, set the log period for 1 hour and the sampling time for 1 second. (I may be using the wrong jargon here.) In this case when the START button is clicked, the system starts logging for 1 second. An hour later, it logs data for another second, and so on until the operator clicks the STOP button. (I will also include a time limit so the logging session will automatically stop after a certain amount of time has elapsed.)
    It’s important that when the STOP button is clicked, that the system promptly stops logging. I cannot have the operator wait for up to an hour.
    Note that a logging session could last for several days. The application here involves a ship towing a barge at sea where they want to monitor and data log tow line tension. While the system is logging, I need the graph X-axis (autoscaled) to show the date and time. (I’m having trouble getting the graph to show the correct date and time.) For this application, I also need the system to promptly start data logging at a continuous high rate during alarm conditions.
    Of course I need to archive the data and retrieve it later for analysis. I think this part I can handle.
    Please make a recommendation for program control and provide sample code if you can. It’s the program control concepts that I think I mostly need help here. I also wish to use the Strip Chart Update Mode so the operator can easily view the entire logging session.
    DAQ Hardware: Not Selected Yet
    LabVIEW Version: 6.1 (Feel free to recommend a v7 solution because I need to soon get it anyway.)
    Operating System: Win 2000
    In summary:
    How do I control a graphing (data log) session for both period and sample time?
    How do I stop the session without having to wait for the period to end?
    How do I automatically interrupt and control a session during alarm conditions?
    Does it make a difference if there is more than one graph (or chart) involved where there are variable sample rates?
    Thanks,
    Dave

    Hello Dave,
    Sounds like you have quite the system to set up here. It doesn�t look like you are doing anything terribly complicated. You should be able to modify different examples for the different parts of your application. Examples are always the best place to start.
    For analog input, the �Cont Acq&Chart (buffered).vi� example is a great place to start. You can set the scan rate (scans/second) and how many different input channels you want to acquire. This example has its own stop button; it should be a simple matter to add a manual start button. To manually set how long the application runs, you could add a 100 ms delay to each iteration of the while loop (recommended anyway to allow processor to multi-task) and add a control that sets the number
    of iterations of the while loop.
    For logging data, a great example is the �Cont Acq to File (binary).vi� example.
    For different sample rate for different input lines, you could use two parallel loops both running the first example mentioned above. The data would not be able to be displayed on the same graph, however.
    If you have more specific questions about any of the different parts of your application, let me know and I�ll b happy to look further into it.
    Have a nice day!
    Robert M
    Applications Engineer
    National Instruments
    Robert Mortensen
    Software Engineer
    National Instruments

  • How to optimize data logging in my code?

    I have my program working well enough to have it run some trials in the lab. It was run under some 'extreme' conditions to make sure data acquisiton and logging is working well.
    With frequency being 1000Hz, he requirements are that the relay goes ON for 20ms and and stays off for 250ms. This 250ms should equate to 250samples gathered.
    After a run, the saved files range from 240 to 280 samples for a 250ms setting, but some are as little as 150 samples. I need to ensure that the correct number is logged, a +/- 5% variation is 'OK' but when the samples gathered are close to half of the desired is unacceptable.
    I need the graphs wired to 'data[0]' and 'data[1]' to update in real time, to be smooth.
    Any suggestions? Every time my consumer loop executes, how many samples does my DAQmx Read, at current, receive? I do not think it's an issue w DAQmx setup, but I am not 100% sure..

    Is there any reason you're not using compound arithmatic to get into the logging loop?  What happens in those false cases?  If you're just wiring everything through, you'd be better served to only use one case structure.  Feed all three boolean values into a single compound arithmatic set to AND.  If all three are true, after the NOT used to invert the false value, it will enter the true case.  Otherwise, it'll enter the false case.  It's the same logic, but it's handled better.
    You might consider taking a look at Producer/Consumer or Queued Message Handler.  You can use these to send a message to an external while loop.  If you have multiple cores, this makes it easy to split the task to read data on one core and leave it mostly unaffected by the logging process done on another core.

  • With journaling, I have found that my computer is saving a large amount of data, logs of all the changes I make to files; how can I clean up these logs?

    With journaling, I have found that my computer is saving a large amount of data, logs of all the changes I make to files; how can I clean up these logs?
    For example, in Notes, I have written three notes; however if I click on 'All On My Mac' on the side bar, I see about 10 different versions of each note I make, it saves a version every time I add or delete a sentence.
    I also noticed, that when I write an email, Mail saves about 10 or more draft versions before the final is sent.
    I understand that all this journaling provides a level of security, and prevents data lost; but I was wondering, is there a function to clean up journal logs once in a while?
    Thanks
    Roz

    Are you using Microsoft word?  Microsoft thinks the users are idiots. They put up a lot of pointless messages that annoy & worry users.  I have seen this message from Microsoft word.  It's annoying.
    As BDaqua points out...
    When you copy information via edit > copy,  command + c, edit > cut, or command +x, you place the information on the clipboard. When you paste information, edit > paste or command + v, you copy information from the clipboard to your data file.
    If you edit > cut or command + x and you do not paste the information and you quite Word, you could be loosing information.  Microsoft is very worried about this. When you quite Word, Microsoft checks if there is information on the clipboard & if so, Microsoft puts out this message.
    You should be saving your work more than once a day. I'd save every 5 minutes.  command + s does a save.
    Robert

  • Data type of the base attribute or the base value does not match...

    ...the assigned expression.
    Hello all,
    I always get the Error
    +<ERROR+
    TEXT="'DWH.CUB_REGISTRATIONS_AW.REGISTRATIONS': XOQ-02517: Der Datentyp des Basisattributs oder der Basisgröße stimmt nicht mit dem zugeordneten Ausdruck überein.
    XOQ-01400: Ungültige Metadatenobjekte"/>
    The English message must be something like this:
    The data type of the base attribute or the base value does not match the assigned expression.
    when I run my mapping. The attribute REGISTRATIONS is NUMERIC (12,2) in the Cube and I map a NUMERIC(12,2) constant in it.
    I use a simple OWB-Mapping for loading, but I don't understand why it doesn't function. Other mappings where the attributes are out of a
    table I put in a cube are running well.
    I tried different things, but nothing fixed my problem. Any idea ?
    Thanks a lot for help
    Michael

    Technically this is a 'warning' from the server, not an 'error'. This means that the change you made should have been submitted, but you get an warning message on the client. AWM would suppress this warning, but evidently OWB does not. Can you switch to use AWM?
    Here is the definition of the warning along with 'cause' and 'action' sections. (Unfortunately these sections are not translated into German for some reason.)
    >
    02517, 0, "The data type \"%(1)s\" of the base attribute or base measure is different from the mapped expression \"%(2)s\"."
    // *Cause: Either the base attribute or base measure with the mapped expression was set to an inconsistent data type, or it was mapped to an expression of a different data type from its fixed data type.
    // *Action: When changing a mapped expression for a base attribute or base measure, ensure that the expression has the same data type; otherwise, set the data type of the base attribute or base measure to NULL first. When a base attribute or a base measure has an existing mapped expression, do not set it to a different data type.
    >
    It is probably safe to ignore this warning, but if you can post the relevant XML for the cube, then will probably be able to spot the problem. I assume that REGISTRATIONS is a measure in the cube CUB_REGISTRATIONS_AW, so this is what you can look for in the XML:
    (1) The definition of the base measure along with the datatype. It should be something like this
    <Measure>
      <BaseMeasure
        SQLDataType="NUMBER(12,2)"
        ETMeasureColumnName="REGISTRATIONS"
        Name="REGISTRATIONS">(2) The mapping info for the measure, which should looks something like this:
    <MeasureMap
      Name="REGISTRATIONS"
      Expression="...">
      <Measure Name="REGISTRATIONS"/>
    </MeasureMap>I don't know if you can get the XML directly from OWB. If not, then DBMS_CUBE.EXPORT_XML should work (assuming you are in 11.2). You could also attach AWM and save the cube to an XML template.

  • How to read a byte data from maxdb data base

    Dear All,
    I have a issue in reading the data from database table.
    I have a column named as templateData which contains the byte data (biometric template data, which comes from fingerprint device) which is DataType of LONG and CODE of BYTE.
    I am not using the below to get the template data
    Connection con = null;
      Statement stmt = null;
      ResultSet resultSet = null;
    byte[] DbBioData = new byte[1024];
    InitialContext ctx = new InitialContext();
       if(ctx == null)
         throw new Exception("Boom - No Context");
       DataSource ds = (DataSource)ctx.lookup(db_drvstr);
       con = ds.getConnection();
       stmt = con.createStatement();
       resultSet  = stmt.executeQuery(db_query + " where SUBJECT_ID='"+ username +"'");
       if(resultSet.next())
        DbBioData = resultSet.getBytes(1);
        _loc.infoT("verify", "verify::Got BioData From MAXDB" +DbBioData );
        loc.infoT("verify", "verify::Query is: " +dbquery + " where SUBJECT_ID='"+ username +"'" );
    But I am not getting the proper data, could anyone please tell me the way to read the biometric data from data base table.

    Hi Kishore,
    is it me or is there no query definition in that code?
    I see that you concatenate a "db_query" with a string to make up a WHERE clause, but the db_query is nowhere defined before.
    So at least you should provide something like
    stmt = con.createStatement("SELECT templateDate FROM <tablename> ");
    before you do anything with the query.
    Besides this: have you ever heard of SQL injections? Try to use BIND-variables instead of concatenating strings. Otherwise your application will spend much time just with parsing your queries...
    Hmm... possibly the best thing you could do about this is to read the JAVA manual for MaxDB:
    <a href="http://maxdb.sap.com/currentdoc/ef/2de883d47a3840ac4ebb0b65a599e5/content.htm">Java Manual (SAP Library - Interfaces)</a>
    Best regards,
    Lars
    Edited by: Lars Breddemann on Dec 17, 2007 1:12 PM - corrected link

  • Add new payment term base on sales order contract date and shipment date

    Dear Sir/Madam,
    My company need to create new payment term base on sales order's contract date and shipment date.
    the first time is 30% made in T/T within 30days from contract signed date.
    the second time is 70% made in T/T before shipment.
    I don't know how to configuration this payment term base on that both date, who can tell me ,thanks very much!
    Best Regards
    Danny Zhang

    Hi,
    You have to define the PAYMENT TERMS as per days and Percentage.
    Define the Payment terms in the transaction OBB8 and assign this payment terms in the CUSTOMER MASTER and will be copied to the SALES ORDER from the customer master
    In the MATERIAL MASTER in the SALES ORG 1 view you have to check the field CAHS DISCOUNT In the Pricing procedure you can defin the CASH DISCOUNT condition type ( in standard there are two SKTV & SKTO)
    Now process the sales order and check
    regards,

  • Base line date field ( header data 2nd tab) to be made noneditable in MIRO

    Hi friends,
    My requirment is to make Base line date field ( header data 2nd tab) to be noneditable in Tcode MIRO .
    This base line date should be noneditable only for one specific company code.
    Help me with some clues.
    regards
    Sathish

    why cant you use a screen variant....In SHd0..
    also check this..
    [http://forums.sdn.sap.com/click.jspa?searchID=37685778&messageID=8389969]

  • Help please: DAQWare or data logging software (multichannel data capture) questions

    I am writing regarding DAQWare, data logging software, and the PC-LPM-16
    board, which a group of us a trying to come to grips with. This is rather
    lengthy, I'm afraid...
    We are a group of college students in a computer programmer/analyst
    program. We have a course that involves doing a project to go through the
    software development lifecycle (or as much of it as can be done in a term).
    For our project we teamed up with a group in the industrial hygiene
    program; they have a computer (standalone) with a PC-LPM-16 (PnP) DAQ board
    and the NI-DAQ software (all of this has been around for a few years, but
    has not been used much), and our goal was to capture the data they are
    measuring (atmospheric pollutants) to an Microsoft Access database.
    We are not familiar with DAQ systems, but were shown the software they had
    installed. This included DAQWare (appears to be version 2.0). We thought
    we could use DAQWare to log data to a text file, which we then would import
    into the Access database. We came up with VBA code to parse the ASCII text
    file created, but have run into one problem: DAQWare does not timestamp
    each sample, but only puts a single timestamp in the header information.
    Now we could extrapolate the time for each line based on the sample rate,
    except that sometimes it seems to put in 8 values per sample, sometimes 12
    values. For instance, in the sample of a text file below, the capture was
    run for 1 minute at a sample rate of 60, and there were 480 measurements in
    the file, or 8 lines of measurements per sample. (At a sample rate of 100,
    we got 800 measurements in the file etc.) This was two weeks ago. Today,
    we returned to capture more data, and DAQWare was logging 12 measurements
    per sample (so at a sample rate of 100, we ended up with 1200 lines of
    measurements). We do not know where this factor of 8 or 12 is coming from
    or how it got changed in the two weeks between captures. We would like to
    be able to have them just run DAQWare, for days on end if they wanted,
    capture the data to file, then use our code to parse the text file into the
    database, but if we cannot put timestamps on the readings, there seems no
    point.
    *** Example of a capture below... ***
    DAQWare File
    Version: 2.0
    Number of Lines in Header: 10
    Comment:
    Date: 10-18-1999 Time: 10:01:39
    Sample Rate: 60.0
    Scan Rate: 0.0
    File Format: 1
    Samples per Channel: 480.0
    Number of Channels: 5
    O3 SO2 NOX NO2 NO
    4 3 2 1 0
    1 1 1 1 1
    0.537 0.276 0.259 -0.017 0.015
    0.537 0.273 0.261 -0.022 0.012
    0.537 0.276 0.259 -0.037 0.012
    0.537 0.276 0.264 -0.007 0.015
    *** and so on... ***
    Regarding this attempt to use DAQWare:
    1. Can you tell us where this factor (8 or 12 or however many more readings
    than we would expect) means, where it is read from or set?
    2. Is there an updated version of DAQWare that we should download that
    would be better?
    3. Is there some other existing software that we can download to use to
    perform basic logging of multichannel analog input to a text file (with
    timestamp)?
    I realise that the software comes with tools (DLL functions) that one can
    use to create custom software to interface with the DAQ board, but in the
    limited amount of time we have we are not sure we can learn enough about
    these functions to write our own datalogging software.
    However, to see if I could grasp the basics, I have looked through the
    examples for Visual Basic and think that a program would run something like
    this:
    1. at the beginning, use LPM16_Calibrate to reset the board
    2. configure acquisition with DAQ_Config
    3. start acquisition with Lab_ISCAN_Start
    4. loop to check is acquisition done with Lab_ISCAN_Check
    5. once sampling done, write data out to file
    6. loop back up to 3 to get next lot of samples
    Unfortunately, a sample app using Access and VBA I created came back with
    an error telling me it could not find nidaq.dll (even though this is in the
    Windows system directory); probably it is not a good idea to try to do this
    in Access in the first place. I am going to have a go using Delphi, which
    I know a bit better.
    One thing I am unsure of is what the numbers will be coming out of
    Lab_ISCAN; the reference file seems to indicate they will be binary
    readings, not voltages, and I wonder how to correlate these with instrument
    measurements (the instrumentation people we going to set it up so that
    1mV=1ppm).
    Any help you can give to point us in the right direction would be
    appreciated.
    Sincerely, Marc Bell ([email protected])

    I am writing regarding DAQWare, data logging software, and the PC-LPM-16
    board, which a group of us a trying to come to grips with. This is rather
    lengthy, I'm afraid...
    We are a group of college students in a computer programmer/analyst
    program. We have a course that involves doing a project to go through the
    software development lifecycle (or as much of it as can be done in a term).
    For our project we teamed up with a group in the industrial hygiene
    program; they have a computer (standalone) with a PC-LPM-16 (PnP) DAQ board
    and the NI-DAQ software (all of this has been around for a few years, but
    has not been used much), and our goal was to capture the data they are
    measuring (atmospheric pollutants) to an Microsoft Access database.
    We are not familiar with DAQ systems, but were shown the software they had
    installed. This included DAQWare (appears to be version 2.0). We thought
    we could use DAQWare to log data to a text file, which we then would import
    into the Access database. We came up with VBA code to parse the ASCII text
    file created, but have run into one problem: DAQWare does not timestamp
    each sample, but only puts a single timestamp in the header information.
    Now we could extrapolate the time for each line based on the sample rate,
    except that sometimes it seems to put in 8 values per sample, sometimes 12
    values. For instance, in the sample of a text file below, the capture was
    run for 1 minute at a sample rate of 60, and there were 480 measurements in
    the file, or 8 lines of measurements per sample. (At a sample rate of 100,
    we got 800 measurements in the file etc.) This was two weeks ago. Today,
    we returned to capture more data, and DAQWare was logging 12 measurements
    per sample (so at a sample rate of 100, we ended up with 1200 lines of
    measurements). We do not know where this factor of 8 or 12 is coming from
    or how it got changed in the two weeks between captures. We would like to
    be able to have them just run DAQWare, for days on end if they wanted,
    capture the data to file, then use our code to parse the text file into the
    database, but if we cannot put timestamps on the readings, there seems no
    point.
    *** Example of a capture below... ***
    DAQWare File
    Version: 2.0
    Number of Lines in Header: 10
    Comment:
    Date: 10-18-1999 Time: 10:01:39
    Sample Rate: 60.0
    Scan Rate: 0.0
    File Format: 1
    Samples per Channel: 480.0
    Number of Channels: 5
    O3 SO2 NOX NO2 NO
    4 3 2 1 0
    1 1 1 1 1
    0.537 0.276 0.259 -0.017 0.015
    0.537 0.273 0.261 -0.022 0.012
    0.537 0.276 0.259 -0.037 0.012
    0.537 0.276 0.264 -0.007 0.015
    *** and so on... ***
    Regarding this attempt to use DAQWare:
    1. Can you tell us where this factor (8 or 12 or however many more readings
    than we would expect) means, where it is read from or set?
    2. Is there an updated version of DAQWare that we should download that
    would be better?
    3. Is there some other existing software that we can download to use to
    perform basic logging of multichannel analog input to a text file (with
    timestamp)?
    I realise that the software comes with tools (DLL functions) that one can
    use to create custom software to interface with the DAQ board, but in the
    limited amount of time we have we are not sure we can learn enough about
    these functions to write our own datalogging software.
    However, to see if I could grasp the basics, I have looked through the
    examples for Visual Basic and think that a program would run something like
    this:
    1. at the beginning, use LPM16_Calibrate to reset the board
    2. configure acquisition with DAQ_Config
    3. start acquisition with Lab_ISCAN_Start
    4. loop to check is acquisition done with Lab_ISCAN_Check
    5. once sampling done, write data out to file
    6. loop back up to 3 to get next lot of samples
    Unfortunately, a sample app using Access and VBA I created came back with
    an error telling me it could not find nidaq.dll (even though this is in the
    Windows system directory); probably it is not a good idea to try to do this
    in Access in the first place. I am going to have a go using Delphi, which
    I know a bit better.
    One thing I am unsure of is what the numbers will be coming out of
    Lab_ISCAN; the reference file seems to indicate they will be binary
    readings, not voltages, and I wonder how to correlate these with instrument
    measurements (the instrumentation people we going to set it up so that
    1mV=1ppm).
    Any help you can give to point us in the right direction would be
    appreciated.
    Sincerely, Marc Bell ([email protected])

  • Get data from a Data Base in MySQL

    Hi guys,
    I'm developing an app for my exam at school. In this app I need to query my Data Base to get my data and to create a table.
    The purpose of my app is to create a list of songs that a DJ has played during a concert and automatically create a table with the song titles, artist name and date of the concert. All of these information are already stored in the Data Base.
    I created an interface in Xcode where the user types in the DJ name and the date. I want to query the Data Base with these information and create a table that can be view directly on the iPhone. I think that I can send the text contained in the text field to a PHP page and then the PHP page does the query.
    Is it possible doing this? Can you help me with the code?
    If you need any explanation just ask me.
    Thank you very much!
    Angelo

    Thanks for the reply, I found the problem, i was returning no.sentDate in the form YYYY-MM-DD and method getTime doesn't like so it was returning null, so what I have done was cast(no.sentDate as datetime) and also store the difference of the dates as a long variable as I need the difference between the dates not the day of the month.
    My code now looks like this:
    conWorkPartyID = con.createStatement(ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_READ_ONLY);
    String sWorkOrderID = "select co.orderPartyid, no.workOrderListPartyid, wl.workOrdListDesc, cast(no.sentDate as datetime) as newDate from contractorOrders as co "+
    "left join newOrders as no on no.orderPartyid = co.orderPartyid "+
    "left join workOrderList as wl on wl.workOrderListPartyID = no.workOrderListPartyid "+
    "where co.flagSentToContractor = 0 and co.contractorPartyid =" + sCompany;
    cWorkPartyID = conWorkPartyID.executeQuery(sWorkOrderID);
    while(cWorkPartyID.next()){              
    Object x = cWorkPartyID.getObject("co.orderPartyid");
    Object y = cWorkPartyID.getObject("no.workOrderListPartyid");
    Object z = cWorkPartyID.getObject("wl.workOrdListDesc");
    Date dateTest = cWorkPartyID.getDate("newDate");
    Date Now = new Date();
    System.out.println("dateTest is: " + dateTest.getTime());
    long dif = ((Now.getTime() - dateTest.getTime())/86400000);// milliseconds to days
    System.out.println("Order PartyID that require your attention is : "+ x + " and workOrderPartyid: " + y +" and WorkOrderListDesc: "
    + z + " and the sent date is: "+ dateTest + "and the difference between the insertDate and the today is in days: "
    + dif);
    cWorkPartyID.close();
    Any other suggestions are welcome.
    Thanks for answering so soon.
    Good night!

Maybe you are looking for

  • Unable to install Photosmart B-209a on Win 8.1

    Trying to install full feature sw for existing b-209a on a new Lenovo Yoga 2 Pro running Win 8.1 64. Have tried the installer and it downloads the full sw.  After extracting nothing happens, no screens, no directions etc... Have also manually downloa

  • How do i know if my mac has a virus

    what can i use to check and see if i have a virus on my computer

  • Why is my password auto saved on my 4gs?

    After installing IOS 6 i no longer need to enter my password to update apps. How do I change it back so that I have to enter my ID/Password to update or install an app? Thanks.

  • Passing variables to a procedure inside a database trigger

    Hi,   I am new to oracle Forms . I am having a table in database . For that table i had written a database trigger which will fire after insert or update . I am using a procedure inside the Trigger . I want to pass arguments to the procedure which is

  • Dynpro_not_found ML81N

    the scenario: Once user exit project Z1(package is $TMP). It contains one enhancement assignment Z2. Z2 has some user's customized codes. Z2 is active and then saved in one change request and last it is sent to PRD and it can work. This sounds some s