Tuesday, March 5, 2013

GoogleAppengine Data Store Entity- Create, Retrieve, Updating, Deleting, Batch Operation Delete ENTITY in Bulk via the Administrative Console


Data objects in the App Engine Datastore are known as entities. An entity has one or more named properties, each of which can have one or more values. Entities of the same kind need not have the same properties, and an entity's values for a given property need not all be of the same data type. (If necessary, an application can establish and enforce such restrictions in its own data model.)
The Datastore supports a variety of data types for property values. These include, among others:
  • Integers
  • Floating-point numbers
  • Strings
  • Dates
  • Binary data
Each entity in the Datastore has a key that uniquely identifies it. The key consists of the following components:
  • The kind of the entity, which categorizes it for the purpose of Datastore queries
  • An identifier for the individual entity, which can be either
    • key name string
    • an integer numeric ID
  • An optional ancestor path locating the entity within the Datastore hierarchy
An application has access only to entities it has created itself; it can't access data belonging to other applications. It can fetch an individual entity from the Datastore using the entity's key, or it can retrieve one or more entities by issuing a query based on the entities' keys or property values.
The Python App Engine SDK includes a data modeling library for representing Datastore entities as instances of Python classes, and for storing and retrieving those instances in the Datastore. The Datastore itself does not enforce any restrictions on the structure of entities, such as whether a given property has a value of a particular type; this task is left to the application and the data modeling library.

Contents

  1. Kinds and Identifiers
  2. Ancestor Paths
  3. Transactions and Entity Groups
  4. Properties and Value Types
  5. Working with Entities
    1. Creating an Entity
    2. Retrieving an Entity
    3. Updating an Entity
    4. Deleting an Entity
    5. Batch Operations
    6. Deleting Entities in Bulk via the Administration Console
  6. Understanding Write Costs

Kinds and Identifiers

Each Datastore entity is of a particular kind, which categorizes the entity for the purpose of queries: for instance, a human resources application might represent each employee at a company with an entity of kind Employee. In the Python Datastore API, an entity's kind is determined by its model class, which you define in your application as a subclass of the data modeling library class db.Model. The name of the model class becomes the kind of the entities belonging to it. All kind names that begin with two underscores (__) are reserved and may not be used.
The following example creates an entity of kind Employee, populates its property values, and saves it to the Datastore:
import datetimefrom google.appengine.ext import db

class Employee(db.Model):
  first_name = db.StringProperty()
  last_name = db.StringProperty()
  hire_date = db.DateProperty()
  attended_hr_training = db.BooleanProperty()


employee = Employee(first_name='Antonio',
                    last_name='Salieri')

employee.hire_date = datetime.datetime.now().date()
employee.attended_hr_training = True

employee.put()
The Employee class declares four properties for the data model: first_namelast_namehire_date, and attended_hr_training. The Model superclass ensures that the attributes of Employee objects conform to this model: for example, an attempt to assign a string value to the hire_date attribute would result in a runtime error, since the data model for hire_date was declared as db.DateProperty.
In addition to a kind, each entity has an identifier, assigned when the entity is created. Because it is part of the entity's key, the identifier is associated permanently with the entity and cannot be changed. It can be assigned in either of two ways:
  • Your application can specify its own key name string for the entity.
  • You can have the Datastore automatically assign the entity an integer numeric ID.
Note: Instead of using key name strings or generating numeric IDs automatically, advanced applications may sometimes wish to assign their own numeric IDs manually to the entities they create. Be aware, however, that there is nothing to prevent the Datastore from assigning one of your manual numeric IDs to another entity. The only way to avoid such conflicts is to have your application obtain a block of IDs with the methods allocate_ids() or allocate_ids_async(). The Datastore's automatic ID generator will keep track of IDs that have been allocated with these methods and will avoid reusing them for another entity, so you can safely use such IDs without conflict.
To assign an entity a key name, provide the named argument key_name to the model class constructor when you create the entity:
# Create an entity with the key Employee:'asalieri'.
employee = Employee(key_name='asalieri')
To have the Datastore assign a numeric ID automatically, omit the key_name argument:
# Create an entity with a key such as Employee:8261.
employee = Employee()
Note: In addition to arguments such as key_name, the Model constructor accepts initial values for properties as keyword arguments. This makes it inconvenient to have a property named key_name. For more information, see Disallowed Property Names on the Model class page.

Ancestor Paths

