On Fri, 14 Mar 2003, Ţórhallur Hálfdánarson wrote: > -*- Greg Stark <[EMAIL PROTECTED]> [ 2003-03-14 17:43 ]: > > Do you really think someone looking for a function to break up a string into a > > list of strings would ever think of looking up "explode" in an index if he > > hadn't already used PHP or (shudder) VBScript? > > If one had gotten used to Lotus Notes, sure. ;>
To try and get back on track... Let me ask you, if you were looking through a list of array functions and you saw explode and implode, and you had no other experience with a language that used those keywords, would you, upon seeing them, have some idea what they did? I certainly did the first time I saw them way back when on Rex. Since there was no one around to teach me the religious belief that explode and implode are anathema to "real" programmers, I started using them and was quite happy with their performance. (Sorry, that's a reference to a previouis post about "real" code. I'll stop the verbal sparring now :-) I would like to have a single word. Join and Split are a poor choice becuase join already has a very well defined meaning in SQL. any variation that keeps the word join in it is a poor choice because it can be confusing. What other languages have used before is of little consequence really, as long as Postgresql's choices are internally consistent, are a desriptive word and don't conflict with current key words. The fact that some languages that use explode / implode are not favored by certain folks means less than nothing to me. The names for functions should be something that is easily found in the docs both when you don't know what it is called and when you do. Explode may be a little harder to find when you don't know the name yet, but since you should be using the table of contents, not the index to look up a function whose name you don't know, then all that means is having a good table of contents and well layed out docs. If you do know the function name, you shouldn't have 200 choices in an index or a keyword search. Join, both as a keyword, and as a word, is very common in the docs. Searching for it, I currently find 412 entries for the word join in the 7.3.2 docs. Explode, on the other hand, returns 0 count. So, if someone goes to google and searches on site:techdocs.postgresql.org join, he will get hundreds of pages back. If he searches on explode, he would, in the future, only find those pages referencing the explode function. I'll repeat, the part about looking in an index for a keyword you don't know yet is a straw man, and a poor one at that. If you don't know the keyword for a cursor is "declare" why would you look in the index? You wouldn't, you'd look up cursors in the table of contents and find it that way. Or you'd search for it. If cursors were used for some other function in postgresql (widget counting et. al.) it would make it harder to find the entries you wanted for real cursors. ---------------------------(end of broadcast)--------------------------- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly