Blog ala Vidar

SQL, AppFrame and other cool technologies

Tag Archives: Omega

How does Windows Live Writer work?

When you first install live writer, you get 4 radio-buttons. Choose the 4th. “Other” or something like that. Then it asks you for a URL. This will be This will only work after I’ve set up your blog first. Username and password will be the same as in TeamDoc.

After filling category and adding the text, you can insert a picture by clicking "Picture” under Insert on the right side. After doing that, you might want to add the blog item to a category. Then you need to go into TeamDoc and add a section to your blog-TeamDoc. Then, in live writer, click the combo box “Set category”.

To insert code, install this plug-in and click on the right “Code…” under Insert. This supports VB, TSQL, JavaScript, HTML etc.

Before you publish, you can preview your post. When that’s done, click “Publish” (in the upper left corner), and you’ll get forwarded to your blog.

You can also open previous posts to fix typos or similar by clicking file –> Open. There you’ll find recently posted, or you can search all your posts.

Under the “Blog Data” section in your TeamDoc, you can change the about page, your stylesheet (CSS), header etc. Contact me if you’ve got problems with any of these and I’ll help you through it 🙂

Bloggers bloggers bloggers!

As you might have noticed, Jarl Erik have fixed a couple of things on this site. Including the new rating-system. Would be nice if you used this so we (the bloggers) know what’s interesting and what’s not.

Also, I want to invite others to start blogging. Is there anything you want to write about? Tell me, and I’ll set up a blog for you! I sent an email yesterday asking the existing bloggers to write about a couple of topic that I would be interested in reading more about. Is there any topics you’d like to read more about, please tell me (or the others). If you tell me, I can ask others to write about them if it’s not something I feel comfortable writing about.

We use Windows Live Writer for blogging. Here’s a couple of plug-ins that are very useful:

Insert Code
Syntax highlighting, row number etc. Supports C#, HTML, MSH, Java Script, Visual Basic and TSQL

Insert File(s)
This allows you to insert files directly into Live Writer, and saves the files automatically to our filestore.

Please remember security. Do not mention server-names, details that can be exploited by hackers. Also keep in mind that our customers might be reading these blogs!

News from Ølen and stuff that matters

Quite a lot has happened in Ølen lately. We’ve had visitors, moved to other departments etc.

Most important thing first; I’ve (been?) moved from the technology department to 3E (Trygve Haaland). This means (in theory) that I’m no longer the DBA for Omega’s main database, support for R3 or similar. My new responsibilities will be supporting Trygve’s team with any of their projects. I’m sure there will be plenty of technical challenges but first I want put my focus on quality. Quality can always be improved and we will look into every corner for ways of improving both existing applications and our every day performance. This includes using the latest builds, going through QA-lists, helping each other with best practices and making sure that what we build is tested at all times. I’m not saying I’m better than anyone else making building projects with good quality, but as some of you may know, I’ve got a big mouth and I’m not afraid to use it J Therefore I think I’m pretty good at making OTHERS delivering quality projects. This will hopefully make us better at reporting bugs to the technology department, and trying to get them to deliver with the same quality as us. So, in the long run, we’ll all hopefully deliver the best of the best, not just the best!

So, who’s going to support you now? JanCB has taken over for me several months ago. He’s responsible for all support. But, if you got DBA-related questions, PLEASE send them to me! You probably already know I LOVE databases. If MSSQL was a lady, I’d already asked her to marry me!

I’m not the only one who’s moved. Johnny and Øystein have moved to Kiwi where they’ve started a “PIMS R3” team. There have been some rumors about creating a new department for them, but this is not settled yet. Along with them, Jan Leon has moved to Gassco for a couple of months. Hopefully, he’ll be back in Ølen soon. I miss my smoke-buddy. Audun Habbestad is also a part of Johnny’s team, along with Vadim, Lina and a couple of other guys from Lithuania. Sorry if I forgot to mention anyone. I’m not sure who’s a part of this team and who’s not.

So, who’s left in technology?
JanCB – responsible for support, servers, internal MarketMaker etc.
Torgeir – TeamDoc
Peter – The big chief
Georgij – Web guru
Tomas – CR3 guru

