| |
| |
| |
|
Page: 1 2 3 4 5 6 7 8 9 10 11
Comments:
<0> firewire : http://pastebin.com/529196 is output of : su mysql -c '/usr/libexec/mysqld --skip-grant' <1> Joran does your isp limit the ammount of memory mysql can use? <2> what reason could there be for not being able to drop a unique key? <0> nope, the vm has a small amount of physical mem, but I did try reducing those bits too, to the point where it was only requesting 2MB same output :( <3> telos: Strange. Not too many. What error do you see? <2> Xgc, errno 150 .. <4> it's snowing in madrid ! <5> what's the largest size a myisam table can be? <2> Xgc, aahh, found outu why.. it was cause tehre was a primary key that relied on it <2> Xgc, is it possible to rename keys at all? <1> Joran what kind of vm? <0> uml <0> hence the lack of control of kernel <1> hmm <6> sean_micken I believe that is limited by the filesystem, and how large a file the OS can handle? <0> both my distro (cAos) and AB's mysql binaries do the same, is the wierd thing.
<1> Joran why is key buffer size 0? <0> no idea, not in the config file. <1> that should be set bigger than 0 <0> firewire : just tried setting it to 2048 in the config file, it reports back as "8" <7> (ok, it's rebooted) Anyway, I think I have a corrupted database because our power went out last night and now mysql works ok, except when I try to access a particular database. (for example, doing show tables on that database) it crashes mysql with a segfault (gdb told me this). The other databases work alright though. I tried doing "myisamchk --silent --force */*.MYI" from the datadir and it fixed a few things, but it still doesnt <6> work <1> Joran why are you running mysql in uml? <0> firewire, because I have a whole vm on a well-connected backbone (telehouse) which I'm using as my webserver, dbserver, and mail backup mx <1> how big is the host server? <0> oh they're pretty big machines, don't know the exact spec <0> <quote>Typically they are either 1U rackmount servers with P4 Processors and 2GB ECC memory, or 2U machines with 2 Xeons and 4GB ECC Memory. All machines run RAID disks for data storage, with 1U machines having RAID1 arrays, and the 2U machines using either RAID 5 or 10 arrays. We use 3ware RAID cards, since these are the only ATA Raid cards that properly support hardware RAID in the linux kernel.</quote> <1> that's not very big <0> when they only share them about 10 people it's adequate <1> how much traffic do you plan on putting through this? <0> very little. <1> why aren't they providing you with a central mysql server? <0> any would be nice at the moment though ;-) <0> because that's not what they're about - they provide vms <1> are you just looking for hosting? <0> no... I have already bought a vm... I'm not looking for anything apart from getting mysql running at the moment. <1> you should probably contact their support <0> a vm gives me root access. <1> why do you need root? <1> to me it sounds like you paid for a pain in the *** <0> because I'm a distro maintainer and do various other stuff <0> (server programming being one of them ;-) ) <1> then you know more about vms than I do <0> it's just an odd kernel/mysql interaction I'm sure. <0> doesn't happen on my captive uml vm here. <1> kernel/pthreads/mysql interaction <0> pthreads... unlikely to be involved except on the kernel end, as they're distro provided and work elsewhere, but thanks for the tip. <8> Hi all, I could really use your help with an sql statement (using InnoDB). <8> I have three tables: <8> - questions( questionID, question ) <8> - answers( questionID, post_time, username, comment ) <8> - answer_visits( questionID, username, last_visit_time ) <8> I need the following information: <8> - the question text <8> - a count of the comments entered since the users last visit to this page <8> - a total count of all comments ***ociated to each question <8> My current statment (username is stored in session - using php): <8> SELECT q.questionID, question, COUNT(*) AS new_comments <8> FROM questions q, answers a, answer_visits av <8> WHERE a.questionID = q.questionID && a.questionID = av.questionID && q.questionID = av.questionID && <8> av.username = '" . $_SESSION[ 'username' ] . "' && av.last_visit_time < a.post_time GROUP BY q.questionID <8> I understand count will not return null values, but I'd like it to return 0 if no new comments are found. <8> Let me start off by saying I'm new to writing sql statements other than the typical select, insert, update statements. <9> Oh. That was a mistake. <8> I've tried a few thing using IFNULL and LEFT JOIN, but I didn't get the results I'm after. Someone at my work <8> suggested functions. Any suggestions? I'd like to do a similiar statement to get a total count of all comments <8> ***ociated to each question, not just new comments. <8> oh? <9> www.pastebin.com <9> im surprised an op hasnt kicked you for that <8> my mistake <8> I'll put it on there and resubmit <8> http://pastebin.com/529277 <8> never posted before.. <9> Good. :), your new. thats cool :P <1> we have ops? <9> there are no ops in here!?
<8> then I guess I'm safe :P <0> it looks to be a uml-specific thing actually... <1> Joran yeah.. <0> in my local uml it crashes too. :( <1> mysql doesn't typically crash on startup in a normal environment ;) <0> that shouldn't be. <0> yeah, I get that impression ;-) <0> but a uml environment is very un-different to a normal environment. <1> normally <0> in my uml it has a good key buffer size though <0> well my uml is actually my distro's normal kernel compiled for uml rather than x86 <9> edster: you working in php? <8> punkstar: yes <3> edster: I suspect you'll need to use LEFT JOIN appropriately to obtain those 0 count cases. <9> If you sort the SQL out, I can tell you everything you need on the PHP side.. <3> edster: Inner joins won't return the missing data. <9> im not too hot with adv. sql <8> Xgc: since my where clause has av.timestamp < a.timestamp would a left join return a 0 <0> firewire... yup, making sure the mem requirements are met with physical ram, I still get sig11s from mysql_install_db <8> I tried to use a left join...not sure if I had the sql correct <3> edster: You'd need to use the correct JOIN criteria in an ON clause, not the WHERE clause. <1> get me a stack trace <3> edster: ... for the OUTER JOINs, that is. <8> punkstar: I looked at possible alternatives in php using mysql_fetch_***oc, and a few if statments if that makes sense <8> Xgc: I'm new to joins...could you give me an example? tks <9> Yeah, I'll sort that out for you now.. hang on. <0> firewire, as in strace mysql_install_db? <3> edster: MySQL doesn't support some of the more complex data mining constructs at this point. So obtaining aggregates over different ranges of dates will probably require some additional work. <1> no <9> edster: Never send a $_SESSION['var'] into a statement without addslashes() or something to prevent sql injections ;) <1> gdb mysqld <8> punkstar: well I'd only have to worry about injections on the intial login right? <9> thats true. <8> xgc: a oracle coworker told me I'd probably have to use functions <1> never trust an oracle coworker ;) <9> edster: where is your question_id input@ <9> ? <9> or are you just generally searching the database for all of them? <8> punkstar: for all of them <3> edster: In Oracle, there are functions that operated over windows within groups that provide very powerful access mechanisms. MySQL doesn't support that yet. <8> its going to list all questions with number of comments (bolding if new comments are present) <8> Xgc: would "count()" be considered a function? <9> right, ill get it returned in an array <3> edster: Yes. <8> Xgc: so you can't write your own functions correct? <3> edster: You can. <8> Xgc: would a possible solution be to write my own function in this case? <3> edster: Lookup "oracle analytical functions" and you'll see what I mean. <3> edster: Are you using 5.0? <3> edster: or are you thinking of writing a function using the C API or similar? <3> edster: I'm not saying you can't construct a query for your problem. It's just tough to do without more complex constructs. <8> Xgc: sorry, wife needed me to open a jar.... I'd have to look which version the host company is using <10> Xgc: Were you able to look at my pastebin post from a few days ago? <0> firewire : erm, I ain't great with gdb... http://pastebin.com/529317 <8> Xgc: I'm not familiar with the C API... I think I'd rather construct a query <8> but I'll do w/e it takes if for nothing else to learn from <3> DShadow: Probably, but I don't remember the specific post/issue. <10> Xgc: http://hashmysql.org/1366 <9> edster: nearly finished my good deed for the day =D <8> much appreciation <9> edster: http://pastebin.com/529333 <9> i wonder if that'll work <9> you know php right? <9> so you can debug? <8> yea <9> good man. <3> DShadow: I don't think I've seen this. What was the goal? <3> Sorry. I see expected. but what does that represent. <8> Xgc: I'd still like to know what kind of sql statement would fulfill everything I need... you mentioned correct JOIN criteria <8> punkstar: I'll give it a shot <10> it's the sum of _AAV.org per unique article/source <10> s/org/ord/ <10> so that, when additional rows get created as a result of the inner join A0, the extra rows don't affect the result. <3> I've saved this. I have to run out for a little bit.
Return to
#mysql or Go to some related
logs:
no audio in totem-xine ubuntu avi #perl #mysql #gentoo #python how to check whether datas in two tables are same or different using MYSQL query ubuntu server install problem qmail-remote yahoo.com.tw sounddex #php
|
|