You are viewing limited content. For full access, please sign in.

Question

Question

Duplicate entry IDs saving in multiple instances v12

asked on June 30 • Show version history

Why are we seeing the exact same entry ID in multiple instances? That's one. The other question is why there are the exact same entry ID showing per instance? One instance was cancelled which is interesting. 

These are from a cancelled instance:

 

 

This one completed successfully:


Has anyone else seen anything like this?
 

0 0

Replies

replied on July 3

Hi Chris,

I just did a simple test by starting two instances and upload same attachment, but they are saved to repository with different names, one has (2) as suffix, the Name Conflicts setting is same as yours. Can you tell how many instances are showing the same entry ids? And for those instances, the attachments are saved indeed with (2), (3) after names, or not saved at all? The files list you see is stored in Forms database, you can use the query to get the history data for the STR step.

 select * from dbo.worker_instance_history_extended_data wid
 left join dbo.cf_bp_worker_instance_history wih on wid.history_id = wih.history_id
 where wid.bp_instance_id in (280973, 281167) and wih.step_id = @STRSTEPID

update the STRSTEPID with it's real value, include more instance ids if you can find.

The history_context column stores the data that will display on the Monitor page.

What I want to figure out is whether somehow the history is mismatched that those instances retrieve same history out, or attachments are always imported as same entry id.

You can file a support ticket after getting the results, and provide us more details about your design, if you can still reproduce it, etc.

1 0
replied on July 7

I'll open another ticket. Thanks for the script. Here are the results for one of the stepid's

I initially ran this script to identify dup entry ids. i have 39 results returned .

 

-- Detail rows for every duplicated LF Entry ID
-- Includes attachment-created/uploaded date and unique attachment IDs
WITH AttachmentInstances AS (
    SELECT
        -- Forms instance
        s.bp_instance_id,

        -- Submission / variable linkage
        d.submission_id,
        d.bp_data_id,
        d.attribute_id,
        d.member_path,

        -- Attachment identifiers
        a.attachment_id,          -- Forms attachment row ID
        a.file_unique_id,         -- Forms unique file GUID/ID
        a.lfentry_id,             -- Laserfiche repository entry ID
        a.bp_id,                  -- Business process ID tied to attachment

        -- Attachment details
        a.file_name,
        a.extension,
        a.uploaded_time AS attachment_uploaded,
        a.length,
        a.is_deleted,
        a.deleted_on
    FROM dbo.cf_bp_attachment_data a
    JOIN dbo.cf_bp_data_attachment_mapping m
        ON m.attachment_id = a.attachment_id
    JOIN dbo.cf_bp_data d
        ON d.bp_data_id = m.bp_data_id
    JOIN dbo.cf_submissions s
        ON s.submission_id = d.submission_id
    WHERE a.lfentry_id IS NOT NULL
      AND ISNULL(a.is_deleted, 0) = 0
),
Dupes AS (
    SELECT lfentry_id
    FROM AttachmentInstances
    GROUP BY lfentry_id
    HAVING COUNT(DISTINCT bp_instance_id) > 1
)
SELECT
    ai.lfentry_id,
    ai.bp_instance_id,
    ai.attachment_uploaded,
    ai.attachment_id,
    ai.file_unique_id,
    ai.file_name,
    ai.extension,
    ai.length,
    ai.bp_id,
    ai.submission_id,
    ai.bp_data_id,
    ai.attribute_id,
    ai.member_path
FROM AttachmentInstances ai
JOIN Dupes d
    ON d.lfentry_id = ai.lfentry_id
ORDER BY
    ai.lfentry_id,
    ai.bp_instance_id,
    ai.attachment_uploaded,
    ai.attachment_id;

 

0 0
replied on July 8 • Show version history

@████████, just to confirm. You set your save to repository user like this, correct?

0 0
replied on July 9

Yes, but I should have replied in the support ticket, this is windows client setting, it does not affect how Forms save to repository, cause Forms doesn't support read this setting yet.

1 0
replied on June 30 • Show version history

Best bet is that this setting in the save to repo profile user is set incorrectly:


and needs to be:


Does this check out? Or is this  bug? Shouldn't every time an instance saves to the repo a new entry ID gets assigned? Unless this is an exception. I need some confirmation that this is expected behavior please. This issue has the natives shook up pretty well over here. 

@████████ what say you sir? 

Thanks everyone!

0 0
replied on July 1

This is just looking at the history in Forms. Have you checked that entry ID in the repository to see if that's the case? From the screenshot, is it possible that the same doc, therefore same entry ID, was processed multiple times, then just saved in the repository with different entry IDs or just saved only once because of the naming conflicts?

I also believe your name conflicts changes would be correct. If it's an automatic process, you don't want the repository to prompt you or it will fail.

0 0
replied on July 2 • Show version history

Confirmed. The same entry exists once in the repository and was saved by more than one Forms instance. The prompting did NOT make it fail. Rather it ignored the prompt and moved on. 

The concern is that the Forms database is malfunctioning. I have reported 4 bugfixes for version 12 in the past 2 months so to me anything is possible at this point. 

To me, each and every time save to repository runs, it should create a unique entry ID.


My question is this: if the user set in the Save To Repository step is set to prompt on name conflict, is this an exception to creating a unique entry ID for each and every new document saved to the repository?  I seek confirmation this is expected behavior or is yet another bug. Also, are there any other exceptions similar to this one? If so, this is a HUGE piece of training information I need to pass on to my team of LF Admins.

This is the first time I have seen this happen in 15 years which may be just a coincidence. But now I am suspicious of every weird thing I encounter in version 12. I officially have trust issues with v12 ha ha. 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.