I've workflow application using 8 xpages. It was working fine upto this moment and all of sudden when saving new document for any xpage, it started giving the following error:
Unexpected runtime error
The runtime has encountered an unexpected error.
Error source
Page Name:/XpNew.xsp
Exception
Error saving data source document1
Could not save the document 44F2A NotesException: Notes error: You cannot update or delete the document(s) since you are not listed as an allowable Author for this document
Even though I've manager access to the database. It is also weird that it started giving error on test and production server. I also ran compact with -c and still the same issue.
Ran Fixup and still same issue.
In this situation, since it appears to be a core Notes exception and not anything at the XSP layer, I'd look into ACLs first. Are you manager by way of being in a group? And if so, has that group changed in any way recently, or is it specified in a secondary Directory referenced via Directory Assistance? I've had situations where the HTTP task just sort of "forgets" group membership from a secondary Directory until I restart it.
Another potential source of trouble could be the "Maximum Internet name and password" field on the database's ACL's Advanced tab - if that's set to Author, it will override whatever your real access is.
As a troubleshooting step, I'd make an XPage with this in a computed text item:
database.queryAccess(session.getEffectiveUserName());
That should return your numeric access level. Additionally, to check on the first paragraph's theory, you could add a Form or Page with a computed value of:
#UserNamesList
That will give you a list of all effective names, groups, and roles for the current user in the current database.
There was a Authors field on Notes form with value #Username which was returning value in hierarchical form as First Name/Company.
Changed the formula to #Name([Canonicalize];#UserName) and Maximum access Level thru web kept default editor. This resolve the issue. Now it is saving documents without any issue.
Thanks everybody for help
Related
I have a notes database and recently we are having an issue across random documents. Users gets error "The linked document cannot be found in the view" when they try to open a document from a view. I am not sure how to reproduce this issue.
I tried the below options to reproduce it, but no luck:
Attaching a document link to one of the Rich text field and deleting the link's target.
Attaching a file as a link and deleting the file in the target.
I am not seeing any pattern with the documents having the issue. The documents accessed few days ago, which was not accessed for more than 2 years also becomes corrupt like this.
Other details:
The Field info tab in Document properties dialog box is empty
There is no scheduled agent running overnight affecting this documents
No change was done to the database recently
We recently migrated to Notes 11.0 from 9.0
Since we have a daily backup of the database, we restore the document from one of the restored copy in which it was working fine.
A guess: did you try re-indexing the view? Shift-F9?
It could also be in the form, or even the view.
What if ...
you open the same document from a different view?
you remove some, many or all fields from the form, do you still see the error?
I think those documents have actually been deleted, and two things make me think that:
You say in a comment that rebuilding the view makes the documents disappear. I'd expect this only if the documents no longer exist.
I have in the past had LotusScript code doing view lookups which produced documents that I knew to be deleted, but the NotesDocument.IsDeleted property was False and the NotesDocument.Items property was Empty (i.e. no fields in the document). This is consistent with your saying the Field info tab is empty.
I'd check if any user action or code could delete documents. You say there are no scheduled agents, but maybe some user action could run code which deletes documents, or some users with the Delete privilege in the database ACL could be directly deleting documents using the Delete key on the keyboard.
Also check the database properties -> Info tab -> User Detail. This should show if there are recent deletions, but the record is probably limited to the last week or less.
Not able to sync content page when i changed the approval status to unapproved.
I reverted back it to "Approved" still page not getting synced.
I compared the dumps in sync job , it's exactly same.
What could be causing the issue?
Troubleshooting the synchronization is very complicated...
A synchronization is executed using a synchronization cronjob. To find the respective cronjob:
go to hmc/backoffice
navigate to System/Cronjobs in hmc or System/Background Processes/Cronjobs in backoffice
use the types dropdown to restrict the search to "Multithreaded Synchronization"
pick the most recent one OR look in log file for this output and search for the code.
INFO [Thread-107] (000000RS) [CatalogVersionSyncJob] Sync 'sync powertoolsContentCatalog:Staged->Online' (pk:8796094464500) configured 0 entries for job '000000RS' (pk:8796125823477) schedule medias: 1
This is the cronjob that executed your synchronization. Now it is getting even more tricky:
go to the administration tab
look for an attribute called "Dump medias"
download the media file where attribute Realfilename starts with "sync_dump_"
The downloaded file should contain comma seperated values.
Example:
8796256994364;8796256961596;;actions,allDocuments,...,uid,urlLink,visible;;false
The entries represent the following data:
the PK of the source item
the PK of the target item
(timestamp)
a list of attributes, that could not be synchronized
?
item has been victim to a deadlock
Now you can troubleshoot your synchronization by evaluating source and target items and pending attributes.
Sometimes there is a problem when referencing an item, that does not exist in the target catalog, sometimes a uid is already existing in the target catalog. Sometimes an initial attribute needs change. There are a lot of pitfalls. In this case you can try to use this property to get more details about the exception that is thrown during sync:
synchronization.itemcopycreator.stacktraces=true
Here is some additional information:
https://www.sap.com/cxworks/article/2589632280/catalog_synchronization#CatalogSynchronization-TroubleshootingFailure
I have a strange problem: I want to access documents in a different database (same server). My approach is very close to this one discussed here: http://www-10.lotus.com/ldd/nd85forum.nsf/DateAllFlatWeb/517ef6249d5b9fa6852575cc00503786?OpenDocument
I have only 3 docs in the source database. 2 are created directly, one is copied from another database (these are just test document). We have a generic view that lists thos entries from a view, calcs the links in a form like this:
http://localhost/database.nsf/xpMBK.xsp?action=openDocument&db=dominotest%2Ftest%2Fulcbs%21%21projects%2FFKIE%2FEinsMuB.nsf&view=AMBKEinsAll&documentId=781F14A98A699548C1257C3200316BAC
As you can see we are using an Xpage in the current database and place parameters that point the Xpage to open the document to the source database (notation is server!!database here), a view (this is the one to which I want to return) and finally the unid of the source document.
Now the strange one:
I cannot open the copied document, receiving the
NotesException: Invalid universal id
lotus.domino.local.Database.getDocumentByUNID(Unknown Source)
error.
Even better: if I copy a document that works within the same database (the current one) this document can also not opened anymore!
What's this and can you give me a hint to solve this?
Thanks in advance!
If, by "copied", you mean either manually copied and pasted into the target database or programmatically duplicated via copyToDatabase(), the new copy of the document will be assigned a new UNID; it is not guaranteed to have the same UNID as the original did (and, in my experience, it's rare that it preserves the original). If you're duplicating the document programmatically, be sure to check its new UNID afterward and use that ID in your URL calculation instead.
I've had a problem very similar to this in the past, and the answer turned out to be that I wasn't opening the NSF file that I thought I was opening. I was using NotesDatabase.OpenByReplicaID, and there were two replicas of the database on the server, with different sets of documents. In that situation, Notes gets to pick one of the two replicas -- you have no control over it. The replica that was actually opening contained some of documents corresponding the the UNIDs that I was trying to access, but some of them really were not there and therefore the getDocumentByUNID() method was correct in throwing the "Invalid universal id" error. This was really, really hard to debug.
After I figured it out and removed the second replica from my server, the first thing I did (after testing and confirming the problem went away) was to write an agent that scans a server for duplicate replica IDs.
The UNID:S in a Domino database when it's copied to the database thru copyToDatabase is done like this.
One part of the UNID comes from the database one part is document unique. So if you copy a document from one database to another the document could get the same unid each time. If the unique combination doesn't have a valid document with that combination in the database, the document will get the same UNID everytime. In other cases the document will get a new Id.
More information can be found here
UNID and copytodatabase
Thank you guys for your ideas!
But I was completely wrong #facepalm
The problem was: a colleague coded a bean to access the other database and I didn't noticed that the config document pointed to a replica on another server, so when I copied the document within my database on my local server it was fairly clear that the xpage could not find the copied one - as it resided on the other machine.
Thank you anyway :)
Depending on the user, report data is missing when viewed via the dashboard.
-In security settings I gave organization-wide read/write permission.
-The reports are based on a two custom data objects with a master/child relationship (which is also set as read/write.)
-The report folder is also set as "read/write" and all users have permission.
Anything else that I forgot to check?
Thanks!
What error do you experience? "Insufficient privileges"? Or maybe report loads fine but just shows 0 rows?
When drilling down to the detailed report you need to make sure that
viewing user has at least Read permission in his Profile on both the master and child object
he must also has read permission to all fields used in the report (columns as well as filters. And if any of them is a formula -> check their source fields too).
Does the report use "My Opportunities" in the filters? Or unrealistic date criteria? If the dashboard wasn't refreshed in a while even date filters can cause you grief.
In some cases the Roles hierarchy is saved with the report - if the user sits in different branch of the role hierarchy than the dashboard's running user, you might have to flip it to your top level Role for example. Run the report, examine top part for Role names, adapt if needed and save it.
Perhaps the best way is to debug it is to login as this user and try to recreate this report from scratch. If you can't even select proper report type - this looks like scenario 1. If fields are missing - 2.
I have some javascript code attached to the accounts entity. This code sets the requirement level of the primary contact attribute based on the value of a custom option set field showing various account types. This was developed on one server, where it worked, and so the solution was imported into another organisation where it now doesnt work.
It seems to be only on this field as i have changed the code to look at another field and that works fine. The error it gives is that the "Object doesn't support this property or method". Also what is strange is that the field doesn't appear in the list under the entity within the solution despite it being a system field.
The code i'm using is:
Xrm.Page.getAttribute("primarycontactid").setRequiredLevel("required");
Can anyone help me figure out what it's doing?
Thanks
EDIT: Found that the code is actually making the field required despite the error, but it's not displaying the * next to it. Also if I make the field required in it's settings then it does the same thing