26 messages in com.perforce.perforce-userCan't retrieve by date?
FromSent OnAttachments
Pete...@auspex.com11 Mar 1998 18:28 
Jame...@perforce.com12 Mar 1998 08:05 
Hans...@sap-ag.de12 Mar 1998 08:33 
RobC...@within.com12 Mar 1998 09:47 
Ross...@mecalc.co.za12 Mar 1998 12:07 
Pete...@auspex.com12 Mar 1998 12:14 
Davi...@home.chat.net12 Mar 1998 12:30 
RobC...@within.com12 Mar 1998 12:39 
RobC...@within.com12 Mar 1998 12:51 
Pete...@auspex.com12 Mar 1998 13:07 
Ross...@mecalc.co.za12 Mar 1998 13:11 
Pete...@auspex.com12 Mar 1998 13:12 
Lesl...@perforce.com12 Mar 1998 14:15 
Davi...@home.chat.net12 Mar 1998 19:15 
Davi...@home.chat.net12 Mar 1998 19:20 
WesP...@xmission.com12 Mar 1998 21:46 
WesP...@xmission.com12 Mar 1998 21:51 
Davi...@home.chat.net13 Mar 1998 00:06 
Gerd...@bitart.com13 Mar 1998 00:20 
Paul...@radstone.co.uk13 Mar 1998 00:59 
RobC...@within.com13 Mar 1998 10:20 
Pete...@auspex.com13 Mar 1998 10:43 
Chri...@perforce.com13 Mar 1998 11:38 
Davi...@home.chat.net13 Mar 1998 12:42 
Davi...@home.chat.net13 Mar 1998 12:45 
RobC...@within.com13 Mar 1998 13:30 
Subject:Can't retrieve by date?
From:Jame...@perforce.com (Jame@perforce.com)
Date:03/12/1998 08:05:56 AM
List:com.perforce.perforce-user

On Wed, 11 Mar 1998, Peter DiPrete wrote:

A potential user of ours (or potential adversary, if we can't do this) is used to another CM system which has flexible reporting and retrieving options. I'm willing to build these same features on top of Perforce, if I can get at the basic information. He wants to be able to set a range of dates and pull files out of the depot (or limit revision history, or comments on changes) which fall between his two dates.

I can't quite wrap my lobes around a straightforward method to do this given retrieval by label, version, or change (or client).

Ideas?

I'm not sure what you mean by "files which fall between two dates". With Perforce's atomic change transactions it's easy to get the state of files as of a certain time. Running

p4 sync @change-number

will give you the state of all depot files mapped to that client as of that change number. You can also, of course, limit which files you synchronize (update/delete) with

p4 sync //depot/foobar/... at change-number

Unless you've done something wacky (editing the dates by hand or setting the clock on your server back in time) change numbers increase monotonically with time.

I wrote a very simple Perl script which, given a date, takes the output of p4 changes and returns the change number in effect at the start of that day. The script is called p4dtc (date-to-change). Thus, for example, you can type

p4 sync @`p4dtc 1998/1/1`

to get the state of the depot at the stroke of midnight on New Years'. To compare this with the state on, say, Feb 14, run

p4 diff @`p4dtc 1998/2/14`

The script is available from http://www.perforce.com/perforce/loadsupp.html