Of all the features of the new DK4 software, Search has received the least love. It wasn't quite ready when the software was released: there were still date range bugs and other issues. For that matter, there are still some issues here and there.
Tonight, while the forum is happy to try to answer your questions about all five searches as they exist today, I wanted to discuss the Advanced Search capability on the Search Diaries and Search Comments pages.
One thing we haven't known is what parameters would work here: there were a bunch that could be specified on DK3, but only some seemed to work on DK4, and not necessarily as we expected.
I have consulted with our Search expert and one of the designers, the inimitable jotter, and obtained some information that I hope will help you with future searches. You can find it below the jump.
As always, FAQ Forums are primarily here to let you ask questions, get advice, ask for an FAQ topic to be added asap, etc. And to give you pointers to some top-notch comments from the past 24 hours.
I thought it would be worthwhile to point you to the FAQ specifically about the new Daily Kos software, the DK4 FAQ on the dKosopedia. It has information on how DK4 works, though it remains very much a work in progress, with some significant sections yet to be written. I expect to take the information below and use it to create a section on Searching for the FAQ.
Advanced Search allows you to specify parameters that will narrow down your search, or find diaries and comments through related or tangential information. Here is a list of these parameters (some descriptions are modifications of the jotter originals):
story_id: the unique number assigned to each diary; this appears in that diary's URL. For example, here's a section of today's Cheers and Jeers diary URL with the "story_id" bolded: dailykos.com/story/2011/03/21/958504
id: the unique number assigned to each comment; this appears in each comment's URL. For example, last night's Top Comments tip jar with the "id" bolded: dailykos.com/comments/958442/40853331#c1
cid: the number assigned to each comment within a diary as it is submitted. Tip Jars always have cid=1. Referring to the same Top Comments tip jar: dailykos.com/comments/958442/40853331#c1
pid: the cid of this comment's parent comment (the one this comment is in reply to). If pid=1, then you get back all the replies to the tip jar.
parent_id: the unique number of this comment's parent comment. For example, if you used "40853331" as the parent_id, you'd get back all the replies to last night's Top Comments tip jar, one of which is by me.
title: a string that matches part of a diary title
subject: I thought this would be a string that matches part of a comment title, but I can't get it to work that way. I'll see what I can find.
user_id: the UID of a user you want to search for. If you know the number but not the name, use it. For example, I'm user_id=17760
parent_user_id: the UID of a user who wrote a comment, used when you want a list of replies to that user's comment and you know the number but not the name.
nickname: the username of a user. For example, I'm nickname="sardonyx". (It's safer to put quotes around nicknames or any strings that might have a space or punctuation in them; that way you don't forget and have the search fail or return unexpected results.)
parent_nickname: the username of a user, but used when you want a list of replies to that user's comment.
sig: if you know part of a user's sig, or want to know who has certain words in their sigs. For example, since I have "reserved" in my sig, using sig="reserved" will return all my comments in the range specified; if you use sig="rights", you'll get comments by a whole bunch of folks, including me.
n_children: a list of those comments that have the specified number of direct replies. For example, n_children=5 will return all those comments that have exactly five immediate replies.
n_recrates: a list of those comments that have exactly this number of recommends. For example, n_recrates=12 will return all those comments that have exactly twelve comment recommends.
n_trollrates: a list of those comments that have exactly this number of Hide ratings.
The following parameters are available, but I have no idea how they work:
time: jotter tried to explain it to me, but I don't understand how it could be useful. I'll try again. It doesn't have anything to do with a time range, I do know that much.
points: no clue. It does require a parameter; if you use it along, search will just return comments (and maybe diaries?) with the word "points" in it.
movie: no idea. It also requires a parameter for the same reason.
Update: I realized, thanks to OLinda, that I failed to explain the syntax for Advanced Search parameters. The general format is:
param="value"
where "param" is one of the above advanced search parameters like story_id or cid, and "value" is the id number or string that you want to search for. The equal sign is required, and should not have any spaces around it. Examples:
• story_id="958504"
• cid="1"
Note that it isn't necessary to put quotes around a "value" made up only of digits and letters, but any punctuation or spacing requires that you use the quotes. Generally, I find it's a good idea to get into the habit of using quotes after the equal sign, because it's always correct to use them, and you don't have to fix anything later.
One extremely helpful command for Advanced Search is "not". If you want to see all comments except tip jars, then not cid=1 will do that for you. If you want to exclude comments from certain diaries, then not story_id="958504" will exclude diary 958504 (the Cheers and Jeers example from above). You can also exclude comments with words, phrases, or parenthetical expressions.
jotter provided me with the following examples:
Example1: not this
Example2: not that
Example3: not "this or that"
Example4: not (this or that)
Example5: this not that
Example1 removes any hit containing the word "this".
Example2 does the same for the word "that".
Example3 removes hits containing the phrase "this or that".
Example4 removes hits containing either the word "this" or the word "that".
Example5 selects hits that contain the word "this" which do not contain the word "that".
sardonyx provides this word of caution: if "not" is the
first word of your search string, search is not currently handling it properly. In fact, it doesn't seem to "not" at all, and may also fail to "not" later parameters in the search string. There is a
workaround: put parenthesis around the first "not" expression—the whole expression, not just the word "not".
For example, if you want to exclude first comments (tip jars) and the word "chocolate", do the following: (not cid="1") not chocolate
Almost as useful, "or" is also allowed in Advanced Search. cid="1" or cid="2" will return all first and second comments from diaries. "And" is automatically assumed between advanced search parameters; if nothing's there, it's "and" by default.
A closing shoutout to dmsilev, who originally founded the FAQ Forum and posted 77 of them in 2008 and 2009.
If there's some part of the DK4 FAQ that isn't clear, do let me know. Ask questions here! Areas that continue to need fleshing out include groups, messages, and searching. I've been busier than I expected this winter, so there's been precious little fleshing out over the past two months. Things will only get worse now that spring has sprung.
~~~~~
We received a few emails today from people who took the time to submit comments that deserved recognition to Top Comments mailbox in time for the 9:30pm Eastern Time deadline. The address of our mailbox for top comments submissions remains:
TopComments AT gmail DOT com
(change " AT " to "@" and " DOT " to ".")
Anyone can send great comments to our address. Be sure to include the direct link to a comment—the URL—which is available from that comment's date/time; we need that to find your choice. Please always include your Daily Kos user name in the body of your message, so we can credit you properly. If you send a writeup with the link, we are able to include that, too, though we reserve the right to edit.
From Dragon5616:
In angelajean's MCM Open Thread, webranding made this comment that served as a reminder that, as a teacher, I must make every child feel valued.
From marigold:
In Barbara Morrill's front-page story Tim Pawlenty makes it official ... he's exploring a presidential run, here's a response from Marjmar about a video made by Tim Pawlenty's "people".
From Ed Tracey:
In the front-page diary about Tim Pawlenty's decision to kinda-sorta get into the presidential race, The Lone Apple was not impressed with his announcement video that used stock footage.
From sardonyx (your questioning Monday diarist):
In today's ROV 20: Japan Nuclear Disaster, mattman has a comment on paranoia.
In JeffLeiber's Me and My Rich Ass Friends, bkamr has a somewhat different perspective on the matter of riches.
In MinistryofTruth's diary from yesterday Are you freaking kidding me? How the hell does someone live on $7.25 an hour????, Anton Bursch has this comment.
Please add your own comment finds below!
~~~~~
A reminder: Top mojo will return once we figure out how to strongarm convince Comment Search to give us exactly what we need in a form that we can use. Which is more difficult and requires more hand-editing than it should be (or used to be).