Здравствуйте! Недавно работаю с данным продуктом, поэтому не спец. Не подскажите любой из методов изменения ID реплики базы данных под необходимый. ...
Sharon Bellamy is looking for some examples of Domino apps being surfaced through WebSphere Portal for two reasons. One -to use in a UKLUG session. Two - she's planning on building some apps and would like to know how it worked for you.
WANT THE TOP LOTUS EXPERTS BY YOUR SIDE WITHOUT PAYING HEFTY CONSULTING FEES? LOOK NO FURTHER. Like having a team of consultants by your side -- ones who have all the answers and never make mistakes -- THE VIEW gives you immediate access to field-tested instruction, guidance, and best practices from the brightest Lotus professionals around.
My ASP.NET adventure is about 18 months in now and I continue to learn. The more I learn the more I love it. One of the things I've learnt to love just recently is LINQ-To-SQL.
At first I was dismissive of LINQ. Mainly because I didn't really get it and thought it was too advanced, so I'd come back to to it once I'd mastered the traditional approach of using raw SQL.
What I found with the old approach was that apps I was building soon became a mess. The DataSets had their own SQL stored in them and then lots of references to Stored Procedures in the database itself. Before long they became unmanageable.
Now that I've switched to LINQ-To-SQL I've not written any actual SQL code and my database no longer have Stored Procedures. All my data-access logic is written in LINQ (C# code) and stored in repository classes in the app's source code. It feels so, so much better this way.
I wish I'd taken note of LINQ from the off!
What is LINQ?
From memory I think it means Language Integrated Natural Queries. Even if it I got that wrong it does kind of explain (at least in my mind) what it is. Firstly that the queries you write feel more natural to a programmer ("this"=="that" rather than SQL's "this"="that" etc) and that it's integrated in the language you're using (C#).
Basically it's a programmer-friendly way of doing SQL queries. You don't need to write any SQL at all. It does all that for you by converting your code in to SQL.
Here's a basic example of using LINQ (it doesn't have to be used to access SQL!):
string[] names = {"Tom", "Dick", "Harry", "Jake"}; IEnumerable<string> namesWithAIn = names.Where(n=>n.Contains("a")); //The namesWithAIn "list" has two strings in it -- Harry and Jake
We define an array of strings and then pick out those containing the letter "a". The result is an IEnumerable object. Don't worry about that though. It's just a class that lets you loop its member. Like a fancy List.
Don't worry about the The "n=>n." bit either. It confused me at first but is quite simple really once you get used to it. It's called a "Lambda expression" and, in my mind, I read it as "using n". So, what you're doing is saying "from here on in 'n' refers to the objects in the list I'm querying. In our case 'n' would be each of the strings in the array. In reality it would refer to rows of a table or the classes C# is using to represent those rows.
LINQ-to-SQL
Let's say you have a SQL table in a database like this and it's called "Kids":
ID
Name
Age
Sex
1
Quinn
16
Female
2
Felix
4
Male
3
Minnie
2
Female
4
Evelyn
1
Female
In Visual Studio you can add LINQ-to-SQL classes to create objects to represent tables. You would then be able to do this:
IEnumerable<Kid> girls = dataContext.Kids.Where( k=>k.Sex.Equals("Female")).OrderBy(k=>k.Age); foreach(Kid kid in girls){ Console.WriteLine("Found a girl called "+kid.Name);
}
Pretty cool, no?
No need for any SQL and all the objects are strongly-typed. Like it promises it just feels natural.
Note the class called "Kid" we're referring to. I didn't create this. Visual Studio did. And for each column in the table it added the appropriate property to the class. Such as an integer called Age and a string called Name etc.
You can make the Lambda expressions in the Where() "clause" as complex as you like:
IEnumerable<Kid> girlsTwoOrOlder = dataContext.Kids.Where( k=>k.Sex.Equals("Female") && k.Age>=2).OrderBy(k=>k.Age); foreach(Kid kid in TwoOrOlder){ Console.WriteLine("Found a girl called "+kid.name);
}
Notice we're using "&&" rather than "AND", which is what SQL expects us to use. Again, more natural.
LINQ gives us lots of cool methods to use. Two examples are Skip() and Take(), which come in handy when paging through large tables.
If you wanted entries for page 3 of a view that showed 5 rows per page, you would write:
Obviously this is merely scratching the surface of what LINQ-to-SQL can do.
Hopefully this is enough to whet your appetite? What I'm trying to get across is that there's no need to be scared of it (like I was). Embrace it from the off! I only regret that I didn't.
One of the cool things I discovered while getting to grips with LINQ is that you can chain LINQ queries together. This helps when trying to follow the Don't Repeat Yourself (DRY) approach to design, which I'm sure we all do.
While using DataSets and SQL/Stored Procedures in ASP.NET projects I was finding myself repeating the same SQL over and over. Any change to the column in any of the tables would likely mean a change to all the queries I had stored. Ergh.
As an example, let's say you have your zoo and its animals. If you want a list of animals that are viewable by the visiting public you might have a query like this:
public IEnumerable<Animal> GetViewableAnimals(){return zoo.Animals.Where( a => a.Alive && !a.Sick && a.DepartureDate == null).OrderBy(a => a.Name);
}
Not a great real-world example, but you get the idea - there's a base logic for what set of animals any other list should ever derive from.
Now, let's say you want get animals of a certain types (monkeys?). You might write another method, like so:
But, wait. You've repeated yourself! What if the logic by which you decide if an animal is "viewable" changes (say, you let the public see sick animals)!? You need to update all methods.
Well, you could instead have each method return an IQueryable object and chain them together. Like so:
Notice how the "by type" method first gets the "base" query from the other method and then appends an extra clause to the "where" part of the statement.
Note that it's not until you try to access the data in the IQueryable class that it performs the SQL query. So, the above does not perform two SQL queries. Just one!
A fuller example would be the following example of a repository class:
There might be other or better ways to do this, but, for now, it's my preferred approach. I came up with the above while working on an app that has a fairly complex set of rules about what the base set of viewable rows are for the current user. Chaining queries like this means I only have to write this logic once.
I need to export data to Ms-excel using xpages View. I created the view or i can create the xpage and embeded the view and i given a sorting and grouping also.Now i need to export the view data to Ms-excel. Is there any suggestions to export the data.
The IsSummary flag is only used to determine if a field is available for views. Since Profile documents can never be shown in a view, all items stored on profile documents should have their IsSummary property set to false. This would remove the limitations on the amount of data in a profile document that is usually seen in a regular notes document.
When you are writing a new message, you cannot drag and drop an existing message into it (like an EML for instance). Instead it creates a doc link which is very annoying because not readble for external people and needs to open to access to your mailbox to be effective... Copy-pasting ? Are you kidding me ? ;-)
Currently when you open a mail to read and delete, it opens the next one. Which is excellent. But there should be an option to 'deactivate' this in order to go back to the Inbox after the delete.
I know : this has been posted several times... But it still isn't there !! Also make available to other platforms than MS if possible. Some other enhancements are always welcome of course.
I have read some post on edbrill.com stating that this is difficult because it needs to be translated into all the supported languages before being made available. I cannot see why this should stop the idea : I am willing to take the Dutch and French version, leaves all the other languages for other volunteers ;-)
Currently, the NotesDatabase class has no method for creation of new folders.
There is a method for creating a new view, but not a folder.
It is possible to use the C API (the folderCreate API) to do this from LotusScript - I have successfully used it on numerous occasions - but a native LotusScript method would be preferable.
Being the deployment guy, I must have done this countless times - copying the ACL entries from one database and pasting into another - one by one. Why not have the ability to copy them all on the click of a button and paste into another? The user name, user type and access level + checkboxes may be copied. This should be useful especially when working with datbases for an organization unit.
David Taieb has released a new
version of this project JAVADDIN.
Here is how he describes the new functionality: - Changed the javaddin executable name
to "dots" and updated documentation accordingly.
- Added support OSGi profiles ...
TuneKrnl is a program that runs when a Lotus Domino server is started on a Linux platform. It is used to change the Linux kernel values that are needed for large scale Domino environments. When executed, several errors display.
Exporting emails with in-line images in Windows 2003/2008 (Often as a Citrix user) to .RTF format results in the images in the email converting to black boxes.
You can view the 8.5.2 Original edition of the Lotus Notes Traveler 8.5.2 documentation in PDF format using the file attached to this article. Note that this version of the documentation is considered nonaccessible.