@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info


Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14



Comments:

<enginuitor_> AaronCampbell: I've thought about it... I think I had a pretty good reason against using a file, but I forgot it :-D
<enginuitor_> Actually, my original reason was that all the scripts on my former webhost's servers ran as the same user...
<TheCool> Does anyone know of any good case/uml database design tools? Or am I stuck with pencil and paper?
<enginuitor_> ...so to make a file writable by my script would make it writable by every idiot on the server
<enygma> paper!
<solus> i'm trying to add a foreign key constraint to a table but I get funny error messages
<Darien> like ha-ha funny?
<solus> like this "alter table articles add constraint foreign key (author) references users (id) "
<TheCool> mysql_error: You can't do that, you are a moron
<solus> Darien: no like hrmm? funny
<Darien> like 'things that make you go hmmm
<solus> "Can't create table './guanabara/#sql-6df9_1b6e.frm' (errno: 150) "
<Darien> !perror 150
<SQL> MySQL error: 150 = Foreign key constraint is incorrectly formed
<Darien> !
<Darien> re-evaluate your foreign key
<Darien> !m solus foreign keys
<SQL> solus: (Foreign Keys) : http://dev.mysql.com/doc/mysql/en/ANSI_diff_Foreign_Keys.html
<Darien> solus: you need to add a symbol name after 'constraint'
<Darien> !m solus foreign key constraints
<SQL> solus: (FOREIGN KEY Constraints) : http://dev.mysql.com/doc/mysql/en/InnoDB_foreign_key_constraints.html
<Darien> solus: or take out 'constraint' entirely
<solus> ah
<Darien> e.g. ALTER TABLE articles ADD FOREIGN KEY (`author`) REFERENCES `users` (`id`)
<AaronCampbell> I'm working with a table that is using 2 Columns in the primary key...The first is version (3, or 4), and the second is `order`(auto_inc). I want to swap the order value for 2 objects, so if I want to swap order 1&2 for version 4, I would normally do this: UPDATE `todo` SET `order`=(2-`order`)+1 WHERE `version`='4' && `order` in (2,1); it seems that this doesn't work if `order` is a primary key...I get: 'Duplicate entry '4-2' for key 1'
<AaronCampbell> is there any way to swap them? Or swap the data in them (basically just need to swap a 3rd column...`todo`) without having key constraint problems?
<AaronCampbell> or rather duplicate key problems (that's what I get for reading above comments while I type)
<solus> Darien: that query gives the same error
<Darien> well I didn't say it would work
<sjrussel> AaronCampbell - you need to change to a placeholder value.. primary keys are, by definition, unique
<sjrussel> for example, 0
<sjrussel> but you'll have to lock the table first
<Darien> solus: does the 'articles' table have a column called 'author' which is the exact same format as the 'id' column in 'users' ?
<solus> yes
<Darien> can you pastebin the SHOW CREATE TABLE foo; results of each table?
<AaronCampbell> sjrussel: so it needs a few queries rather than one?
<AaronCampbell> Something to lock the table, then to set one number to 0, then to set the second number to the first, then to set 0 to the second number? 4 queries?
<ikiru> i tried seraching forums and wikis, but i'm having a problem with crashing in both query browser and administrator on mac 10.4 is this the case for everyone or am i just lucky?
<Julian|Work> !m reserved words
<SQL> reserved: (Treatment of Reserved Words in MySQL) : http://dev.mysql.com/doc/mysql/en/Reserved_words.html
<killfill> !m reserved words
<SQL> reserved: (Treatment of Reserved Words in MySQL) : http://dev.mysql.com/doc/mysql/en/Reserved_words.html
<solus> Darien: i just discovered something
<Darien> oh yeah?
<Darien> does it involve aliens?
<solus> no, small dinosaurs, actually
<Darien> awesome
<Darien> do tell
<solus> the tables were different types, users was myisam
<solus> and then the little dinosaurs came and chewed my toes for being stupid
<sjrussel> AaronCampbell, I think that would work
<Darien> nice
<Daveman> Hi Darien
<AaronCampbell> wow...maybe I'll have to do away with the key...that seems like a waste.
<sjrussel> why are you switching versions?
<sjrussel> that seems od
<sjrussel> but yeah, usually, primary keys are fairly static
<AaronCampbell> Maybe I can remove the primary key, and instead during inserts (SELECT MAX(`order`) FROM `todo`)+1
<AaronCampbell> hmmm, actually...I can't SELECT from the same table I INSERT to in 4.1
<killfill> hello.
<AaronCampbell> and I'm not changing versions...It's like changing priority of a 'todo'
<killfill> im trying to make this work:
<killfill> http://gwireless.sourceforge.net/GoogleMap/InsertWayPoint.php?name=Mine&id=0
<killfill> Error on UPDATE gps set name="Mine" where id="0" : Query was empty
<killfill> why do i get that?
<sjrussel> I think you're trying to do something simple in the most bizzarly complicated way
<killfill> you can see the code on InsertWayPoint.phps ...
<sjrussel> I recommend going back to the whiteboard
<AaronCampbell> sjrussel: I suppose. I was mostly trying to add functionality (the ability to adjust todo's up and down the priority list) to a system that was in place
<sjrussel> priority sounds like something that shouldn't be in a unique key
<sjrussel> generally, multiple things can have the same priority
<BusyBeaver> CAST(FLOOR(CAST(BT.ValutaDebit AS DECIMAL(12, 5))) AS DATETIME)))
<BusyBeaver> thats how it is done
<BusyBeaver> and now
<BusyBeaver> **** ya
<BusyBeaver> mother****ers
<sjrussel> heh
<BusyBeaver> mota ****ers
<BusyBeaver> u are such disabled beach bastard that stick its little ********
<BusyBeaver> **** in every slut cunt even in your niggerbitch of a motherwhore. u are
<BusyBeaver> such damn grizzly mota****ers that put your damn ugly face in a goats
<BusyBeaver> arsehole every day and let your poor dog give you a blowjob all day and
<BusyBeaver> night , you are such cheap wallmart morons, you cum in the cellar all the
<BusyBeaver> time. bah.
<sjrussel> that's another bizzarely complicated way to do something simple, BusyBeaver
<zeitoun> killfill: because it is empty... double check your execute() function
<AaronCampbell> sjrussel: right now, we just have an unordered list. I was simply changing it to an ordered list, and allowing us to adjust up/down. I didn't really think about letting 2 things have the same priority
<sjrussel> the 4 query thing would work
<sjrussel> why not just do that?
<killfill> zeitoun: yah, got it.. fool error.. :-p sorry for the flood
<Elshar> I think that's quite possibly the funniest thing I've read all day
<ries_> what is tinytext and when is it used, eg what can tinytext do what varchar can't ?
<netbrain> select if((select ps_id from prosyk where profil_id = 2 and syk_id = 2) is not null,ps_id,null) as id;
<netbrain> how can i get to use id in a replace function?
<netbrain> replace query
<will> Therion, where are you?
<netbrain> how can i bind an subquery to a variable?
<netbrain> or .. something?
<litheum> "or .. something"
<litheum> that sounds about right
<netbrain> ...
<zeitoun> netbrain, let me try to translate what litheum says: rephrase your un-understandable question.
<litheum> unintelligible
<zeitoun> ty :)
<litheum> is a slightly more frequently used and much less awkward word
<Elshar> Yea, and un-understandable has that double-negative that confusles people, like irregardless
<StoneCypher> or, um
<StoneCypher> confusing
<StoneCypher> huhu
<StoneCypher> unintelligable doesn't mean "hard to understand"
<StoneCypher> unintelligable means "cannot make out what is being said"
<zeitoun> imcompréhensible
<StoneCypher> a bad radio transmission is unintelligable
<netbrain> i have a table with a primary key (ps_id), and 2x seconday keys (profil_id,syk_id) im trying to make an optimized sql query to replace profil_id and syk_id with updated values, or create a new row if not exists
<StoneCypher> a bad question is just confusing
<Elshar> Oh holy, now you want to get into the technical specifics :P
<Therion> will: In Tennessee? :)
<Elshar> Should we all start breaking out the dictionary and 'correcting' each other? :P
<StoneCypher> yes
<StoneCypher> erudition is important
<netbrain> select (select ps_id from prosyk where profil_id = 2 and syk_id = 2) as a, if (a is not null,a,null);
<Elshar> No, the correct answer would be 'affirmative'
<StoneCypher> no
<netbrain> so i tried someting like that
<StoneCypher> the correct answer is "yes"
<Elshar> Yes, it would be
<StoneCypher> affirmative means "guaranteed to be so"
<StoneCypher> it is affirmed that someone who has RSVPed will be there
<StoneCypher> it is affirmative that a bank will release escrow to the payant
<Elshar> ***erting that something is true or correct, as with the answer yes: an affirmative reply.
<StoneCypher> the answer to a yes or no question, however, is yes or no
<Elshar> First definition of the word 'affirmative'
<StoneCypher> huhu.
<Elshar> :)
<StoneCypher> web dictionaries are not known for their control of subtlety.
<Elshar> Apparently neither are you :P
<StoneCypher> Elshar: One might consider the case of the pot calling the kettle black. Follow through the etymology of "to affirm" and you're in for a dry shock.
<StoneCypher> By the way, your grammar there is hilariously self referential.
<Elshar> Oooh, I feel bad now. Gonna cry. Just so you know, the first comment was this thing people with humour call a joke. :P
<Therion> StoneCypher: "a bad question is just confusing"
<Therion> StoneCypher: How, pray tell, can a question be "bad"?
<Elshar> Apparently if he disagrees with it :P
<Therion> StoneCypher: Does it stay out all night with its friends, breaking laws and rebelling against authority figures?
<Therion> Since that goes back to the beginning of this conversation, it's a good reason to drop the thing now. ;)
<StoneCypher> Therion: shall I answer or drop it?
<zeitoun> wow, I didn't know a late night approximative translation of a word in my brain could lead to so much discussion :)
<Therion> StoneCypher: Whichever you like, I do not care. ;)
<StoneCypher> I'll answer then drop it.
<Therion> I am aware of poor questions or incomprehensible questions and so forth, but not "bad" questions.
<StoneCypher> The root of the word "bad" (baeddel / baedling) in Old High English is "inferior or defective."
<Therion> Sure, and family/famulus/slave


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #mysql
or
Go to some related logs:

#web
qingy freezes
#linux
#lisp
#asm
pipe into tar
#debian
crystal snd-cd4236
How do you turn cookies on
compix xgl gentoo



Home  |  disclaimer  |  contact  |  submit quotes