| |
| |
| |
|
Page: 1 2 3 4
Comments:
<0> ? <1> when doing division in sql, how do i get the decimal value? <1> it's rounding off <2> don't use an int? <2> id guess convert to float like any other language <1> multiplying it by 1.0 worked <1> ok <1> there has to be an easier way to do this <1> Table A, Table B, Table C. Table B is common to C and A, I need all possible values from C and A and the matching B value <1> simple joins wont work <1> i can either get all of Table A or Table C but not both <1> is this where full outer joins work? <1> maybe a cross join <3> hi, mssql 2k - how many columns in a table is too many. Most of the answers in each field are a number... <3> i always wonder if im going over a limit <4> when you think 'wtf', its too many
<3> haha <3> im at 17 <3> mostly bit fields <3> maybe im there right now! <0> settrip : how many of the bit fields need to be used in where clauses or joins? <5> Anyone know where I can get a copy of Query Analyzer I thought it was a free download at M$'s website <0> Kranfer : QA is part of the Enterprise Manager suite, which is part of ms-sql2000 <0> Kranfer : it is included with the eval of ms-sql2000 - the engine is limited to 180 days, but the client tools (like EM and QA) are not so limited <0> brb <6> hi. in MSSQL, having a table with a 'number_dialed' column, how do I do a max(count) query to find out the most dialed number? thank you <7> g-tox, select number_dialed, count(otherfield) from mytable group by number_dialed; <6> yeah, but i just want to show the max line <6> i messed up with having and max, but i can't seem to make a clause 'having count(dialed) = max(count(dialed))' <6> are you seeing what i'm after? <8> Gambit- : not count(otherfield), you cunt. it's always count(*) unless counting a distinct col <8> g-tox : what do you mean 'the max line'? <8> g-tox : which rdbms is this for? <6> i want the output to be just one tuple <8> g-tox : which rdbms is this for? <6> its for mssql 2000 <8> does the table in question have a primary key? <6> yep <9> astounding! <8> evening rmah <6> both 'number_dialed' and 'code' are the primary key <8> so you have a composite primary key? <8> what is 'code'? <6> is a int code for the local hardware phone <6> like phone 1 called 0987654 <8> and 'phone 1' will only ever dial a number once? <6> nope <6> phone 1 can dial many phone numbers <6> so both code and number are primary keys <6> like 0987654 dialed by phone 1, 4355675 dialed by phone 1, 327674 dialed by phone 2 <6> etc <9> haha <8> er, ms-sql does not support two primary keys to a table - which rdbms is this really for? <6> my query is: which was the most dialed number <6> no... primary key is made of two attributes <6> no two primary keys <8> so it *is* a composite primary key <6> yes <8> so why did you say 'no'? <6> i'm still learning... frst approach to databases <8> ok, so any given 'code' will only ever dial a number once? <6> my table is like this: <6> code | number_dialed | hour <6> 1 | 12345 | 13:34 <8> ok, so any given 'code' will only ever dial a number once? <9> select t.phone, tmp.ncalls from t join (select phone, count(*) as ncalls from t group by phone) as tmp on t.phone = tmp.phone order by tmp.ncalls DESC; <9> do that <9> limit by 1 or use top 1 or whatever to just grab the first row <9> phone = code <6> every code can dial as many numbers as it want <9> g-tox, I just gave you the query, now try it <6> gonna try it <8> g-tox : then your primary key is not a primary key, is it can contain duplicates <9> YuppieScm: don't bother him with trivialities like technical correctness :-) <10> if i get a telemarketing call from this app i'm suing #sql <9> he's a telemarketer?
<9> **** me <10> what else is it for? <9> maybe it's homework <10> haha <9> then I could ban his ***! <8> nah - i used to do **** like this when i worked for qwest <10> ban either way <8> call-centre traffic logging <9> wouldn't telcos hire dba's and programmers to do call accounting ****? <8> yah, they do... well, they hired me... <8> yeah, you're right, it must be homework <9> heh <9> YOU'RE the one who first said "homework" <8> true... maybe i should kb him <8> thinking about it, not sure what kind of call centre needs to track which number they called the most <10> or from which phone number <9> maybe they're trying to find employees to fire by looking at phone abusers? <9> it's as good a reason as any <8> you'd think they would only call any number once per scam... er, unbeatable product offering <10> why don't we ask him <9> that would make too much sense. boo on you Mixx <10> =/ <8> g-tox " you still here? <6> yep <10> sooooooo whatcha makin? <6> result is good, but i still can't get just the first row <10> sooooooo whatcha makin? <6> got it <10> [20:37:04] <+YuppieScm> g-tox : which rdbms is this for? <10> [20:37:38] <6> i want the output to be just one tuple <10> [20:37:43] <+YuppieScm> g-tox : which rdbms is this for? <10> his guy doesn't listen either <10> ^t <8> http://video.google.com/videoplay?docid=6514168251893889573&q=ariel+atom+top+gear <8> oops <8> sorry... meant for another window... however, wirth a watch <9> hahaha... this video is funny <8> i so want one... sent the link to a mate, and he offered to go halves on buying one... <8> 0-60 in 2 and a bit seconds, and totally street legal <9> now, that's pickup <9> 2.9 sec <9> I just hit that section :-) <9> haha <9> that thing looks fun <8> i keep watching it because the guy is normally so disparaging about every car he drives... until now... <8> have you got to the 'stig' bit yet? <9> just got there <9> who's this stig? <8> undisclosed professional racing driver <8> i suspect that for this series it was damon hill - <8> but i could be wrong <9> is this a regular BBC show? <8> yah... 'top gear' <8> format has changed over the years... have been presented by that big bloke for for last several <8> actually, i think he's been doing it for 10 years or so... damn that makes me feel old <11> i want one of those cars. <8> indeed <9> I'd feel silly driving that to the grocery store <8> fwiw, it's one of the available cars in PGR3 <11> it's just a toy.. you wouldn't drive it anywhere unless you were out for fun <8> gripe : ey - grocery shopping can be fun <10> sweet vid YuppieScm <11> especially when you can compress the driving time from 15 mins to 3 <8> if i had one, i'd drive the ****er everywhere unless it was raining <12> lol <12> holy **** atom <8> up and atom! <9> the big bloke drives a Mercedes SL55 AMG <9> I want a Mercedes SL600 even more now <8> jeremy clarkson <9> *his* car is a Mercedes SL55 AMG <8> he drives many things <9> he sold his Ferrari 355 for it
Return to
#sql or Go to some related
logs:
natural gas etf #stocks #beginner #ubuntu gentoo h00lyshit #beginner #wtf Kirupa_3D_05_PullThroughSpace Blind Carbon Copy-Explorer addictz xti
|
|