Thursday, June 02, 2011

Yes, and it's great!

Finally, the semantic web is here. This means that from now on, the search engines won't have to guess what is the content of the (our?) web pages. The answer will be there, behind the scenes.
Technically, we (the web developers) will add new properties to our HTML tags that will describe the content of the text. For example, you can add a property to your DIV or SPAN that will tell the search engine that this is an article, creative idea or a critique.

What is the meaning of this for us, the web developers or independent bloggers? That depends. If you want to make your blog (or site) to appear in more relevant search results, you should add these properties. Yes, you'll have to manually edit your HTML or to make a template. Of course you don't have to do this.
For those who want to have a deeper understanding of this subject, go to the common standard site - Schema.org

Friday, June 03, 2011 6:08:33 AM (Jerusalem Daylight Time, UTC+03:00)
 Wednesday, June 17, 2009

A wonderful idea I heard of is to turn to full screen mode in Internet Explorer when entering the Dashboard site. It can make a better user experience. Try it yourself and you'll see the huge difference.
How will we do that? We will add a JavaScript code to the first page of the dashboards site and after that we'll ask our system administrator to enable this script for us. Let's get to work:

Step 1 - The JavaScript

Create a new HTML component in the dashboard page. Edit it and click on the "View Source" button (the one with the <>). Enter the following code:
<SCRIPT>
var wscript = new ActiveXObject("Wscript.shell");
wscript.SendKeys("{F11}");
</SCRIPT>

It will simulate the user hitting the F11 key which will turn the IE to fullscreen mode. The only problem is that when viewing the page, you'll see this message:

This takes us to step 2.

Step 2 - Enabling ActiveX

