ghamm
New Member Posts:10
|
09/20/2011 8:41 AM |
|
Hi Peter, I've had this up and running on a number of portals for a while without hitch. I have a series of network folders that are synced with DMX, last week the network started to act funny and the sync jobs that normally took 1-2 minutes (there are a lot of folders, synced one way to DMX Source leading, 4 times a day) now took 610 minutes. I resolved the network issue and the jobs are back to functioning as per normal. However, now the new docs from the source folders are added to the DMX_Entries table (and are visible in the Whats New module) but they are not showing in the DMX main module or any of the DMX Shortlist that I use. When the Sync job runs again, it picks up the document again and starts the whole cycle. so that I know have two entries in the dmx_entries table for teh one doc and none showing in DMX Shortlist or DMX main. Any ideas? Greg |
|
|
|
|
ghamm
New Member Posts:10
|
09/20/2011 9:25 PM |
|
Just to update, I have found out why the entries are not showing. The LastVersionID is set to -1 for those entries that are not showing, when I update the entries to show the lastVersionID of the EntryID for the entry, they start showing, of course this is giving me duplicates, I can figure out the SQL to change this though. But how is it not getting set? during the sync process? |
|
|
|
|
ghamm
New Member Posts:10
|
09/21/2011 1:36 AM |
|
Another update, From looking at the forums, some people had an issue with the trigger not being fired, DMX_EntryTriggerInsert. I have validated that the trigger is firing, from the sql code, it looks like the lastVersionID is calculated in the module code, not sure how that is done, I am pretty sure it has to be some corrupt data somewhere in the database that is causing the lastversionID to be set to -1
|
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
09/29/2011 2:09 PM |
|
Hi Greg, Add the following to the insert trigger and check if this happens again: -- repair missing LastVersionId UPDATE {databaseOwner}{objectQualifier}DMX_Entries SET LastVersionId=EntryId WHERE LastVersionId IS NULL OR LastVersionId=-1; Peter |
|
|
|
|
ghamm
New Member Posts:10
|
10/05/2011 8:39 PM |
|
Hi Peter, Came to a similar solution that solved the issue, on the insert statement I updated the code with a case statement ***************************************** -- select self (not in root) UPDATE e SET e.[Path] = e1.[Path] + CAST(i.EntryId AS NVARCHAR(20)) + ';', e.LastModified = ISNULL(e.LastModified, GETDATE()), e.LastVersionId = CAse when e.LastVersionID = -1 then e.entryID else ISNULL(e.LastVersionId, e.EntryId) END FROM dbo.dnn_DMX_Entries e INNER JOIN dbo.dnn_DMX_Entries e1 ON e1.EntryId LIKE e.CollectionId **************************************** and so far so good, no -1 versionIDs I am just about to turn back on the notifications everything is looking good here. |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
10/20/2011 4:30 PM |
|
Good tweak ... thanks |
|
|
|
|