Other news? Jarl Erik is back in business. I’ve got permissions from Håvard Matre to borrow him a couple of days to work with If you’ve got suggestions on how to make this site better, please tell me and we’ll fix it!

Jekaterina, or Kate as we call her, have been on “my” team since she started in Omega. We’ve worked with various stuff, such as CR1/CR2 bugs, database related tasks, personnel planning etc. Lately I’ve also had the pleasure of working with Kai. What struck me with them is that they always try their best to figure out stuff on their own before asking questions. This is something the rest of us can learn from. I know I’ve got a tendency to ask Torgeir or Jan Leon if I’ve got any tricky things BEFORE trying to figure things out for myself. Note to self: Learn to keep my mouth shut for more than 5 seconds.

The last month I’ve also worked on a cool project with .NET CE (compact edition) on handheld computers. A customer wants to be able to keep track of deposits of tools in a tool store. To do this they want to use a handheld computer to scan bar codes, instead of manually inserting a lot of numbers. This has given me a good chance to get to know CE. My first comment about this is its lack of features. For example, if you want to be able to sort a listview by clicking on the column headers, you need to make this feature yourself. .Sort isn’t a method on the listview control in CE.


As some of you might have noticed, I’ve had #AppFrame@EFNet as my personal message on MSN. What does this actually mean?

IRC (Internet Relay Chat) is a technology developed as early as in 1988. It’s a chat protocol. The main idea is that there are several servers connected in a network, which clients can connect to to chat with others. The idea behind MSN is in many cases very similar to IRC. The only main difference, in my eyes, is the channels. If you want to start a group discussion on MSN you have to invite several people to your conversation. This can easily be a mess. What do you do if you just need help with something, or want to chat about one topic and don’t care who answers? Well, MSN does not have any features like this. IRC on the other hand has channels. You can join any channel you want. I’ve started #AppFrame (# means it’s a channel) on the EFNet network. Anyone can join to chat, or get help with AppFrame related technologies. NB!!! THIS IS NOT AN OFFICIAL SUPPORT CHANNEL FROM OMEGA!

You can also join other channels to chat, or get help with other technologies. I myself have joined #Haugesund (my hometown), #sql and #appframe. There’s also channels like #vb, #aspnet etc.

Looking forward to have a chat with you on IRC!


I should probably call this FREE PORN. That way everyone would have read it, but anyways.. Although this is a bit of a boring subject, this will only take two minutes, and it can save you many hours afterwards! The topic is security. I’ve gathered some security actions after watching a couple of TechEd Sessions from Steve Riley about Security. All my bullet points are COST FREE as in no money spent, and almost no time spent implementing. Then, why don’t you already do it? I don’t care, but please start doing it.


  • Anti-malware
    This includes virus, spyware, adware+++. Vista comes with Windows Defender, but AVG FREE is a good alternative.
  • Be skeptical!
    Never give your password to ANYONE. This includes your administrator! If I really want/need (for testing purposes) to use your account, I can reset your password to something.
    Never click on anything that you don’t know the results of. For example, lately I’ve gotten many links from a contact on MSN. Typically “Try this cool website:”. I have of course changed the host so you won’t click on it 😉 The reason I got suspect was that this person is Norwegian. Why should she start a conversation with an English sentence and a link? And why is she offline? She’s clicked on one of those links herself, added her msn address and password to the site, and there you go. This also goes to e-mails. If for some reason spam gets through our very tough spam-filter, be skeptical! For the record, I’ve blocked this person from MSN. When she’s stopped clicking on stupid links, I’ll unblock her.
  • Do not run as administrator
    Most common applications does not have any problems running as normal user
  • Ensure Microsoft update is running frequently
  • Firewall
    Both XP and Vista comes with built-in firewalls. DO NOT DISABLE THEM! If you’ve got apple, throw it in the garbage and buy a real computer.
  • Lock your computer when you leave it
    THIS COST YOU about 14 calories, but believe me, you want to loose these 14 calories. Have you ever thought about how easy it is to for example go in to the Omega HQ office at for example lunch time, go in to an empty office and play with your computer? Many of you leave your computer when you’re logged on to MarketMaker, logged in with management studio to our SQL Servers and maybe remote desktop. Now, use one minute to think about what the intruder could do, just because you want to save your 14 calories. This is the easiest security action to take, less time consuming and it’s totally cost free, and also, it’s the most efficient!
  • Uninstall unused applications
    This will not only increase security, it will also increase your computers performance!
  • Use a good password
    Your name is not a good password. Neither is the one you’ve used for 10 years. Use a passphrase and change it every now and then. For example: ILoveEasySecurityActions! It’s easy to remember, it’s secure because of the length, the use of lower and uppercase, and it’s got special signs (!).


  • Anti-malware
    For filestores
  • Firewall
    All windows servers comes with built in firewalls. Leave them on, and also install a hardware firewall on your network to protect you.
  • Microsoft Update
  • Reduse the amount of admins
    The more people that have access, the more likely the server is to be exploited!
  • Uninstall unused applications
    SQL Servers should NOT run ANYTHING ELSE than SQL Server. Same goes to web-servers, DNS servers etc!

