Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: hessodreamy
  • Order by date
  1. hessodreamy

    ownership of code

    Yeah, that's some pretty good advice there. I discussed it with my MD today, on the assumption that UK terms were similar to US, and he wanted to steer clear of any grey 'joint ownership' area to the point that he forbid any in/out of hours project. He's liable to knee-jerk like that... I did...
  2. hessodreamy

    ownership of code

    ok. That seems fairly common sense. Anybody offer anything different from UK law?
  3. hessodreamy

    ownership of code

    From a general industry point of view, who owns code we write while we are employed by a company? Say if we write code in and out of work time? Is there any agreement on this? There's a couple of neat things I want to work on. Basically it'll be of use to the company, but I want to be free to...
  4. hessodreamy

    Showing first 10 results for each day

    yes, but the problem I was finding was in joining the orders table to itself on the date, making a lot of work becuase it had to extract a date from the timestamp (twice). It seems that the problem isn't solved if I'm using timestamp and still have to convert in order to create the join. Or...
  5. hessodreamy

    Showing first 10 results for each day

    Yes I think I've got my head around it now. I think the main reason it was dying was that i was doing from_unixtime for the timestamp on every row. I added a `date` field on which to join and it worked fine. From what i've read it seems that, in 4.1, there is not a way to set a `date` field...
  6. hessodreamy

    Showing first 10 results for each day

    ahhhhhh.... i think.
  7. hessodreamy

    Showing first 10 results for each day

    I have indexes on orderID, and a unix timestamp field (I don't have a 'date' field). So I used t1.uts>unix_timestamp('2006-02-01') in the where statement. I'm not sure why you'd include the orderTotal in the join condition. Maybe I've explained the problem/definition badly?
  8. hessodreamy

    Showing first 10 results for each day

    That seemed to just kill mysql. Do you think you could explain how it works, so that I can optimise it? I can't really see what's happending.
  9. hessodreamy

    Showing first 10 results for each day

    doesn't work. The group by day just limits the results to 1 entry per day, and shows details of the first order from the day. I can get totals for the day, but what I really want is the top 10 orders.
  10. hessodreamy

    Show week start date

    for example: SELECT from_unixtime(uts,'%u') as week_number, count(*) as orders from ordersTable WHERE from_unixtime(uts,'%Y')=2006 GROUP BY from_unixtime(uts,'%u') Giving +-------------+--------+ | week_number | orders | +-------------+--------+ | 18 | 20 |...
  11. hessodreamy

    Show week start date

    I pull out a lot of reports for weekly figures, but is there any way to get the start date for a particulr week number?
  12. hessodreamy

    Showing first 10 results for each day

    I feel I should be able to work this out, but I'm drawing a blank. How would I retrieve, for example, the top 10 orders for each day for a period, where I order by orderTotal? I can't seem to find any way to limit the results for each day, rather than the results as a whole. Any ideas?
  13. hessodreamy

    Record Lock

    Anyone?
  14. hessodreamy

    Batch file for Backup

    I backup my DB on linux using a bash script. Was a pain in the rear as I wanted to back up each table into a separate file, so i've got 30 different statements running. Maybe there was a better way, but i'm not that clever. here's the script. If you are using windows then you'd need to change...
  15. hessodreamy

    Record Lock

    I can't seem to find an answer in the literature, but is it possible in 4.1 to place a lock on a particular record? Say, to prevent changes to the record while being viewed. There's plenty on table locks but no record locks. Are these not supported?
  16. hessodreamy

    help with GROUP BY

    Thanks for that. I agree it was a great answer. Had some initial trouble with the former approach in that the subquery returned more than 1 row. Turned out I had some duplicate rows. A group by sorted that out. When I ran each of them the first was much, much faster, taking fraction of a...
  17. hessodreamy

    sleep processes

    by the way i'm connecting from php using mysql_connect. I think that's non-persistent!
  18. hessodreamy

    sleep processes

    Recently I've noticed the mysql server going very slow at times. At such times i've run show full processlist and there's been one or two processes with a status sleep and time being anything up to about 40 seconds. What are theses proceses? Are they read/write processes waiting for their...
  19. hessodreamy

    help with GROUP BY

    I have a table of customer problems, and another table of cummunications relating to the problem. I'm trying to pull out for each problem: details of the problem, the most recent comversation, and the timestamp of the oldest conversation. I've got the latest conversation like so: select *...
  20. hessodreamy

    using OR in join condition

    I Have this query which just takes too long and kills the server. I have 2 left joins and want to do an inner join matching values in either of the left joins. It seems to be the use of an OR in this inner join which is the bottleneck. select * from categories c INNER JOIN cat_subCat csc...

Part and Inventory Search

Back
Top