Entities in the Datastore form a hierarchically structured space similar to the directory structure of a file system. When you create an entity, you can optionally designate another entity as its parent; the new entity is a child of the parent entity. An entity without a parent is a root entity. The association between an entity and its parent is permanent, and cannot be changed once the entity is created. The Datastore will never assign the same numeric ID to two entities with the same parent, or to two root entities (those without a parent).
An entity's parent, parent's parent, and so on recursively, are its ancestors; its children, children's children, and so on, are its descendants. An entity and its descendants are said to belong to the same entity group. The sequence of entities beginning with a root entity and proceeding from parent to child, leading to a given entity, constitute that entity's ancestor path. The complete key identifying the entity consists of a sequence of kind-identifier pairs specifying its ancestor path and terminating with those of the entity itself:
Person:GreatGrandpa / Person:Grandpa / Person:Dad / Person:Me
For a root entity, the ancestor path is empty and the key consists solely of the entity's own kind and identifier:
Person:GreatGrandpa
To designate an entity's parent, use the parent argument to the model class constructor when creating the child entity. The value of this argument can be the parent entity itself or its key; you can get the key by calling the parent entity's key() method. The following example creates an entity of kind Address and shows two ways of designating an Employee entity as its parent:
# Create Employee entity
employee = Employee()
employee.put()
# Set Employee as Address entity's parent directly...
address = Address(parent=employee)
# ...or using its key
e_key = employee.key()
address = Address(parent=e_key)
# Save Address entity to datastore
address.put()

Transactions and Entity Groups

Every attempt to create, update, or delete an entity takes place in the context of a transaction. A single transaction can include any number of such operations. To maintain the consistency of the data, the transaction ensures that all of the operations it contains are applied to the Datastore as a unit or, if any of the operations fails, that none of them are applied.
Note: If your application receives an exception when attempting to commit a transaction, it does not necessarily mean that the transaction has failed. It is possible to receive a TimeoutTransactionFailedError, or InternalError exception even when a transaction has been committed and will eventually be applied successfully. Whenever possible, structure your Datastore transactions so that the end result will be unaffected if the same transaction is applied more than once.
A single transaction can apply to multiple entities, so long as the entities are descended from a common ancestor. Such entities are said to belong to the same entity group.In designing your data model, you should determine which entities you need to be able to process in the same transaction. Then, when you create those entities, place them in the same entity group by declaring them with a common ancestor. This tells App Engine that the entities will be updated together, so it can store them in a way that supports transactions.

Properties and Value Types

The data values associated with an entity consist of one or more properties. Each property has a name and one or more values. A property can have values of more than one type, and two entities can have values of different types for the same property.
Tip: Properties with multiple values can be useful, for instance, when performing queries with equality filters: an entity satisfies the query if any of its values for a property matches the value specified in the filter. For more details on multiple-valued properties, including issues you should be aware of, see the Datastore Queries page.
The following value types are supported:
Value typePython type(s)Sort orderNotes
Integerint
long
Numeric64-bit integer, signed
Floating-point numberfloatNumeric64-bit double precision,
IEEE 754
BooleanboolFalse < True
Text string (short)str
unicode
Unicode
(str treated as ASCII)
Up to 500 Unicode characters
Text string (long)db.TextNoneUp to 1 megabyte

Not indexed
Byte string (short)db.ByteStringByte orderUp to 500 bytes
Byte string (long)db.BlobNoneUp to 1 megabyte

Not indexed
Date and timedatetime.date
datetime.time
datetime.datetime
Chronological
Geographical pointdb.GeoPtBy latitude,
then longitude
Postal addressdb.PostalAddressUnicode
Telephone numberdb.PhoneNumberUnicode
Email addressdb.EmailUnicode
Google Accounts userusers.UserEmail address
in Unicode order
Instant messaging handledb.IMUnicode
Linkdb.LinkUnicode
Categorydb.CategoryUnicode
Ratingdb.RatingNumeric
Datastore keydb.KeyBy path elements
(kind, identifier,
kind, identifier...)
Blobstore keyblobstore.BlobKeyByte order
NullNoneTypeNone
For text strings and unencoded binary data (byte strings), the Datastore supports two value types:
  • Short strings (up to 500 Unicode characters or bytes) are indexed and can be used in query filter conditions and sort orders.
  • Long strings (up to 1 megabyte) are not indexed and cannot be used in query filters and sort orders.