Guten Morgen, TGE!

I’m now in Bonn helping Jon Kristian to upgrade their PIMS (DocCtrl) to R3. It took some time to get our computers up and running, but it’s at least working perfect now 🙂


Now we’re up and running, and the new database is restored. I’ve started clean-ups (because they’re only going to have DocCtrl). Jon Kristian has got his introduction to CR3, and his first words about it was “WOW! Now I finally have something to brag about to the other consultant”. They’ve got a cool relationship. Always smiling and laughing.

My hotel doesn’t have internet, so I’m “forced” to get out and do stuff. It’s great to have Jon Kristian down here. He’s taking us around the city, to restaurants (remember; I LOVE FOOD), bars etc. I think I’ve found my new favorite beer. Not sure yet, but it’s really good. It’s called Gaffel Kölsch.
On Monday, I tasted some national food. 5-6 different sausages, among them blood-pudding. I love food made from blood. Or, actually, I love all food 🙂

We’ve looked at the old DocCtrl and compared it to the new one. We think it will be ok to convert it, but there’s going to be some weird looking import SPs. I’ve just started them, and I’m looking forward to get it all up and running!


This is a VERY IMPORTANT message for those of you that uses FTP and

All files OLDER THAN ONE WEEK will be deleted automatically. We are going to start this job this weekend. If there is anything you need on this server, please download it or notify me to take backup of it.

Files older than one week WILL BE deleted!


I’ve been asked by Johnny to have a webcast in the near future (probably Wednesday). It will be about tips and tricks in SQL Server. You got any suggestions to topics, something you’d like me to show you that you think might be valuable for others? Please let me know!

This is my list so far: (random order)

  • Backup and restore, also with point in time-restore
  • Shrinking log-files
  • Indenting
  • Query Optimizing
  • Looping recordsets
  • Making backup of a-objects
  • DT and CTE (Derived Tables and Common Table Expressions)
  • DMF and DMV (Dynamic Management Functions and Views)


Are you excited to get starting with CR3, but is tied up with old CR1 applications or similar? Now I’ve got the solution for you 🙂 You can start developing your own personal applications on a new server: TVS2PUBLIC
I’ve set up a database, and a service-site. When web3 is ready, you can use this server to host your personal sites. For example:
The only thing you need to do is start developing! 😀

If you are excited to start, just contact me and you’ll be ready to start within minutes!

News from Ølen

Now, almost a month after the release of R3 I think it’s time for news about the area I’m responsible for: the database
First, something even more important:

  • I’ve been elected to the leader of NNUG (Norwegian .NET User Group) Haugesund. Our first meeting is June 4th. Microsoft sends us their true database guru, Jon Jahren 🙂
  • Microsoft says that they will release a RC (release candidate) of SQL Server 2008 in the second quarter of 2008. That means, within a month! REALLY looking forward to it!

R3 Database

There’s mainly three differences between R2 and R3 databases.

  • R3 is much more clean (deleted MANY old SPs, views and tables, for example MSAccess, MSAccessCR2)
  • New namespaces
  • DDL trigger

New namespaces

  • Database – Used by the DDL-trigger
  • Security – Only stored procedures. Users_Create etc
  • WinClient – Used by CR3 and CR3 Reports

DDL Trigger
Data Definition Language. This triggers on CREATE, ALTER, DROP and similar. We log everything to the stbl_Database_% tables to have version-control of objects, keep track of who’s updated what etc.