Re: Duplicate Records

2006-10-13 Thread McKenzie, James J C-E LCMC HQISEC/L3
**



Joe:
 
If the entry is NULL, then the results should be 
NULL.  You are right.  I think this is another one that deserves the 
'' != $NULL$ treatment.
 
James McKenzie
L-3 GSI
 


From: Action Request System discussion 
list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Joe 
DeSouzaSent: Friday, October 13, 2006 11:09 AMTo: 
arslist@ARSLIST.ORGSubject: Re: Duplicate 
Records
** 




Yes,
 
Scan through the table for conditions that will cause a record to be 
duplicate but make an exception to skip records that have a NULL 
value in that field. Then if it finds any match, return the Entry-ID of 
that record to a temporary field. If at the end of the search the Temp field is 
NULL, you know you haven't found a duplicate. If its not NULL return the 
duplicate record error you want to return and prevent the save of that 
record..
 
Cheers 
Joe D'Souza
Remedy Developer / Consultant,
Shyle Networks,
New Jersey.

- 
Original Message From: "Sullivan, Neil G CTR USAF AFRL/SNOX" 
<[EMAIL PROTECTED]>To: arslist@ARSLIST.ORGSent: Friday, 
October 13, 2006 9:07:56 AMSubject: Duplicate Records** 
Listers, 
Is there any way possible to use workflow to check 
for duplicate records in a form without using a unique index?  I can't use 
an index because some of the values in the field will be null.
Any help is appreciated. 
Neil "Sully" Sullivan Remedy Developer/Administrator AFRL/SNOX Wright Patterson AFB, OH 
45433 937-904-9788__20060125___This 
posting was submitted with HTML in it___
__20060125___This posting was submitted with HTML in it___


Re: Duplicate Records

2006-10-13 Thread Joe DeSouza
**

Yes,
 
Scan through the table for conditions that will cause a record to be duplicate but make an exception to skip records that have a NULL value in that field. Then if it finds any match, return the Entry-ID of that record to a temporary field. If at the end of the search the Temp field is NULL, you know you haven't found a duplicate. If its not NULL return the duplicate record error you want to return and prevent the save of that record..
 
Cheers 
Joe D'Souza
Remedy Developer / Consultant,
Shyle Networks,
New Jersey.

- Original Message From: "Sullivan, Neil G CTR USAF AFRL/SNOX" <[EMAIL PROTECTED]>To: arslist@ARSLIST.ORGSent: Friday, October 13, 2006 9:07:56 AMSubject: Duplicate Records** 
Listers, 
Is there any way possible to use workflow to check for duplicate records in a form without using a unique index?  I can't use an index because some of the values in the field will be null.
Any help is appreciated. 
Neil "Sully" Sullivan Remedy Developer/Administrator AFRL/SNOX Wright Patterson AFB, OH 45433 937-904-9788
__20060125___This posting was submitted with HTML in it___

Re: Duplicate Records

2006-10-13 Thread Robert Molenda
Title: Duplicate Records
**








Yes this works, but ensure you take into
consideration that this will query the table with a match to that field, consider
the QBE settings, and the total record count for the table.

 

When we do this, we don’t use a
table query, we use direct sql which is better performance for high row count
tables.

 

Select count(*) from  where
 = ‘value’

 

Then compare the set-fields-returned-value
!= 0 then error

 



Thanks-n-advance; 

HDT Platform
Incident / Problem Manager & Architect 
Robert Molenda 
IT OS PA 
Tel: +1 408 501 6310 
Fax: +1 408 501 2410 
Mobile: +1 408 472 8097 
[EMAIL PROTECTED]


Quality
begins with your actions.



 









From: Action
Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Grooms, Frederick W
Sent: Friday, October 13, 2006
6:30 AM
To: arslist@ARSLIST.ORG
Subject: Re: Duplicate Records



 

Sure ... You can do a
simple Set Fields action to set a Display Only temp field as an
indicator.  A second filter then checks the indicator to see if the value
exists.

 

Example

 

Scenario:  
Regular Remedy form called FormA with only default fields (plus a 15 char
display only field called zTmpDupID).  You want to make sure users
don't enter a short description twice.

 

Submit version

    Filter
1 On Submit

    Action 1:  

   
Set fields Read value from FormA

   
Set Fields If:  'Short Description' = $Short
Description$

   
No Requests Match Set to $NULL$

   
Any Requests Match Use First Matching

    Set zTmpDupID = $Request ID$

 

Modify version

    Filter
1 On Modify

    Action 1:  

   
Set fields Read value from FormA

   
Set Fields If:  'Short Description' = $Short
Description$ and 'Request ID' != $Request ID$

   
No Requests Match Set to $NULL$

   
Any Requests Match Use First Matching

    Set zTmpDupID = $Request ID$

 

 

Filter 2

    If zTmpDupID != $NULL$ Show Error to prevent save

 

 

Hope this info helps

Fred

 