Note: The long byte string type is named Blob in the Datastore API. This type is unrelated to blobs as used in the Blobstore API.
For values of mixed types, the Datastore uses a deterministic ordering based on the internal representations:
  1. Null values
  2. Fixed-point numbers
    • Integers
    • Dates and times
    • Ratings
  3. Boolean values
  4. Byte strings (short)
  5. Unicode strings
    • Text strings (short)
    • Postal addresses
    • Telephone numbers
    • Email addresses
    • IM handles
    • Links
    • Categories
  6. Floating-point numbers
  7. Geographical points
  8. Google Accounts users
  9. Datastore keys
  10. Blobstore keys
Because long text strings and long byte strings are not indexed, they have no ordering defined.
Note: Integers and floating-point numbers are considered separate types in the Datastore. If an entity uses a mix of integers and floats for the same property, all integers will be sorted before all floats: for example,

  7 < 3.2

Working with Entities

Applications can use the Datastore API to create, retrieve, update, and delete entities. If the application knows the complete key for an entity (or can derive it from its parent key, kind, and identifier), it can use the key to operate directly on the entity. An application can also obtain an entity's key as a result of a Datastore query; see theDatastore Queries page for more information.

Creating an Entity

In Python, you create a new entity by constructing an instance of a model class, populating its properties if necessary, and calling its put() method to save it to the Datastore. You can specify the entity's key name by passing a key_name argument to the constructor:
employee = Employee(key_name='asalieri',
                    first_name='Antonio',
                    last_name='Salieri')

employee.hire_date = datetime.datetime.now().date()
employee.attended_hr_training = True

employee.put()
If you don't provide a key name, the Datastore will automatically generate a numeric ID for the entity's key:
employee = Employee(first_name='Antonio',
                    last_name='Salieri')

employee.hire_date = datetime.datetime.now().date()
employee.attended_hr_training = True

employee.put()

Retrieving an Entity

To retrieve an entity identified by a given key, pass the Key object as an argument to the db.get() function. You can generate the Key object using the class methodKey.from_path(). The complete path is a sequence of entities in the ancestor path, with each entity represented by its kind (a string) followed by its identifier (key name or numeric ID):
address_k = db.Key.from_path('Employee', 'asalieri', 'Address', 1)
address = db.get(address_k)
db.get() returns an instance of the appropriate model class. Be sure that you have imported the model class for the entity being retrieved.

Updating an Entity

To update an existing entity, modify the attributes of the object, then call its put() method. The object data overwrites the existing entity. The entire object is sent to the Datastore with every call to put().
Note: The Datastore API does not distinguish between creating a new entity and updating an existing one. If the object's key represents an entity that already exists, theput() method overwrites the existing entity. You can use a transaction to test whether an entity with a given key exists before creating one. See also theModel.get_or_insert() method.
Tip: To delete a property, delete the attribute from the Python object:
del address.postal_code
then save the object.

Deleting an Entity

Given an entity's key, you can delete the entity with the db.delete() function
address_k = db.Key.from_path('Employee', 'asalieri', 'Address', 1)
db.delete(address_k)
or by calling the entity's own delete() method:
employee_k = db.Key.from_path('Employee', 'asalieri')
employee = db.get(employee_k)
# ...

employee.delete()

Batch Operations

The db.put()db.get(), and db.delete() functions (and their asynchronous counterparts db.put_async()db.get_async(), and db.delete_async()) can accept a list argument to act on multiple entities in a single Datastore call:
# A batch put.
db.put([e1, e2, e3])
# A batch get.
entities = db.get([k1, k2, k3])
# A batch delete.
db.delete([k1, k2, k3])
Performing operations in batches does not affect the cost, regardless of the entity's size. A batch operation for two keys costs two reads, even if one of the keys did not exist. For example, it is more economical to do a keys-only query that retrieves 1000 keys, and then do a fetch on 500 of them, than to do a regular (not keys-only) query for all 1000 directly:
  1. Query returning 1000 keys + fetching 500 entities:
    1. $0.0000007 (base query cost) + $0.0001 (per-key query cost) + 0.00035 (entity fetch)
    2. = $0.0004507
  2. Fetching 1000 entities:
    1. $0.0000007 (base query cost) + $0.0007 (per-entity query cost)
    2. = $0.0007007
Note: A batch call to db.put() or db.delete() may succeed for some entities but not others. If it is important that the call succeed completely or fail completely, you must use a transaction, and all affected entities must be in the same entity group.

