> use yesterday\a_sname alias old && yesterdays table > select 0 > use a_sname alias sname > set relation to recn() into old > replace all sn_account with old.sn_account > > Hey presto you have all your PK's back. Anyone think of a better way of > doing that? > >Peter
<untested> update a_sname set sn_account = (select sn_account from .\yesterday\a_sname.dbf old where old.recno = a_sname.recno) Andrew Davies MBCS CITP - AndyD 8-)# ********************************************************************** Manchester City Council supports Smokefree England - 1 July 2007 This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. Please contact [EMAIL PROTECTED] with any queries. ********************************************************************** _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED] ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.