From: Action Request System discussion
list(ARSList) [mailto:[EMAIL PROTECTED] On
Behalf Of Sullivan, Neil G CTR USAF AFRL/SNOX
Sent: Friday, October 13, 2006
8:08 AM
To: arslist@ARSLIST.ORG
Subject: Duplicate Records

** 



Listers, 

Is there any way possible to use workflow to check
for duplicate records in a form without using a unique index?  I can't use
an index because some of the values in the field will be null.

Any help is appreciated. 

Neil "Sully" Sullivan 
Remedy
Developer/Administrator 
AFRL/SNOX

Wright
Patterson AFB, OH 45433 
937-904-9788  

 






__20060125___This posting was submitted with HTML in it___
__20060125___This posting was submitted with HTML in it___

Re: Duplicate Records

2006-10-13 Thread Carey Matthew Black

You can combine the two Filter #1's below too.
Use the second Set field If: Qualification (include AND 'Request ID'
!= $Request ID$). It will work just as well for Submit as it does
modify.

The basic idea is "Test4Dup" that was published back in the days of
old in an RxPress. ( Circa 91? 92?)


The only "gotcha" is that it does not work for multiple transaction
that are taking place right now. (AKA: before the first transaction is
committed to the RDBMS.) One POSSIBLE way to get around that is to do
a Filter non-phased Push to a second form with data the you would us
in the Test4Dup logic. Then issue a Application-Release-Pending and
have your Test4Dup logic run on the target form for the Push action. I
think that will catch the second record even if the first parent
record is not yet committed to the RDBMS. (But I have not tested that
idea. Bugs may abound...)

--
Carey Matthew Black
Remedy Skilled Professional (RSP)
ARS = Action Request System(Remedy)

Love, then teach
Solution = People + Process + Tools
Fast, Accurate, Cheap Pick two.



On 10/13/06, Grooms, Frederick W <[EMAIL PROTECTED]> wrote:

**

Sure ... You can do a simple Set Fields action to set a Display Only temp
field as an indicator.  A second filter then checks the indicator to see if
the value exists.

Example

Scenario:   Regular Remedy form called FormA with only default fields (plus
a 15 char display only field called zTmpDupID).  You want to make sure users
don't enter a short description twice.

Submit version
Filter 1 On Submit
Action 1:
Set fields Read value from FormA
Set Fields If:  'Short Description' = $Short Description$
No Requests Match Set to $NULL$
Any Requests Match Use First Matching
Set zTmpDupID = $Request ID$


Modify version
Filter 1 On Modify
Action 1:
Set fields Read value from FormA
Set Fields If:  'Short Description' = $Short Description$ and
'Request ID' != $Request ID$
No Requests Match Set to $NULL$
Any Requests Match Use First Matching
Set zTmpDupID = $Request ID$


Filter 2
If zTmpDupID != $NULL$ Show Error to prevent save


Hope this info helps
Fred

 
 From: Action Request System discussion list(ARSList)
[mailto:[EMAIL PROTECTED] On Behalf Of Sullivan, Neil G CTR USAF
AFRL/SNOX
Sent: Friday, October 13, 2006 8:08 AM
To: arslist@ARSLIST.ORG
Subject: Duplicate Records


**

Listers,

Is there any way possible to use workflow to check for duplicate records in
a form without using a unique index?  I can't use an index because some of
the values in the field will be null.

Any help is appreciated.

Neil "Sully" Sullivan
Remedy Developer/Administrator
AFRL/SNOX
Wright Patterson AFB, OH 45433
937-904-9788


___
UNSUBSCRIBE or access ARSlist Archives at http://www.wwrug.org


Re: Duplicate Records

2006-10-13 Thread Grooms, Frederick W
Title: Duplicate Records
**



Sure ... You can do a simple Set Fields action to set a 
Display Only temp field as an indicator.  A second filter then checks the 
indicator to see if the value exists.
 
Example
 
Scenario:   Regular Remedy form called FormA with 
only default fields (plus a 15 char display only field called zTmpDupID).  
You want to make sure users don't enter a short description 
twice.
 
Submit version
    Filter 1 On Submit
    Action 1:  
    Set 
fields Read value from FormA
    
Set Fields If:  'Short Description' = 
$Short Description$
    
No Requests Match Set to 
$NULL$
    
Any Requests Match Use First 
Matching
    Set zTmpDupID = $Request ID$
 

Modify version
    Filter 1 On Modify
    Action 1:  
    Set 
fields Read value from FormA
    
Set Fields If:  'Short Description' = 
$Short Description$ and 'Request ID' != $Request ID$
    
No Requests Match Set to 
$NULL$
    
Any Requests Match Use First 
Matching
    Set zTmpDupID = $Request 
ID$
 
 
Filter 2
    If zTmpDupID != $NULL$ Show Error to prevent 
save
 
 
Hope this info helps
Fred


From: Action Request System discussion 
list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Sullivan, Neil G 
CTR USAF AFRL/SNOXSent: Friday, October 13, 2006 8:08 
AMTo: arslist@ARSLIST.ORGSubject: Duplicate 
Records
** 

Listers, 
Is there any way possible to use workflow to check 
for duplicate records in a form without using a unique index?  I can't use 
an index because some of the values in the field will be null.
Any help is appreciated. 
Neil "Sully" Sullivan Remedy Developer/Administrator AFRL/SNOX Wright Patterson AFB, OH 
45433 937-904-9788  
 
__20060125___This posting was submitted with HTML in it___