Deleting Entities in Bulk via the Administration Console

You can use the Datastore Admin tab of the Administration Console to delete all entities of a given kind, or all entities of all kinds, in the default namespace. To enable this feature, include the builtin handler datastore_admin in your app.yaml file:
builtins:
- datastore_admin: on
This enables the Datastore Admin screen in the Data section of the Administration Console. From this screen, you can select the entity kind(s) to delete individually or in bulk, and delete them using the Delete Entities button. Note that bulk deletion takes place within your application, and thus counts against your quota.
Caution: This feature is currently experimental. We believe it is the fastest way to bulk-delete data, but it is not yet stable and you may encounter occasional bugs.

Understanding Write Costs

When your application executes a Datastore put() operation, the Datastore must perform a number of writes to store the entity. Your application is charged for each of these writes. You can see how many writes will be required to store an entity by looking at the data viewer in the SDK Development Console. This section explains how App Engine calculates these values.
Every entity requires a minimum of two writes to store: one for the entity itself and another for the built-in EntitiesByKind index, which is used by the query planner to service a variety of queries. In addition, the Datastore maintains two other built-in indexes, EntitiesByProperty and EntitiesByPropertyDesc, which provide efficient scans of entities by single property values in ascending and descending order, respectively. Each of an entity's indexed property values must be written to each of these indexes.
As an example, consider an entity with properties A, B, and C:
Key: 'Foo:1' (kind = 'Foo', id = 1, no parent)
A: 1, 2
B: null
C: 'this', 'that', 'theOther'
Assuming there are no composite indexes (see below) for entities of this kind, this entity requires 14 writes to store:
  • 1 for the entity itself
  • 1 for the EntitiesByKind index
  • 4 for property A (2 for each of two values)
  • 2 for property B (a null value still needs to be written)
  • 6 for property C (2 for each of three values)
Composite indexes (those referring to multiple properties) require additional writes to maintain. Suppose you define the following composite index:
Kind: 'Foo'
A ▲, B ▼
where the triangles indicate the sort order for the specified properties: ascending for property A and descending for property B. Storing the entity defined above now takes an additional write to the composite index for every combination of A and B values:
  • (1null)
  • (2null)
This adds 2 writes for the composite index, for a total of 1 + 1 + 4 + 2 + 6 + 2 = 16. Now add property C to the index:
Kind: 'Foo'
A ▲, B ▼, C ▼
Storing the same entity now requires a write to the composite index for each possible combination of A, B, and C values:
  • (1null'this')
  • (1null'that')
  • (1null'theOther')

  • (2null'this')
  • (2null'that')
  • (2null'theOther')
This brings the total number of writes to 1 + 1 + 4 + 2 + 6 + 6 = 20.
If a Datastore contains many multiple-valued properties, or if a single such property is referenced many times, the number of writes required to maintain the index can explode combinatorially. Such exploding indexes can be very expensive to maintain. For example, consider a composite index that includes ancestors:
Kind: 'Foo'
A ▲, B ▼, C ▼
Ancestor: True 
Storing a simple entity with this index present takes the same number of writes as before. However, if the entity has ancestors, it requires a write for each possible combination of property values and ancestors, in addition to those for the entity itself. Thus an entity defined as
Key: 'GreatGrandpa:1/Grandpa:1/Dad:1/Foo:1' (kind = 'Foo', id = 1, parent = 'GreatGrandpa:1/Grandpa:1/Dad:1')
A: 1, 2
B: null
C: 'this', 'that', 'theOther'
would require a write to the composite index for each of the following combinations of properties and ancestors:
  • (1null'this''GreatGrandpa')
  • (1null'this''Grandpa')
  • (1null'this''Dad')
  • (1null'this''Foo')

  • (1null'that''GreatGrandpa')
  • (1null'that''Grandpa')
  • (1null'that''Dad')
  • (1null'that''Foo')

  • (1null'theOther''GreatGrandpa')
  • (1null'theOther''Grandpa')
  • (1null'theOther''Dad')
  • (1null'theOther''Foo')

  • (2null'this''GreatGrandpa')
  • (2null'this''Grandpa')
  • (2null'this''Dad')
  • (2null'this''Foo')

  • (2null'that''GreatGrandpa')
  • (2null'that''Grandpa')
  • (2null'that''Dad')
  • (2null'that''Foo')

  • (2null'theOther''GreatGrandpa')
  • (2null'theOther''Grandpa')
  • (2null'theOther''Dad')
  • (2null'theOther''Foo')
