[CWB] [ cwb-Feature Requests-2824094 ] CQPweb: query-diff postprocess

SourceForge.net noreply at sourceforge.net
Sun Oct 25 18:27:05 CET 2009


Feature Requests item #2824094, was opened at 2009-07-20 07:25
Message generated for change (Comment added) made by schtepf
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=722306&aid=2824094&group_id=131809

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: CQPweb
Group: None
Status: Open
Priority: 6
Private: No
Submitted By: Andrew Hardie (andrewhardie)
Assigned to: Andrew Hardie (andrewhardie)
Summary: CQPweb: query-diff postprocess

Initial Comment:
Idea for an additional postprocess function: query-diff ie difference between two queries.

Have an option on the concordance-page menu "filter out results shared with another query".
This goes to an admin page, where the user's saved queries are listed.

The orig query the user came from is q1, the saved query they select is q2.
Running the postprocess creates a new query containing all && only the hits in q1 that do not occur in q2.

How to implement: create a temporary mySQL table for q2's conc lines (begin position / end position [implemented as one field or 2?? ]). 
Then, dump q1. 
Read the dump line by line -- check the temp table to see if it's there,
--------If it is, skip it.
--------If it isn't, write it to tempfile
Finally, if there is anything in tempfile, add the number of hits at the start (creating tempfile2)  && undump tempfile2 to create the new query.


----------------------------------------------------------------------

>Comment By: Stefan Evert (schtepf)
Date: 2009-10-25 18:27

Message:
>From our experience working interactively in CQP, it's even more useful to
be able to run subqueries, i.e. filter query results either by collocates
(tokens with a certain property within a specified range, e.g. a finite
verb within 3 words) or by another CQP query.  This could easily be
implemented using "set keyword" and subqueries in CQP, but the results
would have to be stored as saved queries (because they can't easily be
reproduced when they're dropped from the cache).

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=722306&aid=2824094&group_id=131809


More information about the CWB mailing list