Saturday, March 31, 2012

Do you want to save time while creating reports in excel?


If your excel report consists the repeated data in many/all the sheets, don’t think about the copy and paste method we have something very interesting alternative.

Legacy way: Copy the required field and paste in all other required sheets.

Friday, March 30, 2012

How do I change the file access permissions in UNIX


Every file has following attributes:
Ø  owner's user ID ( 16 bit integer )
Ø  owner's group ID ( 16 bit integer )
Ø  File access mode word
'r w x -r w x- r w x' 
(user permission-group permission-others permission)
r-read, w-write, x-execute
To change the access mode, we use chmod(filename,mode).


Run the UNIX script on server


I wrote one UNIX script which eventually runs for hours together, which does much functionality fetching the data from DB2 tables and formatting and again loading into another tables. If I run the script in my local system by connecting to the client secured network (VPN) , I can’t guarantee the complete execution of the script.

My friend Maddy suggested me to run the script on server using nohup command in UNIX; here how it is

nohup script.cmd “environment variables” >script.cmd.out 2>&1 &


Comparison of DOS and Unix command-line interfaces

The DOS (Disk Operating System) and Unix environment are looking same in appearance but there are many differences, here are the few.

such as to list the directories and sub directories and hidden directories available in a drive we use ls -lRa in UNIX and we use dir/p/od in DOS environment .

Wednesday, March 28, 2012

Scope of variables in UNIX

To restrict the scope of variables to the function which it requires, we use typeset without any options, here is the example how to use the typeset without any functions to achieve the desired result in complex and large programs.


#!/bin/ksh/ 

x=1 
y=2 
function myfun { 
x=3 
typeset y=4 
print "Inside function x is $x" 
print "Inside function y is $y" 
} 
myfun 
print "Outside function x is $x" 
print "Outside function y is $y" 
exit 0   

Tuesday, March 27, 2012

How to record excel editing's in word document

Some times we need to create a word document which replicates the excel worksheet, there no need to create a table again and fill the data in word document, just do the below 

  •  Copy the required portion in excel template.
  • Open word document and choose paste special option in the paste sub menu item.
  • Select the Paste link radio button and select Microsoft Excel Worksheet Object, then click OK.



Now your word document keep updating as excel template updates.

Wednesday, March 21, 2012

Banned things in the countries


China banned Google instead they are using  www.baidu.com.
UK banned plasma TV.
Australia banned Laser pointers.
Cubes banned cell phones (restricted usage)
US banned ipod
Greece banned Google street views.
Germany banned Galaxy Tab
UAE and Saudi Arabia banned black berry.
Pakistan banned Facebook.
Israel banned ipad.

Sunday, March 18, 2012

Checking Arguments in Unix

Script with one argument to execute the further commands


if [ $# -ne 1 ]
then
   echo "Write your comments"
   exit -1 # exit the script
fi

$# stands for the number of arguments, it is number.
In if command you can change ne (not equal) to other comparing operator according to the requirements.
lt = Less than.
gt = Greater than.
le = Less than or equal.
ge = Greater than or equal.
eq= Equals.

Saturday, March 17, 2012

keyboard short keys

Few Keyboard shot keys to make work easier.
Open the Run command and type the given command to get the result.

%allusersprofile%                      = shows all users profiles.
%programfiles%                        = opens program files menu.
control desktop                          = opens desktop properties box.
osk                                               = onscreen keyboard.
pbrush                                         = paint.
regedit                                        = registry editor.
taskmgr                                      = task manager.
timedate.cpl                               = opens calendar.
write                                            = wordpad.
utilman                                        = utility manager.
winver                                         = windows version.
appwiz.cpl                                 = opens add/remove folder.
shutdown                                   = shut downs the system.
excel                                          = Microsoft Excel (If Installed)
msaccess                                 = Microsoft Access (If Installed)
powerpnt                                  = Microsoft PowerPoint (If Installed)
winword                                    = Microsoft Word (If Installed)
notepad                                    = Notepad
wordpad                                   = WordPad
calc                                           = Calculator
mspaint                                    = Microsoft Paint 



What is shebang in unix

The very first line in any UNIX shell script is shebang, Why should?
In UNIX the script is in Parent shell and the calculations will be done in child shell, in UNIX each shell has its own way of writing style, The script which we have right in our hands may or may not in that format, to make sure the parent shell execute calculations in the right child shell , we use she bang.
#!/bin/ksh (for korn shell)

Career path

Career path after 10,Plus two and Graduation

Why do most of the manholes are in circular shape

There are many reasons,
-> Very easy to manufacture compare to other shapes.
-> If water is flowing over to it , then it is capable of redirecting the water into tank or canal itself.
-> While closing the cap of manhole, just lift the cap perpendicular to the earth and turn it diagonal and leave, certainly it will not go in, but in other shapes it is possible.  

Windows notepad as Dairy

Few simple steps to create Dairy using Windows Notepad.
1) Open notepad.
2) Type .LOG (only .LOG)
3) Save the file with any valid name.
4) Close it and open
here is your Dairy