Storing this entity in the Datastore now requires 1 + 1 + 4 + 2 + 6 + 24 = 38 writes.

Thursday, February 28, 2013

How to Insert Equations & Formulas At using Open Office


How do you do that in OpenOffice?
The first step is to just go to the old reliable Insert menu. Anything out of the realm of plain text, just go to the Insert menu.
Just Using the Special Characters Window
Now, if you just want a Special Character, pi or lambda or something, you can choose Insert > Special Character.
Sc1_1
Find the one you want. If you select several you'll see them all displayed at the right side of the window and they'll all be inserted.
Then just click Insert. The character will show up.
Sc2
It's a pain to scroll through all that again and again so make an AutoText entry for it. See
Using the Formulas Features
If you need something more complex, then instead, choose Insert > Object > Formula.
You get an editing window at the bottom, a box for the equation in the document, and a little shortcut window floating off to the side.
F1
Now,  you can use the little shorcut window. Click an item above the line, then click an item below the line and that inserts some placeholder stuff for you in the editing window.
F3_1   

But frankly I find it not that helpful since just writing the formulas is reasonably easy once you memorize a few tips.
  • Use the Formula Reference Tables online help list to see how to enter formulas. Basically, do it how you think it would work. Use the OpenOffice.org Math Examples online  help list to see examples. These are really good. Just press F1 while you're in the editing window; you can type the titles of these topics into the Find or Index window.
  • Use ^ for exponents, as in 3^2  which would be three, squared.
  • Use sqrt for square root
  • Use % in front of the written version of a symbol, as in %pi
So here are a few formulas. They're pretty easy to figure out. Click each image to see a slightly larger version, if you like.
a + b / $pi
F3bdivides
a + b over $pi
F4
(a + b) over $pi
F5parens

If You Don't Know How to Write Out a Character Like %pi or %rho
Click the Sigma icon at the top to add a special character.
F6epsilon
You can just scroll  through and select something from the list, and insert it.
F8window
Or you can add something yourself if you don't see what you need.
Optional: Add your own symbol   
To add something you don't see, click Edit.
F8window
Find what you want, by scrolling and manipulating all the dropdowns. Then name it, and click Add, not Edit.
F9add
The new symbol will show up in the symbol list.
F10addshowsupinlist
Click in the document to stop editing the formula.
If you want to get back into the formula to change it, double-click the box the formula is in.
Formatting the Formula
All right. You've got a great formula. But it's really small. Or you'd like a different font. You change these by selecting the formula in the editing window and click on the Format menu.
F_formats_1
Choosing Fonts gives you this window. You get to choose the font by the type: variables, etc. Click and hold down on the Modify button to change any font.
F_12fonts2
Select the font in this window, then click OK all the way back out of the windows.
F_font15_1

That's About It
Insert > Object > Formula. Type what you want and use the online help and the brief tips I gave you.
Click in the document when you're done, and double-click the equation box to start editing again.
To format, select the text in the editing box and find the Format menu.
To add a symbol you don't know, click the Epsilon icon at the top of the window and select one--or click Edit to create your own.
Doing All This in Impress
I'm using 2.1 in February 2007 and it works just fine.
Click in a bulleted item and choose Insert > Object > Formula.
Inserting
You can also paste the formula object from Writer to Impress. Don't paste it into a bullet in this case; just paste it into a layout with no bullets.
Editinginimpress
Double-click to edit, as usual.
Insertinginimss
Double-click the formula object to get into edit mode. Use the Format menu or make other changes.
Formatmenu



Thursday, January 17, 2013

Unix - Useful Commands For Developer & User


This quick guide lists commands, including a syntax and brief description. For more detail, use:
$man command

Files and Directories:

These commands allow you to create directories and handle files.
CommandDescription
catDisplay File Contents
cdChanges Directory to dirname
chgrpchange file group
chmodChanging Permissions
cpCopy source file into destination
fileDetermine file type
findFind files
grepSearch files for regular expressions.
headDisplay first few lines of a file
lnCreate softlink on oldname
lsDisplay information about file type.
mkdirCreate a new directory dirname
moreDisplay data in paginated form.
mvMove (Rename) a oldname to newname.
pwdPrint current working directory.
rmRemove (Delete) filename
rmdirDelete an existing directory provided it is empty.
tailPrints last few lines in a file.
touchUpdate access and modification time of a file.