First, I'll show you how to do this on your local maching and then you'll ask your system administrator to enable it on all the machines in the organization using distribution. Enter the Tools menu in IE and hit Internet Options. Click on the Security tab and make sure the "Trusted Sites" zone is selected. Note that the Panorama Dashboards site is already defined as trusted site (if the initial installation of Panorama Dashboards made according to the installation manual. If it's not, you have a problem). Click on "Custom Level" and Enable the "Initialize and script ActiveX ..." option:

Now, you'll see that there's no promting for ActiveX controls. Show this to your sys admin and ask him to make this happen on every user's machine (using distribution, of course). As I said, the dashboards site is a trusted site so I can't see any problem to enable this. The result is very beautiful and can make a lot of users happy. Note that you can also add a button in your page that will call the same script in order to return to normal mode.

Enjoy.

 |  |  | 
Wednesday, June 17, 2009 6:08:44 PM (Jerusalem Daylight Time, UTC+03:00)
 Tuesday, June 09, 2009

The query string was not meant to pass descriptions and string. The correct use of it is using codes and numbers. Anyway, my friend did write query strings with hebrew descriptions and didn't understand why the server side got it scrambled.

This was caused because the client side and the server side were using different encodings. The correct way of doing this is wrapping the strings using the JavaScript command encodeURIComponent (in the client side). This will turn the strings into Unicode. In the server side, using ASP.NET, you can use the Server.UrlDecode method to get it back.

 |  | 
Tuesday, June 09, 2009 10:24:55 PM (Jerusalem Daylight Time, UTC+03:00)
 Monday, June 01, 2009
Trying to build ASP.NET page with Panorama applets, I could not understand why the applets appeared blank when I put them in tables. After a while, I've found that this got something to do with the DOCTYPE declaration that each aspx has in its head (!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"). When I removed this line, it all seems to work fine. Digging into this DTD specification, I can't see anything that will prevent from applet tag to appear inside td tag. Strange.

 |  |  | 
Monday, June 01, 2009 9:32:34 PM (Jerusalem Daylight Time, UTC+03:00)
 Tuesday, April 07, 2009

When you develope a big Panorama Dashboards site, you'll have a lot of javascript code in the background. We use JS to call the Panorama SDK functions and methods, make the server side and the client side work together and to make the website dynamic and user-friendly. After few days, you'll see that you have a lot of code out there, so you must organize it (if you didn't do it in the first place). My friend Doron wrote a great post about JS development guidelines which can help Panorama Dashboards developers and any big website developers.

Wednesday, April 08, 2009 6:12:17 AM (Jerusalem Daylight Time, UTC+03:00)
 Monday, November 17, 2008

After announcing the MdxInjection program I got several requests for additional details and for the ability to run it without using Visual Studio. So, here are some important points:

  • When I published it I had developers in mind because I'm sure than anyone will want to do his little modification before using it for his own needs. That's why I published it as a solution and not as executable.
  • I written it down using VS2008 but only with the .Net 2 framework. Those of you who uses VS2005 won't be able to open the solution.
  • The program has only one public method - InjectMdx, who takes two arguments: The location of the CommonMdx file and the location of the xml configuration file.
  • The CommonMdx.mdx file contains the common MDX script. The relevant part has to start with /* Common MDX */ and then the common mdx script. Anything written before it won't be treated. That gives you the ability to save some data or comments for yourself in this file.
  • Example of the configuration xml file can be found in the Test libary inside the solution. Basically, it enable you to define in which servers, databases and cubes you want to inject the common script. Pay attention that you have to write the connection strings in this file.
  • Note that the program will detect cube dimensions with their name changed and will know how to replace them. That means that if you mention the Time dimension in the common script and inject it to AdventureWorks cube, the script will replace the string "Time" with the "ShipmentDate" string, for example.

For those of you who want simple execution file, I added a windows console project in the solution.

Link to only executable program
Link to the solution with the added windows application project
Link to the solution without the windows application project
Tuesday, November 18, 2008 6:54:17 AM (Jerusalem Standard Time, UTC+02:00)

In the previous post I talked about the DRY principle in the BI Development. I mentioned that one of the major problems in the principle's implementation is in the common MDX code. Chris Commented:

"I'd like to be able to have a global MDX Script and be able to do something like a #include to bring calculations into specific cubes. One to add to my wishlist for the next version..."

And as I said there that I have a temporary good solution until we'll have it in the next SQL Server release (if someone from Microsoft is reading...).

The MdxInjection program takes your common MDX Script and a very simple xml file that defines where to inject this script. It injects the script into your desired cubes and even replaces the dimensions' names where necessary (it is relevant where you put dimension in a cube with a different name to thr dimension or when you use Role Playing Dimensions). I couldn't hold myself from writing some test code so it's also included in the project. The project is written in C# 2 using much AMO code. All the technical little details are inside.

Enjoy.

Download Link

Monday, November 17, 2008 8:29:02 AM (Jerusalem Standard Time, UTC+02:00)
 Thursday, September 04, 2008
In the last years I've seen many astonishing BI web sites. I always asked myself what I need to do to bring my customers such beautiful web-based BI solutions. After having much experience with Panorama NovaView and especially the Panorama SDK I started to run some questions in my mind: Why won't I build some re-usable puzzle pieces that can be joined together to a web site? These pieces can be web controls that using and even interacting Panorama views and Analysis services. Why won't publish it as open source and give it to the BI community?

The PanoramaBasedWebSite project is a toolkit that contains web controls you can easily use in your ASP.NET based web site. The project is written in ASP.NET 2.0 and C# 3.5. These web controls interacts with Panorama views (using Panorama SDK) and Analysis Services (using AMO).
The idea is that you can take these puzzle pieces, combine them as you like in your web site and create your good-looking BI web site with almost no programming. The project is only in its first steps, but I believe that publishing the design/idea is also important. This is why the first release is already published, although it has only two web controls so far. This is what we have so far and what I'm planning for the future. I'll be happy to hear your thoughts/ideas:

First Release Contents

  • PanoramaView web control - this is the main control of the project and it will probably take a lot of the project's weight. The control simply shows panorama view. For now, it doesn't do much rather then showing a view so there's a lot of work to do for this control. It gets two properties - BriefingBookName and ViewName. You can look at the TODO: comments in the code to see what future plans I have for this control.
  • UpdateDatePanel web control - this control shows the date and time when the last process of the cube was made. It can be used in two ways: You can only set the PanoramaViewID property. The control will extract the cube and the database name from the view and take the update date from the cube. The other way is to set the CubeName and DataBaseName properties.
Future Plans

  • KPIView - Already working on it. Similar to PanoramaView, but if the view shows KPI then a drilldown will be made when the user clicks on a gauge.
  • QueryList - Shows the result of MDX query. For example, the list shows the top 10 employees of the month (in sales perspective, for example). This list will be interactive, meaning that clicking on a row will make a drilldown, drill to data or replace the list with another query results.
  • DimensionPicker - Gives the user the ability to pick members of a dimension/hierarchy. After selecting, the control will slice all the views on the page (or only predefined set of views).
  • DatePicker - Same as DimensionPicker but for dates. It will show a calendar to the user and clicking on a date will perform a slice in the views.

The use of the controls in your aspx pages is very easy. You can see for yourself:

<PanoramaControls:UpdateDateLabel ID="UpdateDateLabel1" runat="server" PanoramaViewID="PanoramaView1" />
<PanoramaControls:PanoramaView ID="PanoramaView1" runat="server" Width="100%" Height="80%" BriefingBookName="MikysBook" ViewName="MyFirstView" />

I'll be happy to read your thoughts and ideas about this project. There will be more to come. Stay Tuned.

 |  |  | 
Friday, September 05, 2008 3:37:45 AM (Jerusalem Daylight Time, UTC+03:00)
 Saturday, July 26, 2008
OpenSearch is one of the beautiful things I discovered lately. If you're using Firefox 2 and above or Internet Explorer 7, look at the search field in the right-top corner of the browser. See the shiny little thingy there? Click on it and you can instantly add two new search engines for fast search through your browser. The first one is my blog's search and the second (and more important) one is the ability to search BiBlogs right from the browser. Yeah, now you can search the whole BI community's blogs with only one click.

I call all the BI bloggers to add this too. It's 5 minutes work and it can help lot of people out there. See here for instructions.

Saturday, July 26, 2008 7:26:41 AM (Jerusalem Daylight Time, UTC+03:00)
 Monday, May 05, 2008
My blog is not an official .Net blog, but I find myself writing a lot of C# & VB.Net code over the last weeks.

I remember myself working a lot with ObjectDataSource and DataGrid/DataView/Repeater controls in order to reflect the user what is going on in my DB. The recent changes in the .Net world reflect the major demand from the developers to help us making this easier. First, we were introduced to LINQ which is the first level. Now, I believe that the ASP.Net Dynamic Data is the second level which brings it all together to the web environment.
We are all busy men and we often don't have much time to persue after all the new .Net frameworks and developments. My only way to stay tuned to what's going on is blogs, so I read when I have time. But when I want to learn it in more intimate way I watch screencasts.
I recommend all of you viewing the 17-minutes-cast from David Ebbo about Dynamic Data. It will show you what it's all about and after it you'll even be able to create it for yourself. I hope that this is the end of writing junk code in order to connect your DB to your UI. Time will say if I'm right.

Tuesday, May 06, 2008 5:48:17 AM (Jerusalem Daylight Time, UTC+03:00)
 Monday, February 25, 2008
I had a big test yesterday in the university, so now I can blog again.

the title says it all. Enter here if you're a student. MS offers many free developers tools for students under a project called DreamSpark. Among the tools you can find: Visual Studio 2008, Windows Server 2003, Game Studio 2 (which I eager to learn for a long time, especially because I'm a gamer) and the known Express editions of SQL Server and Visual XXX (you name it).

Enjoy.

Monday, February 25, 2008 10:48:54 PM (Jerusalem Standard Time, UTC+02:00)
 Saturday, August 11, 2007
A good example of how to not use Ajax.

Few months ago, Blizzard Entertainment announced that Starcraft 2 is on the way and they opened a web site to make sales promotions. In the sections where you see details about units and buildings in the new game, clicking on a unit will change 90% of the page with Ajax (no refresh in browser). The problem is that many heavy pictures and flash are loaded using this method and this makes the browser freezing for a while. I tried it with different browsers and different computers but it won't help. The browser always freezes.

Think twice when designing Ajax-enabled web page. Downloading too much data with Ajax can perform troubles. And troubled users won't come back to your web site.
Sunday, August 12, 2007 6:09:56 AM (Jerusalem Daylight Time, UTC+03:00)
We've been working for a while to enable SSO in our Panorama's Dashboard site. In a matter of fact, the responsibility for this was under the skilled hands of our system team. After a short time they succeeded and SSO was established in our site. We saw it when we entered the site: Instead of login page we directly entered the dashboard page.
After a few days, when I entered into the settings section of the dashboard site, I saw this:



Yes, that's right. No security at all. This is why we entered directly to the dashboard page instead of the login page...
The system team claims that they never said that the SSO succeeded and we say they did. No one will prove he's right, so there's no one to blame. But blaming is not everything. The important thing here is to learn for the next time: When you think you got a feature - check it. Things not always as they seems to be.
Sunday, August 12, 2007 5:52:53 AM (Jerusalem Daylight Time, UTC+03:00)
 Saturday, July 14, 2007
Two days ago I talked with a friend about our feelings at work. I told him that many times I have the feeling that people just don't work. He asked me how I can see that, and I told him that they can't concentrate when they all going to have coffee or talking to each other every minute. "So, what you want them to do, sing: Work, Work, Work! all day?", he said. Then I told him this short story:

Last week I went to say hello to my friends in a very serious (and therefore successful) programming team. There were three guys (Doron, Yossi and Roy) coding there. I love challenges, so I tried to go to the other side of the room (and this team has a big room) unseen. Guess what - I made it. I went to the other side of the room and no-one saw me. They were all very concentrated on their code. I could steal everything I wanted, but you know - friends...

"That's how should people work", I told my friend. Still, I don't think that everyone can do this all the time, but I expect every worker to behave that way at least an hour or two in a day, and I promise you that their production will greatly grow.

Sunday, July 15, 2007 6:43:01 AM (Jerusalem Daylight Time, UTC+03:00)
 Thursday, May 10, 2007
As I have said in the introduction, I recently left the .Net department in my company. We worked on a very interesting GIS application, using ESRI's ArcGIS line of products.
In the day before our deadline, I've found a really serious but also foolish bug: In many places in our product, the date looked like this: 13/41/07, 20/56/07, and so on.
When I've seen that I immediately knew what happened. Instead of formatting our DateTime data as dd/MM/yy, we used dd/mm/yy. As you probably know, "mm" is the minutes and "MM" is the month, so the dates had the minutes instead of the month.
That was a foolish mistake which caused us to reopen the solution and running many tests all over again. bummer.

What have I learned from this?
  1. Always remember the DRY (Don't Repeat Yourself) principle (from the pragmatic programmer). If our DateTime format was stored in one place, the change could be much more simple.
  2. Tests have to be more specific: "Check that all fields are OK" is not enought. Many programmers checked these pages/modules and nobody found this bug.
  3. I believe that code review should had cover this bug. The code review must be in high quality.

Thursday, May 10, 2007 7:36:22 AM (Jerusalem Daylight Time, UTC+03:00)