Search This Blog

04 January 2015

Large Objects for Databases

I am developing an application. I got stuck with a situation how to save my pictures. I walked down to my manager, who is an OCP, and asked him what should I do with my images? Where should I save them for my application? He gave a nasty smile, and said, "Bhaskar, Just flow with the Blob!"
I love Oracle DB engine over others. Although, as a basic developer like me, even Access or Excel would work, but Oracle mesmerizes me.  For this application, I chose Oracle over other MS SQL Server. And now I'm even more enlightened with 2 new data types. BLOB and CLOB. Psst, these aren't restricted to just Oracle DB Engine.

Character Large Objects (CLOB)

CLOBs are the large limit character data type for DB. Their limit may vary for DB Engines, but it is said that they're having limit of about  2GB. CLOB is said to be a collection of character data. It is stored at a separate location and is often referenced in a table. Being a data of this much limit, operation may end up slow on performance. Different DBM systems have different mechanism to overcome the performance issue. But, I'm sure, not all the developers will be using this datatype during their career. Hope not me!

Binary Large Objects (BLOB)

BLOB is a collection of binary objects stored as a single entity. This can be used to save multimedia objects. One can save images or audio to the DB by using BLOB. Oracle says "A BLOB without specified length is defaulted to two gigabytes".
BLOB and CLOB have two more siblings in Oracle DB, NCLOB and BFILE

National Character Large Object (NCLOB)

Very Similar to CLOB, with just a difference that it stores UNICODE national character set data.


The BFILE datatype stores unstructured binary data in operating-system files outside the database. A BFILE column or attribute stores a file locator that points to an external file containing the data. The amount of BFILE data that can be stored is limited by the operating system. BFILEs are read only; you cannot modify them. They support only random (not sequential) reads, and they do not participate in transactions. 
I'll be trying BLOB on my application. It will be fun to store images to DB rather than keeping them on File Share.
Let's hope that all goes well with it.

24 June 2014

Windows Code Pages

Intergraph SP3D installation guide suggests Bi-lingual server setup with same Code Page characters. Why?

Code Page are character encoding in Operating System. Characters are identified by codes. Operating System understands characters in code (e.g. ASCII). For example, if I write 'BHASKAR' as string or 66 72 65 83 75 65 82 (which is ASCII decimal by the way), both of them would be same for OS.

These character encodings are defined in Code Pages of Operating System. Different OS has different Code Pages. Code Page 1252 and Code Page 1251 mentioned in SP3D Installation Guide are having different character codes. This may give up a funny result if the platforms for SP3D are shared.

Anyhow, Intergraph doesn't restrict OS usage. In such case, for any project having multi lingual possibility, just check code page of OS. If they match, go for it.

By the way, enjoy Football World Cup.

Till next post, Happy Smartplanting....

06 November 2013

RemoteApp Feature of Windows

Last week when I was travelling home for vacation, I met a person on Airport. He was from a reputed company (I would rather choose not to disclose his identity as I never took his permission). I was discussing about virtualization of applications. He told me that Windows itself has the capacity of doing so,

Enthusiastically I searched over internet for the possibility which I'm sharing here. Thought that this may be useful for people who like to explore.

To start with, I would like to present 2 major topics about RemoteApp:

What is RemoteApp

You can visualize the RemoteApp service similar to a CITRIX XenApp service. This service of Windows Server 2008 (or higher) gives the freedom to use an application installed on a server as a local installed application on client. One can connect to the server without actually logging in to the server (ofcourse with proper permission and configurations). For more details, you can visit Microsoft Portal.

Why use RemoteApp

RemoteApp has similar advantages as CITRIX (not all, but serves bare minimum). As a Smartplant Administrator, I see following advantages of using this features.

  • Managing applications at one server instead of each client. This will make life of administrators a lot easier.
  • Using multiple versions of same application without having headache of compatibility.
  • Management of environments would be a lot easier.
  • Upgrades will be easier and much quicker.
I would suggest to give it a shot. This may be useful for you. Let me know your experience as well.

Happy Smartplanting....

23 September 2013

ISO 15926 Symbology

ISO 15926 is a great effort in progress. When this succeeds, it will be a milestone in data integrity. I believe that we should prepare ourselves in order to have good understanding.

To start with, I chose understand the Symbols which is being used. You can get full specification and related stuff on ISO portal.

S. No.

ISO 15926-2 entity type

Symbols in grey refer to contextual graphs

Name of example instance

ISO 15926-2 Relationsip

ISO 15926-2 (ClassOf)ClassOfRelationsip

Name of ISO 15926-2 ((ClassOf)ClassOf)Relationsip

Attribute of ISO 15926-2 ((ClassOf)ClassOf)Relationsip

Serial Number of the list in template specification

Serial number of role in lowered template signature

Lowered template

Let's keep up with ISO 15926.

Happy Smartplanting...

10 September 2013

The concept of Data Binding

Recently I was referring S3D programming guide when I came across Early and Late Binding pages. Thought it would be fair enough to share knowledge about the topic with people who are unaware of the terms. Developers can skip the post.

.NET has many class libraries and features. An application built on .NET framework has to communicate to the data source. Data Binding provides the facility for the application and provides the relation with the data source.

As written in Wikipedia, 'Data Binding is the process which establishes a connection between UI and Business Logic'. A Data Binding has has typically 4 components:

  • Target Object for Binding
  • Target Property
  • Binding Source
  • Path of Binding source.
There are two types of Data Binding:

  • Early Binding - Also known as Static Binding. As soon as object is created, the method is called. Hence the compiler is aware of binding. The binding results are compiled in the program and is ready available.
  • Late Binding - Or Dynamic Binding. The object is created, but the method isn't assigned. The method is assigned at runtime. Advantage of late binding is that the COM doesn't need the compiler to reference the library that contains the object at compile time.

Till next post

Happy Smartplanting