Manipulating data:

The contents of files can be compared and altered with the following commands.
CommandDescription
awkPattern scanning and processing language
cmpCompare the contents of two files
commCompare sorted data
cutCut out selected fields of each line of a file
diffDifferential file comparator
expandExpand tabs to spaces
joinJoin files on some common field
perlData manipulation language
sedStream text editor
sortSort file data
splitSplit file into smaller files
trTranslate characters
uniqReport repeated lines in a file
wcCount words, lines, and characters
viOpens vi text editor
vimOpens vim text editor
fmtSimple text formatter
spellCheck text for spelling error
ispellCheck text for spelling error
ispellCheck text for spelling error
emacsGNU project Emacs
ex, editLine editor
emacsGNU project Emacs
emacsGNU project Emacs

Compressed Files:

Files may be compressed to save space. Compressed files can be created and examined:
CommandDescription
compressCompress files
gunzipUncompress gzipped files
gzipGNU alternative compression method
uncompressUncompress files
unzipList, test and extract compressed files in a ZIP archive
zcatCat a compressed file
zcmpCompare compressed files
zdiffCompare compressed files
zmoreFile perusal filter for crt viewing of compressed text

Getting Information:

Various Unix manuals and documentation are available on-line. The following Shell commands give information:
CommandDescription
aproposLocate commands by keyword lookup
infoDisplays command information pages online
manDisplays manual pages online
whatisSearch the whatis database for complete words.
yelpGNOME help viewer

Network Communication:

These following commands are used to send and receive files from a local UNIX hosts to the remote host around the world.
CommandDescription
ftpFile transfer program
rcpRemote file copy
rloginRemote login to a UNIX host
rshRemote shell
tftpTrivial file transfer program
telnetMake terminal connection to another host
sshSecure shell terminal or command connection
scpSecure shell remote file copy
sftpsecure shell file transfer program
Some of these commands may be restricted at your computer for security reasons.

Messages between Users:

The UNIX systems support on-screen messages to other users and world-wide electronic mail:
CommandDescription
evolutionGUI mail handling tool on Linux
mailSimple send or read mail program
mesgPermit or deny messages
parcelSend files to another user
pineVdu-based mail utility
talkTalk to another user
writeWrite message to another user

Programming Utilities:

The following programming tools and languages are available based on what you have installed on your Unix.
CommandDescription
dbxSun debugger
gdbGNU debugger
makeMaintain program groups and compile programs.
nmPrint program's name list
sizePrint program's sizes
stripRemove symbol table and relocation bits
cbC program beautifier
ccANSI C compiler for Suns SPARC systems
ctraceC program debugger
gccGNU ANSI C Compiler
indentIndent and format C program source
bcInteractive arithmetic language processor
gclGNU Common Lisp
perlGeneral purpose language
phpWeb page embedded language
pyPython language interpreter
aspWeb page embedded language
CCC++ compiler for Suns SPARC systems
g++GNU C++ Compiler
javacJAVA compiler
appletvieweirJAVA applet viewer
netbeansJava integrated development environment on Linux
sqlplusRun the Oracle SQL interpreter
sqlldrRun the Oracle SQL data loader
mysqlRun the mysql SQL interpreter

Misc Commands:

These commands list or alter information about the system:
CommandDescription
chfnChange your finger information
chgrpChange the group ownership of a file
chownChange owner
datePrint the date
determinAutomatically find terminal type
duPrint amount of disk usage
echoEcho arguments to the standard options
exitQuit the system
fingerPrint information about logged-in users
groupaddCreate a user group
groupsShow group memberships
homequotaShow quota and file usage
iostatReport I/O statistics
killSend a signal to a process
lastShow last logins of users
logoutlog off UNIX
lunList user names or login ID
netstatShow network status
passwdChange user password
passwdChange your login password
printenvDisplay value of a shell variable
psDisplay the status of current processes
psPrint process status statistics
quota -vDisplay disk usage and limits
resetReset terminal mode
scriptKeep script of terminal session
scriptSave the output of a command or process
setenvSet environment variables
sttySet terminal options
timeTime a command
topDisplay all system processes
tsetSet terminal mode
ttyPrint current terminal name
umaskShow the permissions that are given to view files by default
unameDisplay name of the current system
uptimeGet the system up time
useraddCreate a user account
usersPrint names of logged in users
vmstatReport virtual memory statistics
wShow what logged in users are doing
whoList logged in users