#mysql
22 October 2007
Total 24 pages. You are browsing page 3/24.
First :: Prev :: [1] [2] [3] [4] [5] [...] :: Next :: Last
05:26 <****> damn, no one I know is here
05:26 <****> oh wait
05:26 <****> [RainMkr] is here
05:27 <****> maybe
05:28 <****> do rules exist in mysql?
05:29 <****> define 'rules'
05:29 <****> like rule in ms sql server
05:30 <****> create rule [name] as
05:30 <****> it's better to tell us what you want, rather than to ask for something in a product we may never have used
05:30 <****> i know
05:30 <****> but does rule exist in mysql
05:30 <****> what is a 'rule' ?
05:30 <****> rule are objects that validate some fields
05:31 <****> like a constraint?
05:31 <****> so so
05:31 <****> Sounds like a check constraint or trigger.
05:32 <****> well rule are more like trigger
05:32 <****> they execute automatic
05:33 <****> Yes. They do.
05:33 <****> well when you create a rule you bind it to a table
05:33 <****> same with triggers
05:33 <****> fitoria: No difference so far.
05:35 <****> look here http://manuals.sybase.com/onlinebooks/group-as/asg1250e/sqlug/@Generic__BookTextView/37961;pt=37302/*
05:37 <****> chadmaynard: are you still around?
05:38 <****> That was a silly question. I should've just asked again.
05:38 <****> is there an irc channel for mssql (2000) i am having problems with my sql query...
05:38 <****> phpcurious: try #sql
05:39 * chadmaynard has been blinked
05:39 <****> AzMoo[w]: how do you perform a cube sql ? should the columns of the cube data be static?
05:39 <****> I'm having a problem with a mysql function I've written. When I use it in a query that I think it should work on, it fails. http://www.pastebin.ca/742114 <-- info about the problem.
05:40 <****> chadmaynard: can I take that as a yes?
05:40 <****> phpcurious: I don't know.
05:40 <****> phpcurious: lots of group by cube examples on google
05:41 <****> AzMoo[w]: so you don't want to self join?
05:41 <****> fitoria: MySQL doesn't have that (it looks like a T-SQL extension), but you can simulate the same thing with triggers
05:42 <****> damn.. for some strange reason i cant get my slave server to do things right
05:42 <****> it just gets stuck every now and then
05:42 <****>. Get what I mean?
05:43 <****> AzMoo[w]: you can still do that with a join
05:43 <****> chadmaynard: how?
05:44 <****> AzMoo[w]: do you have my previous example?
05:44 <****> chadmaynard: yep
05:44 <****> that does what you are attempting in the paste (if it hasn't been updated)
05:45 <****> chadmaynard: that gets all children though, not children of a specific category.
05:45 <****> AzMoo[w]: add where foo = 5;
05:45 <****> or whatever. I don't remember the column names
05:45 <****> t2.categoryId =5
05:46 <****> chadmaynard: which results in only the direct child, not any other descendants.
05:46 <****> AzMoo[w]: just like your query will
05:47 <****> chadmaynard: the idea of my function was to take an id and see if that id was a descendent of another id.
05:47 <****> which can be done with the join as well
05:48 <****> I don't understand how to get arbitrary depth with only joins.
05:48 <****> i'm not saying that is the ultimate query-answer to your problem. I'm saying it does what you are trying to do with the function
05:49 <****> maybe someone has the link to the tree stuff the_wench uses
05:49 <****> I do.
05:50 <****> Well, I'm not sure what the_wench uses. But I have a link to loads of hierarchical discussion.
05:50 <****> go for it
05:50 <****> Xgc: I would appreciate it.
05:50 <****> http://troels.arvin.dk/db/rdbms/links/
05:51 <****> http://dev.mysql.com/tech-resources/articles/hierarchical-data.html
05:51 <****> There are others, but that should be sufficient.
05:51 <****> Great, thanks.
05:52 <****> here is the mysql link from that list: http://dev.mysql.com/tech-resources/articles/hierarchical-data.html
05:52 <****> chadmaynard: That looks familiar. See above. :)
05:52 * AzMoo[w] chuckles.
05:53 <****> oh. I was reading at that point
05:54 <****> it uses the same method i described earlier
05:54 <****> !tell us about trees
05:54 <****> litheum asked me to tell you this: Trees in SQL: http://www.dbazine.com/oracle/or-articles/tropashko4 and http://www.sitepoint.com/article/hierarchical-data-database, http://jan.kneschke.de/projects/mysql/sp/ and
05:54 <****> http://www.vbmysql.com/articles/managing-hierarchical-data-in-mysql.html
05:55 <****> chadmaynard: yeah, the adjacent list model does. But that doesn't give me arbitrary depth, and the nested set is far too much administration overhead for the app :\
05:56 <****> Which is why I settled on a function that attempts to find the relevant children.
05:57 <****> i think you are asking for trouble with that function
05:57 <****> I think you're right!
05:57 <****> It's slow too!
05:57 <****> Maybe I should just limit it to 5 levels of depth.
05:58 <****> Then I could easily use self joins.
05:58 <****> Do light bulbs last longer in refrigerators?
05:59 <****> yes?
05:59 <****> i asked a question. It isn't fair to answer me with a question....
06:00 <****> Well the simple, not thought-out answer is yes. But there's really not enough information ;)
06:01 <****> how so? Does temperature change the life on an incandescent bulb?
06:02 <****> Well what's it relative to?
06:02 <****> last longer than what?
06:02 <****> ....
06:03 <****> "Will it last longer than the time it takes me to sift through my fridge?"
06:04 <****> Xgc: why doesn't select count(not null) return 1?
06:04 <****> hmm
06:04 <****> no one here that I know, really
06:04 <****> chadmaynard: NULL -and- NOT NULL or the same value.
06:04 <****> a few people I recognize
06:05 <****> s/or/are
06:05 <****> Xgc and AzMoo
06:05 <****> WHERE IS EVERYONE
06:05 <****> Xgc: they are?
06:05 <****> also, whatup Xgc
06:06 <****> NULL
06:06 <****> DarienMB: Evening DarienMB.
06:06 <****> Xgc: does [RainMkr] still work for MySQL, do you know?
06:06 <****> DarienMB: yes
Total 24 pages. You are browsing page 3/24.
First :: Prev :: [1] [2] [3] [4] [5] [...] :: Next :: Last
