Jump to content

kathygriffin

Members
  • Posts

    33
  • Joined

  • Last visited

Posts posted by kathygriffin

  1. Actually I did that wrong  It will look like this.

     

     

    <?xml version="1.0" encoding="UTF-8"?>


    <add>


    <doc><field name="id">something</field>
    <field name="other1">something2</field>
    <field name="other3">something3</field>
    <field name="other4">something4</field>
    <field name="other5">something5</field>
    <field name="other6">something6</field>
    <field name="other7"><![CDATA[something7]]></field>
    <field name="other8"><![CDATA[something8]]></field>
    <field name="other9"><![CDATA[something9.jpg]]></field>
    <field name="other10a"><![CDATA[<p></p>]]></field>
    <field name="other10">something10</field>
    <field name="other11">something11</field>
    <field name="other12">something12</field>
    <field name="other13">something13</field>
    <field name="other14">something14</field>
    <field name="other16">something15</field>
    <field name="other16">something16</field>
    <field name="other18">something17</field>
    <field name="other18">something18</field>
    <field name="other18">something19</field></doc>

    </add>

  2. Thank you for letting me. Ok Here is what I am dealing with. Only its about 200,000 items.

    <?xml version="1.0" encoding="UTF-8"?>


    <add>


    <doc><field name="id">something</field>
    <field name="other1">something2</field>
    <field name="other3">something3</field>
    <field name="other4">something4</field>
    <field name="other5">something5</field>
    <field name="other6">something6</field>
    <field name="other7"><![CDATA[something7]]></field>
    <field name="other8"><![CDATA[something8]]></field>
    <field name="other9"><![CDATA[something9.jpg]]></field>
    <field name="other10a"><![CDATA[<p></p>]]></field>
    <field name="other10">something10</field>
    <field name="other11">something11</field>
    <field name="other12">something12</field>
    <field name="other13">something13</field>
    <field name="other14">something14</field>
    <field name="other15">something15</field>
    <field name="other16">something16</field>
    <field name="other17">something17</field>
    <field name="other18">something18</field>
    <field name="other19">something19</field></doc>

    </add>

  3. ok so I had this database of 20,000 items. My part numbers I had to add a gg in front of all them then add them into the same database. So I had the old part numbers that looked like this 33344 and new part numbers that looked like this gg33344. Now for some reason it is only totaling up the old numbers and not the new numbers. The same exact query with a recently new database was built and seems to have no issue with the letters being in front. So my guess is that if you insert new items into database you have to readd the event? Anyone have any ideas or input?

     

    example of new database after query ran for total  my query is something like this total = (stock ny+ stock nc )

     

    part number  - stock ny - stock nc - total

    33344               5              6            11

    gg33344           5              6            0

    34344               5              6            11

    gg34344           5              6            0

    36344               5              6            11

    gg36344           5              6           0

     

     

    thanks

  4. cannot really help you without specific information. the general answer to programming questions is yes, you can do just about anything you want if you write the code that does it.

     

    is this xml data intended to be directly imported into a database (it must be in a specific format, as shown at the link to the documentation that i posted above.)

     

     

    Sorry.. Heres what I am working with

     

    USE things; LOAD XML LOCAL INFILE 'C:/Users/computer/Documents/items.xml' INTO TABLE everything ROWS IDENTIFIED BY '<doc>'; /g

     

    Now in the xml file I have more than one field name that is named the same thing. For example I have 3 stuff2 and 4 stuff3s

     

    In my mysql table with the code I am using about it inserts only the first field of stuff2 and first field of stuff3s. So I setup stuff2 then stuff2a  then stuff2b how would I get it setup to into the mysql column names that do match.

  5. i recommend reading the mysql documentation for what you are doing - http://dev.mysql.com/doc/refman/5.5/en/load-xml.html

     

    based on what i know, you will need to use - ROWS IDENTIFIED BY '<doc>'

     

    I did look at what you sent you but I am a bit confused here so if I have it right I would have to use it like this >>>

     

    USE stuffdb; LOAD XML LOCAL INFILE 'C:/Users/computeruser/Desktop/stuff.xml' INTO TABLE stuff_load (stuff1,stuff2, stuff3, stuff4, stuff5, stuff6, stuff7, stuff8, stuff9) ROWS IDENTIFIED BY '<doc>' /g

     

     

    Correct?

  6. a) how large is the file, how many rows of data does it contain?

     

    b) does the file contain properly formatted <row></row> elements that mysql would be able to use by default to find the data?

     

     

    A. Some files are 100 mb some others are about 200 mb. Some part numbers contains more data then others.

    B. I'm not seeing row anywhere. I have provided a example below.

     

    Thanks

    <doc><field name="id">22439789</field><field name="prtnmbr">22439789</field><field name="subprtnmbr">22439930</field><field name="mannmbr">00955tr</field><field name="listprc">370.95</field><field name="updatedate">2014-01-01T01:56:03Z</field><field name="iname"><![CDATA[TIRE 190/55 ZR17 PILOT ROAD3 B]]></field><field name="vname"><![CDATA[MICHELIN]]></field><field name="atrribute"><![CDATA[BIAS / RADIAL, RADIAL]]></field><field name="atrributevalueid">11</field><field name="atrribute"><![CDATA[SPEED RATING, (W)-&GT;168 MPH]]></field><field name="atrributevalueid">118</field><field name="atrribute"><![CDATA[LOAD INDEX, 75-853 LBS]]></field><field name="atrributevalueid">154</field><field name="producttype"><![CDATA[TIRES]]></field><field name="atrribute"><![CDATA[FADE, REAR]]></field><field name="atrributevalueid">464</field><field name="atrribute"><![CDATA[TUBE TYPE, TUBELESS]]></field><field name="atrributevalueid">556</field><field name="atrribute"><![CDATA[TIRE INNER DIAMETER, 17 INCH]]></field><field name="atrributevalueid">561</field><field name="atrribute"><![CDATA[WIDTH, 190 MM]]></field><field name="atrributevalueid">588</field><field name="atrribute"><![CDATA[ASPECT RATIO, 55]]></field><field name="atrributevalueid">593</field><field name="atrribute"><![CDATA[PURPOSE, STREET]]></field><field name="atrributevalueid">608</field><field name="atrribute"><![CDATA[TIRE LINE, PILOT ROAD]]></field><field name="atrributevalueid">677</field><field name="atrribute"><![CDATA[TIRE BRAND, MICHELIN]]></field><field name="atrributevalueid">689</field><field name="atrribute"><![CDATA[VERSION, LOADED/TWO-UP]]></field><field name="atrributevalueid">692</field></doc>
    
  7. Ok just bare with me on this question. In phpmyadmin Is there anyway to change the last_execution time to my eastern standard time? Instead of showing the UTC time? Can I change the time zone in system to say like eastern or what would it be UTC - 5 instead of saying system? Is something like that even possible?

     

    Thank you

  8. There is nothing for you to fix. It is working as expected. I provided a link to the "bug" report and an excerpt of the response to that bug - which stated they were updating the documentation. Did you even take 5 minutes to look up that documentation? I'm not trying to be an ass, but the information I provided should have made it clear that this had nothing to do with a mis-configured setting. If you had looked up the update to the documentation that was referenced in the earlier post you would see why it is correct behavior.

     

     

     

     

    So, all events are scheduled based upon UTC time. After reading the above, it makes perfect sense, but it may not be blatantly obvious. You first need to understand timestamps. A timestamp represents the number of seconds since the Unix epoch (Jan 1, 1970 midnight). It is the number of seconds in UTC time. So, a particular timestamp for my would represent March 3rd, 2014 10:45 AM. But, that exact same timestamp would represent March 3rd, 2014 11:45 AM to you because you are 1 hour ahead of me. A timestamp is different than a datetime record in the database. A datetime would be used for something like recoding business hours. If a chain of stores exists in multiple timezones, you might store a single start and end times for hours of operations on a particular day. On that day, all the stores will open at 10:00AM (without any respect to the timezone).

     

    So, with that in mind, the events in MySQL are scheduled using a timestamp. However, it is always based on UTC rather than the servers local timezone. And, that makes sense. Let's say you have an event that should run every 30 minutes and the server is located in the Eastern timezone (UTC-5). So, every 30 minutes that event is executed. Then after an event is executed at 10:00AM the next execution would be at 10:30AM. Then assume at 10:15 AM the server's local timezone is change to Pacific time (UTC - 8 ). The server's local time would be 7:15AM. If it used its local time for the events it would think it did not need to run the event for another 3 hours and 15 minutes.

     

    I really don't understand why this is such an issue. You want the event to run every minute, so what is the fixation on what timezone the events are displayed in. As I said before, if you don't like it, build your own page to display the event details and changing the displayed time to your liking.

     

     

    No your not being a ass. I think we are just on two separate pages. I did forget to  mention I was using a different version because I did upgrade to a higher version. I will double check everything and post back.

     

    Thanks for all your help so far.

  9. I use phpmyadmin and go to mysql > events then browser and in column last_executed. I am using lamp centos 6.4 when I run etc/sysconfig/clock it shows America/New_York which would be eastern time. When I put in date as the command its showing the correct.. Is there maybe something else for mysql somwhere else?

     

     

    As for my timezone it is showing system when I run SELECT @ @ Global.time_zone, @ @ session;

     

    Thanks

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.