InterviewQuestionsAns

Post on 24-Mar-2015

191 views 2 download

Transcript of InterviewQuestionsAns

DATASTAGE QUESTIONSASKED IN DIFFERENT INTERVIEWS

1. Could u tell me about the stage variables? Could u tell me, how u used it.?Stage variables are the intermediate processing variables in the transformation stage. They are used for holding the intermediate values in complex derivations in the transformation stage.

2. How do u eliminate the duplicates when u initial load into the transformer ,when the hash files are empty.?Duplicates are removes by the use of “Reject” in the constraints of transformation stage. Alternatively they can be eliminated by effective use of the hash files. 3.How is the order of execution done internally in the transformer with the stage editor having multiple input links on the left hand side and multiple output links ?Thru Link ordering page, in the transformer properties.

4.Did u write any routines ?Yes I did , I wrote the routines to know where exactly my job was getting aborted(at which row of my database)

6.Have u used aggregator stage?Yes I Did, I have used it to group data and to know exactly about how my total data behaves for certain groups ( I mean when I need to add the sum or Avg of a group of data to know the sales and billing)

7 How do u test the job ?Actually we have two ways of testing a job one is its Functional aspect and the other is the technical aspect. Actually functional aspect was mainly handled by one more teamThe errors and the other testing was done by me by the use of toggle-points and by looking at the Job log.

8. Did u write any routines using BASIC programming?Where exactly the job was aborting was tested by me by the use of Basic programming.

9. How would U track the performance statistics and enhance it?Performance statistics can be known when we look at the job properties and select the performance statistics option. You enhance it the following ways

1. Use of hash files for look ups ( referential and entity)2. Use of proper hash file designs 3. Use of Link partitions and Link Collectors in case MPPs and SMPs 4. Use of IPC5. Use of parallel extender6. Using the buffer cashing of hash files

13. Have u written any function or shell script and what was the purpose and logic.I have written shell scripts to concatenate two files (Environment was UNIX and the command I used was CAT)

15.Can u explain what a Project Life Cycle is and how did u implement it in ur last project.?Project life cycle normally has the following stages

1. Analysis 2. Logical design of the project 3. Physical design 4. Code 5. Testing 6. Maintenance

16.What was the target database used in the last project? Oracle

17. Do u know how to tune the Oracle or your target database especially the SQL tuning?Actually tuning was done by our DBAI use to optimize the queries for the better performance, using the query analyzer

Last Interview:1) How many source files and how many target files, Source ---- 9Target -----3

2) What were the formats of source files? How did u receive the source files? And what was the frequency? Daily or weekly or quarterly?

Depending upon the project

3) How many jobs and transformations were used.Say 80+ jobs if project is for 1 year + Transformations a min of 200 – 300

4) What are job parameters? This the run time options which we can give for a job

5) How do u schedule a job?By the use of Job scheduler where in we can set the time when the job has to run

6) How will u pass the parameter to the job schedule if the job is running at night?

7) What happens if one job fails in the night?

8) How will u pass the file name as the parameter for a job?9) How will u run data stage from Unix? What’s the command?

Dsjob – status –project name – job name

10) How did u populate the source files?

11) If there r million of records, did u use OCI? If yes then why?Yes bcoz OCI stage is three times faster when compares to other stages

12) Why did u use SQL Loader or OCI stage and why?.Bcoz it is faster

13) Diff. Bet. The package and procedure and advantage of using packagePackage will be like a classProcedure is a like a method of a class

14) Unix command to find a particular pattern in a file?Grep

15) Unix command to combine two filesCat

TEST1

1) Explain any five transformations used?

These are some of the transformations used by us1. Date Transforms2. Key Management transforms3. We defined some local stage variable. This is also a transformation4. Moved columns from one link to other5. created output column derivations

2) Explain any five functions used in transforms

functions used:

1. Rand: Return a psuedo random integer between 0 and 232-12. IsNull: Returns true when an expression evaluates to the null value

3. KeyMgtGetNextValue: Used for generating the surrogate id

4. DateGenericToODBC: Used to convert the format compatible to ODBC date

5. MeasureTimeDaysToSeconds: Convert time in days to seconds

Krishna karthik DesaiDATASTAGE

3)What is Snowflakes Schema. Explain with a fig?

Snowflake schema is an extension of star schema. Each dimension radiatesinto one more dimension. It is slightly normalized. Snow flaking is removing low-cardinality textual attributes from dimension tables and placing them in Secondary Dimension tables

The following is Snow-Flaked view of Student Fact table

The above diagram is Snowflaked because the Dimension tables are also connected

4) Explain the difference between OLTP data and DW data with reference to users

OLTP data is usually volatile and DW is non- volatile.

5) Inter row buffering

Inter row buffering can be selected in DataStage Administrator stage Click on ProjectsClick on PropertiesClick on TunablesAnd the option of inter row Buffering can be selected

6.Can we link tow active stages.

Yes we can link tow active stagesEg: We linked Aggregator stage to the transformer stage

7) What is the waiting period in the inter-row Buffering ?

STUDENT MATRICULATION DIMESION

STUDENT FACT

STUDENT BIODEMO DIMENSION

TIME DIMENSION

TERMDIMENSION

INSTITUTION DIMENSION

The connection between a DataStage client and the server times out after 86400 seconds (24 hours) of inactivity. To change this we normally set it in Administrator stage , Projects, Properties, tunables, Inter-row buffering and change the timeout period.

This Time when the Client is connected to the server is called Waiting period in the inter-row Buffering

8) How do you handle rejected by ODBC?

We handle rejected in ODBC by putting a constraint , this is just say “ REJECTED” for rejected ones and check the box of reject row for the non-rejected ones.

9) What is link ordering? The Transformer stage allows you to specify the execution order of links coming into and going at from the stage. This is called link ordering.

Link ordering can be done in two ways. One is by going to the properties stage of the transformer or any active stage and the other is specifying the execution order at the link itself for both input and output order.

10) What are stage variables?

Stage variables are the variables used in the transformation stage. This variable can be used in the transform and can be assigned a value at the run time for processing.

11) Give the reasons for selecting an alternative between fact table with more dimensions and Fact with fewer dimensions and the HierarchiesI prefer Fact table with more dimensions to Fact table with fewer Dimensions and the Hierarchies. The reason for this is the Complexity involved in the approach.is it makes the presentation to the user more complex and more intricate, less intuitive.

12) Disadvantages of High granularity

It takes more time and space for querying

13) Disadvantages of low granularity

High level details may not be present if we use low granularity

14) Advantages of high granularityHigh granularity implies that the level of details is more which is obviously an advantage for making the decisions

15) Advantages of low granularity

the time and space required for querying is reduced which makes the system more faster

16) What is Dual granularity?

You can implement a dual level of granularity by storing data at both high and low levels of granularity, that is, at both summarized and detailed levels. 

17) What does a sequencer do in job sequences?

DataStage provides a graphical Job Sequencer which allows you to specify a sequence of server or parallel jobs to run.

18) What is the use of Job Parameters?Job parameters are the parameters which are given to the application at the run time. Basically job parameters are useful when we want to run the job in our absence.

19) Name two before and after Job sub-routines?

Before: ExecDOS, DsWaitForFileAFTER: DSJobreport, ExecTCL

20) What is the percentage and the count with reference to performance statistics?

Count is the number of times the particular stage was executed Percentage is the percentage of the time the particular process has taken till the completion of the Job

21) How do you Differentiate between a I/O bottle neck and CPU bottleneck

If the Minimum = Average in the Performance parameters then it is CPU bound job If the Minimum != Average in the Performance parameters then it is I/O bound job

22) How do you test a Job?

There are many ways to test a job 1. Check the log after completing for the technicality of the job2. View data at each stage of the Job 3. give the test inputs and check for the outputs for the functionality of the job

23) Can we use a Sequential file for a look up ?

Yes we can use a Sequential file for a lookup

24) How do you propagate columns

When we right Click on an active stage we get propagate column as an option and from then we can propagate the columns to any other link which are connected to that particular stage.

25) Differentiate between shared and local container

A container is a group of stages and links. Containers enable you to simplify and modularize your server job designs by replacing complex areas of the diagram with a single container stage.

Local containers. These are created within a job and are only accessible by that job. A local container is edited in a tabbed page of the job’s Diagram window.

Shared containers. These are created separately and are stored in the Repository in the same way that jobs are. These are aceessible to any job. You can also use shared containers as a way of incorporating server job functionality into parallel jobs.

There are two types of shared container:

Server shared container. Used in server jobs (can also be used in parallel jobs). Parallel shared container Used in parallel jobs.

You can also include server shared containers in parallel jobs as a way of incorporating server job functionality into a parallel stage (for example, you could use one to make a server plug-in stage available to a parallel job).

Questions on DW

1.Tell me about Star flake schema and Snow fake Schema ,?2.Have u done data modeling,have u involved in the design or updated the existing design?3.have you created the datamarts?4.have you heard about Shared containers?5.have u used the DS Adminstartor?6.Could you tell me ,why the hash files are used?7.have you worked on Parallel Extender?8.Have u written any code for DS routines using Basic programming…?9.Have u written SQLs ? procedures ?10. what was the Source and target Databases used in your projects ?11 which versions of DS u have worked on?12. Are you familiar with SQL Server ,DB2

.Could u tell me about the stage variables, how do u use it,

They r local variables used in the transformer stage. They r used to reduce the complexity of the expression, for reusability. They can b part of the expressions, as arguments to functions, for defining the output columns.

2.How do u eliminate the duplicates rows?By writing the SQL before the stage.By using the hash file stage (automatically eliminates duplicates) In parallel Jobs,Remove Duplicates Stage can be used to eliminate the duplicate rows.

3.What is the order of execution done internally in the transformer with the stage editor having input links on the left hand side and output links?

Using Link Ordering

4.Did u write any routines?yes. To check the existence of the file.Code :

OpenSeq Arg1 To AnsThen Ans = @TrueEnd Else Ans = @FalseEnd

5 If u have million records, how do u test that in unit testing ?So Lets take 1000 records.., by limiting the no of rows for the input stage, in the job run options ,test the data by viewing the data in that stage and run and compile the job. Using Sample Stage. 6. how do u do oracle 4 way inner join if there r 4 Oracle input files?Writing the SQL condition in the where clause

7.Have u written SQL Scripts?Yes. I have used the PL/SQL Stored Procedure. Before Jobs, In ODBC stage etc..

8.have u used aggregator stage?In summarizing the records after transformation stage.

9. How do u test the job? Using scheduler, autosys , check in checkout

10. How wud. U tracks the performance statistics and enhances it?

JOB RUN OPTION>Tracing (Select the particular stage)– Check the performance statistics and run the job. View Log (Performance statistics ) PCMA.

11.How will u call external function and subroutine from Data Stage?Datastage Manager> Import > External Table Definition

12.What r shared containers and how do u use it?Containers collections of stages and Links. It generally used to reduce the visual complexity.In Link Partition and link Collectors if u r using any transformation , u can keep those stages in a container . Reuse the container.Two types 1.Local containers 2. Shared ContainerShared Containers are reusable Stages; u can use them across the jobs or projects. Scenario: If we have a job processing daily sales and another job processing weekly sales which are in the same format. The processing stages that are common for both the jobs can be put in a share container. This share container will be used the daily and the weekly job.

13.Have u written any function or shell script and what was the purpose and logic.Yes I have written shell scripts. Scenario: If we have daily data, and we what to concatenate the daily files into a single file to be fed in the weekly job, then this can be done as – write a before job routine in shell script. This shell script will concatenate all the daily files into a single file. The shell script will be used as a before job subroutine in the job properties.

14.Which stage in a data warehouse DataStage is used for and how do u use it?

15.Can u explain what a Project Life Cycle is and how did u implement it in ur last project.???Analysis, Design, Development, Testing, Deployment, Production Support.

16.What was the target database used in the last project? ORACLE (Note: or any other database you are comfortable with)

17. Do u know how to tune the Oracle or ur target database especially the SQL tuning?Use Indexes on tables.Use Hints.For Oracle, use the following utilities – TKPROF, EXPLAIN PLAN, UTILBSTAT, UTILESTAT etc.Use SQL TRACE.Tune the SGA Memory and Data Dictionary Cache Memory.Use the materialized views.

18. What versions of the entire platform used in the project?Unix Sun SolarisWindows NT 4.0DataStage 7.0/6.0Oracle 9iSQL Server 7.0/6.5

16) How will u pass the parameter to the job sequence if the job is running at night?The Job sequence is scheduled for the night in the DataStage Director. When scheduling, the Datastage Director asks for the value of the job parameter to be supplied. This value is then used when the job sequence runs at the scheduled time.

17) What happens if one job fails in the night?If a job in the job sequence fails, the action given in the job sequence for that job for the failure will be taken e.g a failure notification will be sent to the system administrator.

Reset mode

18) How will u pass the file name as the parameter for a job?Using crontab, dsjob – p, in the job parameter the type will be selected as PATHNAME

19) How will u run data stage from Unix? What’s the command? You can start, stop, validate, and reset jobs using the –run option.

dsjob –run–mode NORMAL RESET VALIDATE –param name=value –warn n –rows n –wait –stop –jobstatus–userstatus-local

20) How do u run a datastage job or sequence from Unix.?Using dsjob –run –jobstatus –projectname –filename command

21) How will u pass the parameter to a job?Using Job paramnets at the run time 22) How did u get the source files? And in what format? We get source files by connecting it to the respective databases

23) How did u populate the source files?If it is the Oracle or any database u can connect to them directly

And if it is MS access file we can use ODBC stage for it

24) If there r million of records, did u use OCI? If yes then why?OCI stage makes it faster to load from the database

To connect to oracle database25) Why did u use SQL Loader or OCI stage and why.

Control file contains filename, file source, data file, and delimiter

26) How will u catch the bad rows from OCI stage? Reject link

27) How do u schedule a job and how will it run at particular time? Using Job Scheduler in the Job Director

28) Diff. Bet. The package and procedure and advantage of using package

29) Unix command to find a particular pattern in a file? Grep command will tell u abt the string we r searching for

30) Unix command to combine two filesCat is used for combining two files in Unix

31) What r XML files? And how do u read data from XML files and what stage to be used?

XML input stage can be used to read data from the XML files 32) Have u worked on automation of datastage jobs? If yes, then how did u do it?

points for parallel extender

1. a: brings the power of parallel processing. b: two types of parallel processing: b.1 pipeline parallelism (all the instances run simulteonously) b.2 partition parallelism(used for large quantities of data) partitioning the data into number of separate sets with each partition being handled by separate instance ofthe job stages

2. parallel processing environoments run on two architectures: a SMP (symmetric multiprocessing), in which some hardware resources may be shared among processors. The processors communicate via shared memory and have a single operating system.

b Cluster or MPP (massively parallel processing), also known as

shared-nothing, in which each processor has exclusive access to hardware resources. MPP systems are physically housed in the same box, whereas cluster systems can be physically dispersed. The processors each have their own operating system, and communicate via a high-speed network.

c so it may be harder to improve memory-limited jobs performance on SMP,bcos they share memory

3. DataStage learns about the shape and size of the system from the configuration file.job design need not be changed if platform is changed.The configuration file describes available processing power in terms of processing nodes. You can use the configuration file to set up nodepools and resource pools. A pool defines a group of related nodes or resources, and when you design a DataStage job you can specify that execution be confined to a particular pool.When you run a DataStage job, DataStage first reads the configuration file to determine the available system resources.You can define and edit the configuration file using the DataStage Manager.4. partition methods round robin;random;same;entire;hash by field;modulus;range;db2 Same is the fastest partitioning method. 5. Inside a DataStage parallel job, data is moved around in data sets. data sets can be landed as persistent data sets This is the most efficient way of moving data between linked jobs. Persistent data sets are stored in a series of files linked by a control file6. run time column propagation: if your job encounters extra columns that are not defined in the meta data when it actually runs, it will adopt these extra columns and propagate them through the rest of the job. You can also specify the meta data for a stage in a plain text file known as a schema file. partialschema means that you only need define column definitions for those columns that you are actually going to operate on. 7. If you have NLS enabled, parallel jobs support two types of underlying character data types: strings and ustrings. String data represents unmapped bytes, ustring data represents full Unicode (UTF-16) data. stages: File sets enable you to spread data across a set of files referenced by a single control file.

8. NLS Map Tab If you have NLS enabled on your system, some of your stages will have an NLS Map tab. This allows you to override the project default character set map for this stage, and in some cases, allows you to enable per-column mapping. When per-column mapping is enabled, you can override the character set map for particular columns (an NLS map field appears on the columns tab allowing you to do this). stages supporting the NLS map tab: • Sequential File • File Set

• Lookup File Set• External Source• External Target• DB2/UDB Enterprise (not per-column mapping)• Oracle Enterprise (not per-column mapping)

1.Could u tell me about the stage variables, how do u use it, could u tell me, how u used it.?2.How do u eliminate the duplicates when u initial load into the transformer, when the hash files are empty.?3.how is the order of execution done internally in the transformer with the stage editor having input links on the left hand side and output links ?4.Did u write any routines ?5 If u have million records, how do u test that in unit testing ?6.how do u do oracle 4 way inner join as input oracle ,transformer and output flat file ?7.Have u written SQL Scripts?8.have u used aggregator stage?9.how do u test the job ?10. How wud. U track the performance statistics and enhance it?11.How will u call external function and subroutine from Data Stage?12.What r shared containers and how do u use it?13.Have u written any function or shell script and what was the purpose and logic.14.Which stage in a data warehouse DataStage is used for and how do u use it?15.Can u explain what a Project Life Cycle is and how did u implement it in ur last project.???16.What was the target database used in the last project? 17. Do u know how to tune the Oracle or ur target database especially the SQL tuning?18. What versions of all the platform used?

Last Interview:33) How many source files and how many target files, 34) What were the formats of source files? How did u receive the source files? And

what was the frequency? Daily or weekly or quarterly?35) How many jobs and transformations were used.36) What r job parameters?

37) How do u schedule a job?38) How will u pass the parameter to the job schedule if the job is running at night.39) What happens if one job fails in the night.40) How will u pass the file name as the parameter for a job?41) How will u run data stage from Unix? What’s the command?42) How will u pass the parameter to a job?43) How did u get the source files? And in what format? 44) How did u populate the source files?45) If there r million of records, did u use OCI? If yes then why?46) Why did u use SQL Loader or OCI stage and why?.47) How will u catch the bad rows from OCI stage? 48) How do u schedule a job and how will it run at particular time?49) Diff. Bet. The package and procedure and advantage of using package50) Unix command to find a particular pattern in a file?51) Unix command to combine two files52) What r XML files? And how do u read data from XML files and what stage to be

used? 53) Have u worked on automation of datastage jobs?if yes, then how did u do it?

DATASTAGE QUESTIONSASKED IN DIFFERENT INTERVIEWS

1.Could u tell me about the stage variables,,how do u use it,could u tell me,how u used it.?2.How do u eliminate the duplicates when u initial load into the transformer,when the hash files are empty.?3.how is the order of execution done internally in the transformer with the stage editor having input links on the left hand side and outrput links ?4.Did u write any routines ?5 If u have million records,how do u test that in unit testing ?6.how do u do oracle 4 way inner join as input oracle ,transformer and output flat file ?7.Have u written SQL Scripts?8.have u used aggregator stage?9.how do u test the job ?

1.Could u tell me about the stage variables, and how u used it. ?2.How do u eliminate the duplicates when u initially load into the transformer, when the hash files are empty.?3.how is the order of execution done internally in the transformer with the stage editor having input links on the left hand side and output links on the right hand side?4.Did u write any routines using BASIC programming?5 If u have million records, how do u test that for unit testing ?6.how do u do oracle 4 way inner join as input oracle stage, transformer and output flat file stage ?7.Have u written SQL Scripts?8.have u used aggregator stage?

9.how do u test the job ?10. Are you available now ?11. where are you now ?12.what are delta transactions?,could u exaplain,how did u use it?

1.Could u tell me about the stage variables, how do u use it, could u tell me, how u used it.?2.How do u eliminate the duplicates when u initial load into the transformer, when the hash files are empty.?3.how is the order of execution done internally in the transformer with the stage editor having input links on the left hand side and output links ?4.Did u write any routines ?5 If u have million records, how do u test that in unit testing ?6.how do u do oracle 4 way inner join as input oracle ,transformer and output flat file ?7.Have u written SQL Scripts?8.have u used aggregator stage?9.how do u test the job ?10. How wud. U track the performance statistics and enhance it?11.How will u call external function and subroutine from Data Stage?12.What r shared containers and how do u use it?13.Have u written any function or shell script and what was the purpose and logic.14.Which stage in a data warehouse DataStage is used for and how do u use it?15.Can u explain what a Project Life Cycle is and how did u implement it in ur last project.???16.What was the target database used in the last project? 17. Do u know how to tune the Oracle or ur target database especially the SQL tuning?18. What versions of all the platform used?

Last Interview:54) How many source files and how many target files, 55) What were the formats of source files? How did u receive the source files? And

what was the frequency? Daily or weekly or quarterly?56) How many jobs and transformations were used.57) What r job parameters? 58) How do u schedule a job?59) How will u pass the parameter to the job schedule if the job is running at night.60) What happens if one job fails in the night.61) How will u pass the file name as the parameter for a job?62) How will u run data stage from Unix? What’s the command?63) How will u pass the parameter to a job?64) How did u get the source files? And in what format? 65) How did u populate the source files?66) If there r million of records, did u use OCI? If yes then why?67) Why did u use SQL Loader or OCI stage and why?.68) How will u catch the bad rows from OCI stage? 69) How do u schedule a job and how will it run at particular time?

70) Diff. Bet. The package and procedure and advantage of using package71) Unix command to find a particular pattern in a file?72) Unix command to combine two files73) What r XML files? And how do u read data from XML files and what stage to be

used? Have u worked on automation of datastage jobs?if yes, then how did u do it?

TEST1

1) Explain any five transformations used?

These are some of the transformations used by us6. Date Transforms7. Key Management transforms8. We defined some local stage variable. This is also a transformation9. Moved columns from one link to other10. created output column derivations

2) Explain any five functions used in transforms

functions used:

6. Rand: Return a psuedo random integer between 0 and 232-17. IsNull: Returns true when an expression evaluates to the null value

8. KeyMgtGetNextValue: Used for generating the surrogate id

9. DateGenericToODBC: Used to convert the format compatible to ODBC date

10. MeasureTimeDaysToSeconds: Convert time in days to seconds

3)What is Snowflakes Schema. Explain with a fig?

Snowflake schema is an extension of start schema. Each dimension radiatesinto one more dimension. It is slightly normalized. Snow flaking is removing low-cardinality textual attributes from dimension tables and placing them in Secondary Dimension tables

The following is Snow-Flaked view of Student Fact table

STUDENT MATRICULATION DIMESION

STUDENT FACT

TIME DIMENSION

TERMDIMENSION

Krishna karthik DesaiDATASTAGE

The above diagram is Snowflaked because the Dimension tables are also connected

4) Explain the difference between OLTP data and DW data with reference to users

OLTP data is usually volatile and DW is non- volatile.

5) Inter row buffering

Inter row buffering can be selected in DataStage Administrator stage Click on ProjectsClick on PropertiesClick on TunablesAnd the option of inter row Buffering can be selected

6.Can we link tow active stages.

Yes we can link tow active stagesEg: We linked Aggregator stage to the transformer stage

7) What is the waiting period in the inter-row Buffering ?

The connection between a DataStage client and the server times out after 86400 seconds (24 hours) of inactivity. To change this we normally set it in Administrator stage , Projects, Properties, tunables, Inter-row buffering and change the timeout period.

This Time when the Client is connected to the server is called Waiting period in the inter-row Buffering

8) How do you handle rejected by ODBC?

We handle rejected in ODBC by putting a constraint , this is just say “ REJECTED” for rejected ones and check the box of reject row for the non-rejected ones.

9) What is link ordering? The Transformer stage allows you to specify the execution order of links coming into and going at from the stage. This is called link ordering.

STUDENT BIODEMO DIMENSION

INSTITUTION DIMENSION

Link ordering can be done in two ways. One is by going to the properties stage of the transformer or any active stage and the other is specifying the execution order at the link itself for both input and output order.

10) What are stage variables?

Stage variables are the variables used in the transformation stage. This variable can be used in the transform and can be assigned a value at the run time for processing.

11) Give the reasons for selecting an alternative between fact table with more dimensions and Fact with fewer dimensions and the HierarchiesI prefer Fact table with more dimensions to Fact table with fewer Dimensions and the Hierarchies. The reason for this is the Complexity involved in the approach.is it makes the presentation to the user more complex and more intricate, less intuitive.

12) Disadvantages of High granularity

It takes more time and space for querying

13) Disadvantages of low granularity

High level details may not be present if we use low granularity

14) advantages of high granularityHigh granularity implies that the level of details is more which is obviously an advantage for making the decisions

15)advantages of low granularity

the time and space required for querying is reduced which makes the system more faster

16) What is Dual granularity?

You can implement a dual level of granularity by storing data at both high and low levels of granularity, that is, at both summarized and detailed levels. 

17) What does a sequencer do in job sequences?

DataStage provides a graphical Job Sequencer which allows you to specify a sequence of server or parallel jobs to run.

18) What is the use of Job Parameters?Job parameters are the parameters which are given to the application at the run time. Basically job parameters are useful when we want to run the job in our absence.

19) Name two before and after Job sub-routines?

Before: ExecDOS, DsWaitForFileAFTER: DSJobreport, ExecTCL

20) What is the percentage and the count with reference to performance statistics?

Count is the number of times the particular stage was executed Percentage is the percentage of the time the particular process has taken till the completion of the Job

21) How do you Differentiate between a I/O bottle neck and CPU bottleneck

If the Minimum = Average in the Performance parameters then it is CPU bound job If the Minimum != Average in the Performance parameters then it is I/O bound job

22) How do you test a Job?

There are many ways to test a job 4. Check the log after completing for the technicality of the job5. View data at each stage of the Job 6. give the test inputs and check for the outputs for the functionality of the job

23) Can we use a Sequential file for a look up ?

Yes we can use a Sequential file for a lookup

24) How do you propagate columns

When we right Click on an active stage we get propagate column as an option and from then we can propagate the columns to any other link which are connected to that particular stage.

25) Differentiate between shared and local container

A container is a group of stages and links. Containers enable you to simplify and modularize your server job designs by replacing complex areas of the diagram with a single container stage.

Local containers. These are created within a job and are only accessible by that job. A local container is edited in a tabbed page of the job’s Diagram window.

Shared containers. These are created separately and are stored in the Repository in the same way that jobs are. These are aceessible to any job. You can also use shared containers as a way of incorporating server job functionality into parallel jobs.

There are two types of shared container:

Server shared container. Used in server jobs (can also be used in parallel jobs). Parallel shared container Used in parallel jobs.

You can also include server shared containers in parallel jobs as a way of incorporating server job functionality into a parallel stage (for example, you could use one to make a server plug-in stage available to a parallel job).

Questions on DW

1.Tell me about Star flake schema and Snow fake Schema ,?2.Have u done data modeling,have u involved in the design or updated the existing design?3.have you created the datamarts?4.have you heard about Shared containers?5.have u used the DS Adminstartor?6.Could you tell me ,why the hash files are used?7.have you worked on Parallel Extender?8.Have u written any code for DS routines using Basic programming…?9.Have u written SQLs ? procedures ?10. what was the Source and target Databases used in your projects ?11 which versions of DS u have worked on?12. Are you familiar with SQL Server ,DB2

.Could u tell me about the stage variables, how do u use it, They r local variables used in the transformer stage. They r used to reduce the complexity of the expression, for reusability. They can b part of the expressions, as arguments to functions, for defining the output columns.

2.How do u eliminate the duplicates rows?By writing the SQL before the stage.By using the hash file stage (automatically eliminates duplicates) In parallel Jobs,Remove Duplicates Stage can be used to eliminate the duplicate rows.

3.What is the order of execution done internally in the transformer with the stage editor having input links on the left hand side and output links?

Using Link Ordering

4.Did u write any routines?yes. To check the existence of the file.Code : OpenSeq Arg1 To Ans

Then Ans = @TrueEnd Else Ans = @FalseEnd

5 If u have million records, how do u test that in unit testing ?So Lets take 1000 records.., by limiting the no of rows for the input stage, in the job run options ,test the data by viewing the data in that stage and run and compile the job. Usinf Sample Stage. 6.how do u do oracle 4 way inner join if there r 4 Oracle input files?Writing the SQL condition in the where clause

7.Have u written SQL Scripts?Yes. I have used the PL/SQL Stored Procedure. Before Jobs, In ODBC stage etc..

8.have u used aggregator stage?In summarizing the records after transformation stage.

9. How do u test the job? Using scheduler, autosys , check in checkout

10. How wud. U tracks the performance statistics and enhances it?JOB RUN OPTION>Tracing (Select the particular stage)– Check the performance statistics and run the job. View Log (Performance statistics ) PCMA.

11.How will u call external function and subroutine from Data Stage?Datastage Manager> Import > External Table Definition

12.What r shared containers and how do u use it?Containers collections of stages and Links. It generally used to reduce the visual complexity.In Link Partition and link Collectors if u r using any transformation , u can keep those stages in a container . Reuse the container.Two types 1.Local containers 2. Shared ContainerShared Containers are reusable Stages; u can use them across the jobs or projects. Scenario: If we have a job processing daily sales and another job processing weekly sales which are in the same format. The processing stages that are common for both the jobs can be put in a share container. This share container will be used the daily and the weekly job.

13.Have u written any function or shell script and what was the purpose and logic.Yes I have written shell scripts.

Scenario: If we have daily data, and we what to concatenate the daily files into a single file to be fed in the weekly job, then this can be done as – write a before job routine in shell script. This shell script will concatenate all the daily files into a single file. The shell script will be used as a before job subroutine in the job properties.

14.Which stage in a data warehouse DataStage is used for and how do u use it?

15.Can u explain what a Project Life Cycle is and how did u implement it in ur last project.???Analysis, Design, Development, Testing, Deployment, Production Support.

16.What was the target database used in the last project? ORACLE (Note: or any other database you are comfortable with)

17. Do u know how to tune the Oracle or ur target database especially the SQL tuning?Use Indexes on tables.Use Hints.For Oracle, use the following utilities – TKPROF, EXPLAIN PLAN, UTILBSTAT, UTILESTAT etc.Use SQL TRACE.Tune the SGA Memory and Data Dictionary Cache Memory.Use the materialized views.

18. What versions of the entire platform used in the project?Unix Sun SolarisWindows NT 4.0DataStage 7.0/6.0Oracle 9iSQL Server 7.0/6.5

Last Interview with American Re:74) How many source files and how many target files?

75) What were the formats of source files? How did u receive the source files? And what was the frequency? Daily or weekly or quarterly?

76) How many jobs and transformations were used.?77) What r job parameters? Job parameters are the values for the parameters defined which are supplied for a job at run time.

78) How do u schedule a job?A DataStage job is scheduled in DataStage Director.

Can be done using crontab, shell scripting 79) How will u pass the parameter to the job sequence if the job is running at night?The Job sequence is scheduled for the night in the DataStage Director. When scheduling, the Datastage Director asks for the value of the job parameter to be supplied. This value is then used when the job sequence runs at the scheduled time.

80) What happens if one job fails in the night?If a job in the job sequence fails, the action given in the job sequence for that job for the failure will be taken e.g a failure notification will be sent to the system administrator.

Reset mode

81) How will u pass the file name as the parameter for a job?Using crontab, dsjob – p, in the job parameter the type will be selected as PATHNAME

82) How will u run data stage from Unix? What’s the command? You can start, stop, validate, and reset jobs using the –run option.

dsjob –run–mode NORMAL RESET VALIDATE –param name=value –warn n –rows n –wait –stop –jobstatus–userstatus-local

83) How do u run a datastage job or sequence from Unix.?Using dsjob –run –jobstatus –projectname –filename command

84) How will u pass the parameter to a job?Using Job paramnets at the rum time 85) How did u get the source files? And in what format? We get source files by connecting it to the respective databases

86) How did u populate the source files?If it is the Oracle or any database u can connect to them directly And if it is MS access file we can use ODBC stage for it

87) If there r million of records, did u use OCI? If yes then why?OCI stage makes it faster to load from the database

To connect to oracle database88) Why did u use SQL Loader or OCI stage and why.

Control file contains filename, file source, data file, and delimiter

89) How will u catch the bad rows from OCI stage? Reject link

90) How do u schedule a job and how will it run at particular time? Using Job Scheduler in the Job Director

91) Diff. Bet. The package and procedure and advantage of using package

92) Unix command to find a particular pattern in a file? Grep command will tell u abt the string we r searching for

93) Unix command to combine two filesCat is used for combining two files in Unix

94) What r XML files? And how do u read data from XML files and what stage to be used?

XML input stage can be used to read data from the XML files 95) Have u worked on automation of datastage jobs? If yes, then how did u do it?

1. What is the difficulty you faced with the most un-cooperative user and how did you resolve it?

a. One user was very unwilling to discuss the requirements and kept putting off meetings, saying that he was too busy.

b. I explained to him that his knowledge and input is very important to the success of the project, and arranged to meet him after working hours to discuss the requirements. He was more cooperative after that.

2. How do you go about gathering requirements?a. First I would meet with the department managers to identify the processes

within the department, the workflows within each process, and the roles / role players with each workflow. I would also gather details on how each department feeds/collects information to/from other departments.

b. Then I would arrange meetings with the key (more experienced) role players within the departments to fill out the requirement details with the help of questions (what/how/why) and Use Cases

3. Tell me about yourself.

a. Well __________, I have a Masters in Computer Science. I have over ten years experience as a Business Analyst, with 8 years financial experience. I am an expert at requirements gathering, analysis and documenting the requirements, and I have excellent inter-personal skills.

4. Why should we hire you?a. Well ___________, my skills and experience are an excellent fit for the

requirements. I have successfully completed projects doing requirements gathering and documenting requirements; and with my excellent inter-personal skills, I will be a valuable asset to your company.

5. What is the most difficult situation you faced, and how did you resolve it?a. In my last project, the users were taking a long time to start user

acceptance testing, because the department was extremely busy. I spoke to the manager and suggested that he could allow one key user to spend 1 to 2 hours each day testing with my supervision. He made the necessary arrangements, and we were able to get the first round of testing going, identifying defects and addressing them.

b. In the last project it was discovered that the Fund System that indirectly interfaced to the Bond System, was not handling the results of the sale transactions correctly. I reviewed the processing requirements for the Fund System with the senior developer, and I wrote a detailed specification of the interface process, discussed and handed over to the senior developer for the Fund System, and generated test data from the Bond System. The specs were used to modify the Fund System process, tested and implemented successfully.

c. In the last week of the project, it was discovered that some accounting entries were not being archived correctly for some transactions. We investigated the full extent of the problem, and wrote scripts to update the previous transactions and modified the stored procedures to correctly update new transactions. It took us three nights working late to thoroughly test and then implement the solution.

1. 1.How can you load orchestrate environment to your current directory?

By setting the environmental variable AP_ORCHHOME

2. What are orchadmin dump command options

PASS

3. What dsrecords do in orchestrate

Describe the Dataset description

4.   How can you delete a dataset in orchestrate ? and what happens if I use only

delete and dataset     name. As a standard we donot delete a Dataset

5. how can you copy a data set

Using the copy stage

6. how to describe a schema of a dataset in orchestrate?

Thru te schema files; for mostly the description of column, we can have partial schema def also7. what's the difference between truncate and delete in orchestrate?

Truncate and delete are the DB functions. A truncated table can be broughtback thru

DBA operations, while deleted one can never be restored

8. what is orchadmin check

to check statistics and metadata orchadmin diskinfo -p node pool

9. what is orchadmin describe -f filename

to check the statistics of a file

10. How can we generate error code and how can u find it?

By the transformer functions and written in to LOG files also

11. What kind of errors we found in running orchestrate?

Database related, OS related, Data type mismatch

12. Explain briefly what a surrogate key is?13.Surrogate Key is a Primary Key for a Dimension table. Most importance of using it is it is

independent of underlying database. i.e Surrogate Key is not affected by the changes going on with a database.

14. Why is egrep, fgrep, grep used in UNIX?

Egrep –search for particular pattern in file

Fgrep --- searches for input files

Grep: --- looks for the string in the files

15. What is the difference between a inner log and an outer log?

16. What is the difference between Star schema and Snowflake?

Star Schema - Simple & Much Faster.i. Demoralized form.

Snowflake Schema - Complex with more Granularity.1. More normalized form.

17. Explain briefly Partitioning Methods in Orchestrate.

Round robin, random, entire, same

18. Explain briefly the server components and client components in Data Stage?

Client Components

1.DataStage Designer

2.DataStage Director

3.DataStage Manager

4.DataStage Administrator

Server Components

1.Repository

2.DataStage Server

3.DataStage Package Installer

19. How do you change a file's permission in Unix?

chmod

20. How large were the tables?

85 columns about 20 million rows

21. As far as SQL/advanced SQL,

Extensive knowledge

22. Have you done project plans or scopes for project plans?  Explain

No

23. What has been your role in SW development?

Designing jobs, importing tables, testing ,debugging, performance tuning and (Q) I have a server job that is trying to build a HF for lookup purposes. It seems to slow down immensely as it progresses. The source file has approx. 1.2 mil records in it. I am using the type 30 dynamic hash file and the records being returned are 3 fields, 2 keys and the lookup value. The job starts out very fast but after 400k records it begins to slow and progressively slows to less than 700 records per sec. Any suggestions?

---Up the minimum modulus from 1. What you're probably seeing is the resize by doubling effect degrade performance. Checkout this post as well:

--Dynamic hashed files don't resize by doubling, they resize by adding one group (logically - probably about eight group buffers at a time physically). This actually gives you more pain, as you're taking the hit of restructuring every N records loaded, where N is the number of records per group.

if you create the hashed file with its minimum modulus set to approximately what you'll need at the end, you take the hit of allocating this disk space up front, so that the load should proceed more quickly and at non-diminishing rate.

Do you use write caching? This, too, can help load performance.

Another possibility, if your hashed file is large, is to use a static hashed file. This is one where the disk space is necessarily pre-allocated, and you get more control over the size of groups and the hashing algorithm used. Empirical evidence suggests that these perform slightly better than the equivalent dynamic hashed file for larger sizes; the downsize is that they require more calculation and more maintenance.

--Thanks for your input. I do not consider this hash file to be very large, around 65 Mb, approx 1.2 mil. records. I will try to use the write caching, right now, it takes around 30 minutes of wall clock time to build this.

How to delete or clear the hashfile from the command line?

The command used to delete a hashed file depends on the command that was used to create the hashed file, and whether a SETFILE command has been issued since. The command to clear the contents of a hashed file is CLEAR.FILE if issued from within the DataStage environment, or clearfile from the operating system. You can also use SQL within the DataStage environment (DELETE FROM hashedfile;) or the TCL command DELETE with an active Select List.

Can i increase the limit of hash file size cause after 2 GB my job get hanged and i couldn't procure desired result . I am giving a separate space to it specific for my application.

in general you can using the HFC unsupported utility get the syntax to manually create the file. you can't get it using the regular create option in the hash stage.

If the hashed file already exists, and is not corrupted, you can use the resize utility to

switch it to 64-bit addressing.

Use the following commands at the TCL prompt or in the Administrator client command

window.

Use SETFILE to create a VOC pointer to the hashed file. Code:

SETFILE pathname hashedfile OVERWRITING

The OVERWRITING keyword is optional.

Code:

RESIZE hashedfile * * * 64BIT

You will get a message indicating that the date/time stamp in the file header has been

modified. This message is terminated by an exclamation point (!) but really is just an

informative message. Don't worry about it.

Enough space for a second copy of the hashed file is required for this operation. If this

does not exist where the project or the hashed file reside, add a USING clause referring to

a directory where there is plenty of space (that is, at least as much as the hashed file

currently occupies). Code:

RESIZE hashedfile * * * 64BIT USING pathname

If the hashed file already exists, and is not corrupted, you can use the resize utility to

switch it to 64-bit addressing.

Use the following commands at the TCL prompt or in the Administrator client command

window.

Use SETFILE to create a VOC pointer to the hashed file. Code:

SETFILE pathname hashedfile OVERWRITING

The OVERWRITING keyword is optional.

Code:

RESIZE hashedfile * * * 64BIT

You will get a message indicating that the date/time stamp in the file header has been

modified. This message is terminated by an exclamation point (!) but really is just an

informative message. Don't worry about it.

Enough space for a second copy of the hashed file is required for this operation. If this

does not exist where the project or the hashed file reside, add a USING clause referring to

a directory where there is plenty of space (that is, at least as much as the hashed file

currently occupies). Code:

RESIZE hashedfile * * * 64BIT USING pathname

Hi! Ray

There is two entities created when i run my job for creating an hash file > 2 GB 1. D_H_CUST_SUM_ID - Directory 2. H_CUST_SUM_ID - File

now when i executed yur given code SETFILE /u50/PRODDSS/data2/ffamily/Hashfile H_CUST_SUM_ID OVERWRITING The command gives some warning. Secondly when i execute RESIZE H_CUST_SUM_ID* * * 64BIT The command gives an error as RESIZE : Invalid file name,sizing parameter, or option on command line .

Ascential has released 7.5 but I haven't been able to find anything about it on their web

site, devnet or e.services. Did find an article on dw-institute with a paragraph on new

features, it will be interesting to see the new job sequencer and the performance

visualisation and monitoring services:

Quote:

New features in the Suite include the addition of Mobile Services for RTI, through the incorporation of RTI Mobile Director, which enables the remote administration of DataStage from pocket PCs. Elsewhere, Ascential is touting new RTI clustering support for Oracle, DB2, and SQLServer databases. Enhancements include improved reporting across the Enterprise Integration Suite, a new job sequencer, real-time job validation, and performance visualization and monitoring interfaces. Ascential has also updated the Suite’s support for the HIPAA and EDIFACT standards to assist with compliance-related projects. Finally, the Ascential Enterprise Integration Suite 7.5 has been certified for Oracle 10g, Teradata V2R5.1, and SAP. Ascential will also make available a new packaged application connectivity kit for SAP XI with the revamped Suite.

Mobile Director progam has been created so we can work from airports, hotels, lunch breaks, between nines on the golf course. It will require Pocket PC 2000 OS, Pocket PC

2002 OS, or Windows Mobile for Pocket PC 2003 or higher; Microsoft .NET Compact Framework 1.0 SP2; and RTI 7.5

I am doing a lookup, the lookup conbines 3 keys. So how do I define the contraints?

What are your requirements? Do you only want to pass input rows that have valid

matches in all three lookup tables? Or something else? If all three, you could do

something like:

Code:

Not(Isnull(lu1.KeyField)) and Not(IsNull(lu2.Keyfield)) and Not(IsNull(lu3.Keyfield))

There is a useful feature in the constraint screen where you can check the "reject" flag on a constraint and it automatically gets all rows that do not go down any other outputs. So instead of putting NOT(ISNULL.. down one constraint and ISNULL... down the second constraint you can just turn on the reject flag of that second constraint.

The only caveat to that is to understand that these would no longer be 'silent' rejects. With that check box marked, any rows that go down that link will be logged into the job's log with a warning and a total rejected records count. Sometimes that's a good

thing and sometimes that can be a bad thing.

As long as you understand that and the fact that output link ordering is very important when using 'true' reject rows, then you'll be fine.

Does anyone know of a way to modify the character used as a delimiter on the fly for a Sequential File Stage?

We are receiving over 80 files, but some are delimited by pipes, others by commas. We'd like to be able to use the same stage to process both file types.Yes, that is correct. 80 files have the same metadata, only difference is the delimeter.

Sorry that your first post generates this as an answer, but... no, can't be done.

Do all of your 80 files have the same metadata and the only difference is the delimiter? Seems like at best case you'd need 2 jobs to do the processing, at worst case - 80.

Alas, all you can do is make copies of the job design. As Craig said, the sequential file delimiter character is not able to be a job parameter. Indeed, none of the properties on the Format tab can be job parameters.

Another option might be to explore creating a perl, awk or nawk prejob filter that will convert your file delimiter to a predefined delimiter for your job.

If you choose the "Stage uses filter" checkbox then you can perform some sort of pre-processing and read directly from stdout. I've done this with other things, but not changing delimiters and I can't see that it would be much of problem to do.

Then you could have one job to process all different types of file delimiters as long as the files match for metadata and the predefined delimiter is not in the data of any of the files you will be processing.

I have 1 input file and 2 hash lookups. I want to direct records that have a 0 for account number into my reject file and the rest go to the next transformer. Rows are being written to the reject file and the next transformer, ie it puts them into both locations. For example, my log will indicate:

125179 rows read from inRecs 125177 rows read from CC_lkup 125179 rows read from cal_day_lkup 125177 rows written to outRecs 17537 rows written to badStg

I only want to process good records. I am using a constraint right now to avoid warning messages being issued. I use 2 stage variables and check to see if either = 0, if so, they go to badStg. Any thoughts?

Use a constraint expression on each output link.

For good rows, col1 <> 0 And col2 <> 0. For the rejects link, col1 = 0 Or col2 = 0.

I need to have 3 or more source files joined on a 20 byte key giving one target file with information from all 3. I found on the parallel side a function called join, reading in up to 60+ files and outputing up to 60+ files. On the Server side, which I have to use, I can only fid a function called Merge. The Merge only reads in 2 source files.

Does anyone know of a different function, or data merger I can use on the Server that will allow me to join 3 or more files to create one target?

How about your Operating System? UNIX can 'merge' files based on keys, from what I recall. You may be able to do something before job to get it ready for loading, perhaps even using the 'Filter' capability of the Sequential File stage instead of in a before job routine.

At worst case, use the Merge stage... twice.

If the keys are unique, another option would be to load the files into hash files and do the joins through a lookup.

Alas this can't be done in server jobs. The Merge stage reads two text files; it does not have the ability to be driven by two streams. That's just the way it's written.

The hashed file approach is likely to be the best if the keys are unique.

There are options in the UNIX sort command for merging multiple files. Read the man page on sort .

You might, otherwise, use ODBC driver for text files, and perform an SQL join. Performance will be horrible , particularly if the files are large.

Alas this can't be done in server jobs. The Merge stage reads two text files; it does not have the ability to be driven by two streams. That's just the way it's written.

Sure you can... it's just that it takes two jobs.

Good catch. It can't be done in a single server job using Merge stage.

Some time ago someone showed how to generate a single output row from a server job Transformer stage without having any input link. If someone's got this in their Favorites, or knows the technique, can you please post it here?

start your job with a transformer, put a Stage Variable (must even if not used) put the constraint on @OUTROWNUM = 1 for 1 row.

put anything in the derivation and take it any where

I use this when ever I need to send a user defined sql to any server, especially to invoke the switch between staging and prod tables.

How to insert parameters automatically for the jobs, in sequncer. Here I dont want to enter parameters manually, it should happen automatically. So do i have to design a job with that stores parameters in file ?

The sequence itself is a job and has parameters. Fill these in in the usual way, in the Parameters grid. Then, when you're loading parameters in a Job Activity, choose Insert Parameter to select the sequence's parameter reference. There is no "select all" for this functionality. If you can make a business case, log an enhancement request with Ascential.

It is a pain having to put the job parameters into sequence job stages each time, they really do need an automap or automatch button as frequently the sequence job parameters have the same name as the server jobs being called. One short cut is to upgrade to version 7.x and use the cut and paste. That way you set up the job parameters for just one server job and you can endlessly copy and paste that stage and change the job name leaving job paramters intact.

Check out Parameter Manager for DataStage. This gives you the ability to store global parameters and bulk load them into jobs and sequences when and where you will.

I wrote a routine that retrieves a parameter value from a file given the filename and parameter name. I add a routine stage to the Job Sequence job for each parameter that needs to be retrieved and set the parameter in the Job Activity stage to the return value of the appropriate routine stage. It's a little bulky to have a bunch of routine stages at the beginning of each sequencer job, but it seems to work well enough.

Here is another situation. I have created a Hashfile lookup in one of my mappings.

In the source master query, the following are the columns:

OLDCOLA, OLDCOLB, OLDCOLC, NEWCOLA, NEWCOLB, NEWCOLC, I was able to manage the OLD AND NEW VALUES BY APPLYING TRIGGERS AT THE DATABASE LEVEL

OLDCOLA AND NEWCOLA are the KEYS.

THE HASHFILE IS JOINED WITH THE SOURCE MASTER QUERY TO LOAD THE CODE VALUE FROM HASH FILE LOOKUP INTO MASTER TARGET TABLE.

NOW, FOR LOADING THE HISTORY TABLE I AM USING THE OLDCOLA, OLDCOLB AND OLDCOLC VALUES TO POPULATE HISTORY RECORDS.

QUESTION ?

CAN I USE THE SAME HASFILE AND JOIN THE SOURCE NEWCOLA, OLDCOLA to get the CODE VALUE for OLD AND NEW.

I know it can be done if I have multiple instances of same hash file. But, is it possible to apply coditions in one hashfile and get old and new CODE VALUES.

You can probably do what you want. What is in the hashed file(s), and which column is the key column? What information do you want to return from the hashed file? Without knowing these things it is impossible to give you an answer. Using a hashed file on a reference input link is almost the same as using any stage type, except that the only possible "join" is an equi-join on the hashed file key. If that key is not found, DataStage sets the value on every column to NULL (so it behaves like a left outer join; you can constraint the output of the Transformer stage so that keys

found and keys not found can be directed to different output links, or discarded, thereby mimicking an inner join).

1. Could you explain Cardinality and Optionality2. How do you resolve many-to-many relationships? What is the middle entity

called?3. Please explain referential integrity.4. Say you are using Erwin and you open up an entity and select one attribute to edit

it, tell me what are five things you would enter on that screen?5. Please explain super-types and sub-types.6. How would you go about doing reverse-engineering of a system to understand the

business?7. Tell me of an instance where you were involved in a project where the business

was re-inventing itself, and how did you go about it? Do you know XML? Do you know programming languages . How do you reject rows? Have you made output tables

How did you handle errors. I used Debugger and tracer. Fixedadministration.

o Can the reject link output be connected to transformer? We can give the reject link to transformer

o Can u turn inter-row process buffering for SMP or MPP?

o What is the stage, which is not in parallel?

Hash stage (link partitioner, link collector)

o Is transformer stage active or passive?

Active

o Can server jobs be run on parallel?

o How do u automate jobs from remote i.e when u want to run the jobs during night time.

Using crontab u can automate the scheduling of jobs

o How do u give unix commands from datastage.

Using the command: dsjob – run (look for DS development tool kit in server manual)

1. Which of the following statements is true about implicit cursors?

1. Implicit cursors are used for SQL statements that are not named. 2. Developers should use implicit cursors with great care. 3. Implicit cursors are used in cursor for loops to handle data processing. 4. Implicit cursors are no longer a feature in Oracle.

2. Which of the following is not a feature of a cursor FOR loop? 1. Record type declaration. 2. Opening and parsing of SQL statements. 3. Fetches records from cursor. 4. Requires exit condition to be defined.

3. A developer would like to use referential datatype declaration on a variable. The variable name is EMPLOYEE_LASTNAME, and the corresponding table and column is EMPLOYEE, and LNAME, respectively. How would the developer define this variable using referential datatypes?

1. Use employee.lname%type. 2. Use employee.lname%rowtype. 3. Look up datatype for EMPLOYEE column on LASTNAME table and use

that. 4. Declare it to be type LONG.

4. Which three of the following are implicit cursor attributes? 1. %found 2. %too_many_rows 3. %notfound 4. %rowcount 5. %rowtype

5. If left out, which of the following would cause an infinite loop to occur in a simple loop?

1. LOOP 2. END LOOP 3. IF-THEN 4. EXIT

6. Which line in the following statement will produce an error? 1. cursor action_cursor is 2. select name, rate, action 3. into action_record 4. from action_table; 5. There are no errors in this statement.

7. The command used to open a CURSOR FOR loop is 1. open 2. fetch

3. parse 4. None, cursor for loops handle cursor opening implicitly.

8. What happens when rows are found using a FETCH statement 1. It causes the cursor to close 2. It causes the cursor to open 3. It loads the current row values into variables 4. It creates the variables to hold the current row values

9. Read the following code:10. CREATE OR REPLACE PROCEDURE find_cpt11. (v_movie_id {Argument Mode} NUMBER,

v_cost_per_ticket {argument mode} NUMBER)12. IS13. BEGIN14. IF v_cost_per_ticket > 8.5 THEN15. SELECT cost_per_ticket16. INTO v_cost_per_ticket17. FROM gross_receipt18. WHERE movie_id = v_movie_id;19. END IF;20. END;

Which mode should be used for V_COST_PER_TICKET?

1. IN 2. OUT 3. RETURN 4. IN OUT

21. Read the following code:22. CREATE OR REPLACE TRIGGER update_show_gross23. {trigger information}24. BEGIN25. {additional code}26. END;

The trigger code should only execute when the column, COST_PER_TICKET, is greater than $3. Which trigger information will you add?

1. WHEN (new.cost_per_ticket > 3.75) 2. WHEN (:new.cost_per_ticket > 3.75 3. WHERE (new.cost_per_ticket > 3.75) 4. WHERE (:new.cost_per_ticket > 3.75)

27. What is the maximum number of handlers processed before the PL/SQL block is exited when an exception occurs?

1. Only one 2. All that apply 3. All referenced 4. None

28. For which trigger timing can you reference the NEW and OLD qualifiers? 1. Statement and Row

2. Statement only 3. Row only 4. Oracle Forms trigger

29. Read the following code:30. CREATE OR REPLACE FUNCTION get_budget(v_studio_id

IN NUMBER)RETURN number IS

v_yearly_budget NUMBER;

BEGIN SELECT yearly_budget INTO v_yearly_budget FROM studio WHERE id = v_studio_id;

RETURN v_yearly_budget;END;

Which set of statements will successfully invoke this function within SQL*Plus?

1. VARIABLE g_yearly_budget NUMBEREXECUTE g_yearly_budget := GET_BUDGET(11);

2. VARIABLE g_yearly_budget NUMBEREXECUTE :g_yearly_budget := GET_BUDGET(11);

3. VARIABLE :g_yearly_budget NUMBEREXECUTE :g_yearly_budget := GET_BUDGET(11);

4. VARIABLE g_yearly_budget NUMBER:g_yearly_budget := GET_BUDGET(11);

31. CREATE OR REPLACE PROCEDURE update_theater32. (v_name IN VARCHAR v_theater_id IN NUMBER) IS33. BEGIN34. UPDATE theater35. SET name = v_name36. WHERE id = v_theater_id;37. END update_theater;

38. When invoking this procedure, you encounter the error:

ORA-000: Unique constraint(SCOTT.THEATER_NAME_UK) violated.

How should you modify the function to handle this error?

1. An user defined exception must be declared and associated with the error code and handled in the EXCEPTION section.

2. Handle the error in EXCEPTION section by referencing the error code directly.

3. Handle the error in the EXCEPTION section by referencing the UNIQUE_ERROR predefined exception.

4. Check for success by checking the value of SQL%FOUND immediately after the UPDATE statement.

39. Read the following code:40. CREATE OR REPLACE PROCEDURE calculate_budget IS41. v_budget studio.yearly_budget%TYPE;42. BEGIN43. v_budget := get_budget(11);44. IF v_budget < 3000045. THEN46. set_budget(11,30000000);47. END IF;48. END;

You are about to add an argument to CALCULATE_BUDGET. What effect will this have?

1. The GET_BUDGET function will be marked invalid and must be recompiled before the next execution.

2. The SET_BUDGET function will be marked invalid and must be recompiled before the next execution.

3. Only the CALCULATE_BUDGET procedure needs to be recompiled. 4. All three procedures are marked invalid and must be recompiled.

49. Which procedure can be used to create a customized error message? 1. RAISE_ERROR 2. SQLERRM 3. RAISE_APPLICATION_ERROR 4. RAISE_SERVER_ERROR

50. The CHECK_THEATER trigger of the THEATER table has been disabled. Which command can you issue to enable this trigger?

1. ALTER TRIGGER check_theater ENABLE; 2. ENABLE TRIGGER check_theater; 3. ALTER TABLE check_theater ENABLE check_theater; 4. ENABLE check_theater;

51. Examine this database trigger52. CREATE OR REPLACE TRIGGER

prevent_gross_modification53. {additional trigger information}54. BEGIN55. IF TO_CHAR(sysdate, DY) = MON56. THEN57. RAISE_APPLICATION_ERROR(-20000,Gross

receipts cannot be deleted on Monday);58. END IF;59. END;

This trigger must fire before each DELETE of the GROSS_RECEIPT table. It should fire only once for the entire DELETE statement. What additional information must you add?

1. BEFORE DELETE ON gross_receipt 2. AFTER DELETE ON gross_receipt 3. BEFORE (gross_receipt DELETE) 4. FOR EACH ROW DELETED FROM gross_receipt

60. Examine this function:61. CREATE OR REPLACE FUNCTION set_budget62. (v_studio_id IN NUMBER, v_new_budget IN NUMBER) IS63. BEGIN64. UPDATE studio65. SET yearly_budget =

v_new_budget WHERE id = v_studio_id;

IF SQL%FOUND THEN RETURN TRUEl; ELSE RETURN FALSE; END IF;

COMMIT;END;

Which code must be added to successfully compile this function?

1. Add RETURN right before the IS keyword. 2. Add RETURN number right before the IS keyword. 3. Add RETURN boolean right after the IS keyword. 4. Add RETURN boolean right before the IS keyword.

66. Under which circumstance must you recompile the package body after recompiling the package specification?

1. Altering the argument list of one of the package constructs 2. Any change made to one of the package constructs 3. Any SQL statement change made to one of the package constructs 4. Removing a local variable from the DECLARE section of one of the

package constructs 67. Procedure and Functions are explicitly executed. This is different from a

database trigger. When is a database trigger executed? 1. When the transaction is committed 2. During the data manipulation statement 3. When an Oracle supplied package references the trigger 4. During a data manipulation statement and when the transaction is

committed 68. Which Oracle supplied package can you use to output values and messages

from database triggers, stored procedures and functions within SQL*Plus? 1. DBMS_DISPLAY 2. DBMS_OUTPUT 3. DBMS_LIST 4. DBMS_DESCRIBE

69. What occurs if a procedure or function terminates with failure without being handled?

1. Any DML statements issued by the construct are still pending and can be committed or rolled back.

2. Any DML statements issued by the construct are committed 3. Unless a GOTO statement is used to continue processing within the

BEGIN section, the construct terminates. 4. The construct rolls back any DML statements issued and returns the

unhandled exception to the calling environment. 70. Examine this code

71. BEGIN72. theater_pck.v_total_seats_sold_overall :=

theater_pck.get_total_for_year;73. END;

For this code to be successful, what must be true?

1. Both the V_TOTAL_SEATS_SOLD_OVERALL variable and the GET_TOTAL_FOR_YEAR function must exist only in the body of the THEATER_PCK package.

2. Only the GET_TOTAL_FOR_YEAR variable must exist in the specification of the THEATER_PCK package.

3. Only the V_TOTAL_SEATS_SOLD_OVERALL variable must exist in the specification of the THEATER_PCK package.

4. Both the V_TOTAL_SEATS_SOLD_OVERALL variable and the GET_TOTAL_FOR_YEAR function must exist in the specification of the THEATER_PCK package.

74. A stored function must return a value based on conditions that are determined at runtime. Therefore, the SELECT statement cannot be hard-coded and must be created dynamically when the function is executed. Which Oracle supplied package will enable this feature?

1. DBMS_DDL 2. DBMS_DML 3. DBMS_SYN 4. DBMS_SQL

1. 1.12.23.14.(1,3,4)5.26.37.48.29.210.(3,4)11.1

12.413.114.115.316.317.118.(1,4)19.420.321.422.223.424.325.4

SQL INTERVIEW QUESTIONS:

1. Which of the following statements contains an error?1. SELECT * FROM emp WHERE empid = 493945; 2. SELECT empid FROM emp WHERE empid= 493945; 3. SELECT empid FROM emp; 4. SELECT empid WHERE empid = 56949 AND lastname = ‘SMITH’;

2. Which of the following correctly describes how to specify a column alias? 1. Place the alias at the beginning of the statement to describe the table. 2. Place the alias after each column, separated by white space, to describe the

column. 3. Place the alias after each column, separated by a comma, to describe the

column. 4. Place the alias at the end of the statement to describe the table.

3. The NVL function1. Assists in the distribution of output across multiple columns. 2. Allows the user to specify alternate output for non-null column values. 3. Allows the user to specify alternate output for null column values. 4. Nullifies the value of the column output.

4. Output from a table called PLAYS with two columns, PLAY_NAME and AUTHOR, is shown below. Which of the following SQL statements produced it?

PLAY_TABLE————————————-“Midsummer Night’s Dream", SHAKESPEARE“Waiting For Godot", BECKETT“The Glass Menagerie", WILLIAMS

1. SELECT play_name || author FROM plays;

2. SELECT play_name, author FROM plays; 3. SELECT play_name||’, ‘ || author FROM plays; 4. SELECT play_name||’, ‘ || author PLAY_TABLE FROM plays;

5. Issuing the DEFINE_EDITOR="emacs” will produce which outcome?1. The emacs editor will become the SQL*Plus default text editor. 2. The emacs editor will start running immediately. 3. The emacs editor will no longer be used by SQL*Plus as the default text

editor. 4. The emacs editor will be deleted from the system.

6. The user issues the following statement. What will be displayed if the EMPID selected is 60494?

SELECT DECODE(empid,38475, “Terminated",60494, “LOA", “ACTIVE")FROM emp;

1. 60494 2. LOA 3. Terminated 4. ACTIVE

7. SELECT (TO_CHAR(NVL(SQRT(59483), “INVALID")) FROM DUAL is a valid SQL statement.

1. TRUE 2. FALSE

8. The appropriate table to use when performing arithmetic calculations on values defined within the SELECT statement (not pulled from a table column) is

1. EMP 2. The table containing the column values 3. DUAL 4. An Oracle-defined table

9. Which of the following is not a group function?1. avg( ) 2. sqrt( ) 3. sum( ) 4. max( )

10. Once defined, how long will a variable remain so in SQL*Plus?1. Until the database is shut down 2. Until the instance is shut down 3. Until the statement completes 4. Until the session completes

11. The default character for specifying runtime variables in SELECT statements is

1. Ampersand 2. Ellipses 3. Quotation marks

4. Asterisk 12. A user is setting up a join operation between tables EMP and DEPT. There

are some employees in the EMP table that the user wants returned by the query, but the employees are not assigned to departments yet. Which SELECT statement is most appropriate for this user?

1. select e.empid, d.head from emp e, dept d; 2. select e.empid, d.head from emp e, dept d where e.dept# = d.dept#; 3. select e.empid, d.head from emp e, dept d where e.dept# = d.dept# (+); 4. select e.empid, d.head from emp e, dept d where e.dept# (+) = d.dept#;

13. Developer ANJU executes the following statement: CREATE TABLE animals AS SELECT * from MASTER.ANIMALS; What is the effect of this statement?

1. A table named ANIMALS will be created in the MASTER schema with the same data as the ANIMALS table owned by ANJU.

2. A table named ANJU will be created in the ANIMALS schema with the same data as the ANIMALS table owned by MASTER.

3. A table named ANIMALS will be created in the ANJU schema with the same data as the ANIMALS table owned by MASTER.

4. A table named MASTER will be created in the ANIMALS schema with the same data as the ANJU table owned by ANIMALS.

14. User JANKO would like to insert a row into the EMPLOYEE table, which has three columns: EMPID, LASTNAME, and SALARY. The user would like to enter data for EMPID 59694, LASTNAME Harris, but no salary. Which statement would work best?

1. INSERT INTO employee VALUES (59694,’HARRIS’, NULL); 2. INSERT INTO employee VALUES (59694,’HARRIS’); 3. INSERT INTO employee (EMPID, LASTNAME, SALARY) VALUES

(59694,’HARRIS’); 4. INSERT INTO employee (SELECT 59694 FROM ‘HARRIS’);

15. Which three of the following are valid database datatypes in Oracle? (Choose three.)

1. CHAR 2. VARCHAR2 3. BOOLEAN 4. NUMBER

16. Omitting the WHERE clause from a DELETE statement has which of the following effects?

1. The delete statement will fail because there are no records to delete. 2. The delete statement will prompt the user to enter criteria for the deletion 3. The delete statement will fail because of syntax error. 4. The delete statement will remove all records from the table.

17. Creating a foreign-key constraint between columns of two tables defined with two different datatypes will produce an error.

1. TRUE 2. FALSE

18. Dropping a table has which of the following effects on a nonunique index created for the table?

1. No effect. 2. The index will be dropped. 3. The index will be rendered invalid. 4. The index will contain NULL values.

19. To increase the number of nullable columns for a table,1. Use the alter table statement. 2. Ensure that all column values are NULL for all rows. 3. First increase the size of adjacent column datatypes, then add the column. 4. Add the column, populate the column, then add the NOT NULL

constraint. 20. Which line of the following statement will produce an error?

1. CREATE TABLE goods 2. (good_no NUMBER, 3. good_name VARCHAR2 check(good_name in (SELECT name FROM

avail_goods)), 4. CONSTRAINT pk_goods_01 5. PRIMARY KEY (goodno)); 6. There are no errors in this statement.

21. MAXVALUE is a valid parameter for sequence creation.1. TRUE 2. FALSE

22. Which of the following lines in the SELECT statement below contain an error?

1. SELECT DECODE(empid, 58385, “INACTIVE", “ACTIVE") empid 2. FROM emp 3. WHERE SUBSTR(lastname,1,1) > TO_NUMBER(’S') 4. AND empid > 02000 5. ORDER BY empid DESC, lastname ASC; 6. There are no errors in this statement.

23. Which function below can best be categorized as similar in function to an IF-THEN-ELSE statement?

1. SQRT 2. DECODE 3. NEW_TIME 4. ROWIDTOCHAR

24. Which two of the following orders are used in ORDER BY clauses? (choose two)

1. ABS 2. ASC 3. DESC 4. DISC

25. You query the database with this command

SELECT nameFROM employeeWHERE name LIKE ‘_a%’;

Which names are displayed?

1. Names starting with “a” 2. Names starting with “aR 3. or “A” 4. Names containing “aR 5. as second character 6. Names containing “aR 7. as any letter except the first

Database admin interview questions Database

1. What is a major difference between SQL Server 6.5 and 7.0 platform wise? SQL Server 6.5 runs only on Windows NT Server. SQL Server 7.0 runs on Windows NT Server, workstation and Windows 95/98.

2. Is SQL Server implemented as a service or an application? It is implemented as a service on Windows NT server and workstation and as an application on Windows 95/98.

3. What is the difference in Login Security Modes between v6.5 and 7.0? 7.0 doesn’t have Standard Mode, only Windows NT Integrated mode and Mixed mode that consists of both Windows NT Integrated and SQL Server authentication modes.

4. What is a traditional Network Library for SQL Servers? Named Pipes. 5. What is a default TCP/IP socket assigned for SQL Server? 1433 6. If you encounter this kind of an error message, what you need to look into to

solve this problem?

[Microsoft][ODBC SQL Server Driver][Named Pipes]Specified SQL Server not found.

1. Check if MS SQL Server service is running on the computer you are trying to log into

2. Check on Client Configuration utility. Client and Server have to in sync. 7. What is new philosophy for database devises for SQL Server 7.0? There are

no devises anymore in SQL Server 7.0. It is file system now. 8. When you create a database how is it stored? It is stored in two separate files:

one file contains the data, system tables, other database objects, the other file stores the transaction log.

9. Let’s assume you have data that resides on SQL Server 6.5. You have to move it SQL Server 7.0. How are you going to do it? You have to use transfer command.

10. Do you know how to configure DB2 side of the application? Set up an application ID, create RACF group with tables attached to this group, attach the ID to this RACF group.

11. What kind of LAN types do you know? Ethernet networks and token ring networks.

12. What is the difference between them? With Ethernet, any devices on the network can send data in a packet to any location on the network at any time. With Token Ring, data is transmitted in ‘tokens’ from computer to computer in a ring or star configuration. Token ring speed is 4/16 Mbit/sec , Ethernet - 10/100 Mbit/sec.

13. What protocol both networks use? TCP/IP. Transmission Control Protocol, Internet Protocol.

14. How many bits IP Address consist of?An IP Address is a 32-bit number. 15. How many layers of TCP/IP protocol combined of? Five. (Application,

Transport, Internet, Data link, Physical). 16. How do you define testing of network layers? Reviewing with your developers

to identify the layers of the Network layered architecture, your Web client and Web server application interact with. Determine the hardware and software configuration dependencies for the application under test.

17. How do you test proper TCP/IP configuration Windows machine? Windows NT: IPCONFIG/ALL, Windows 95: WINIPCFG, Ping or ping ip.add.re.ss

Oracle Interview Questions and Answers : SQL

1.      To see current user name  Sql> show user;

2.      Change SQL prompt name  SQL> set sqlprompt “Manimara > “ Manimara > Manimara >

3.      Switch to DOS prompt  SQL> host

4.      How do I eliminate the duplicate rows ?  SQL> delete from table_name where rowid not in (select max(rowid) from table group by duplicate_values_field_name); or SQL> delete duplicate_values_field_name dv from table_name ta where rowid <(select min(rowid)  from table_name tb where ta.dv=tb.dv); Example. Table Emp Empno Ename 101               Scott 102               Jiyo

103               Millor 104               Jiyo 105               Smith delete ename from emp a where rowid < ( select min(rowid) from emp b where a.ename = b.ename); The output like, Empno Ename 101               Scott 102               Millor 103               Jiyo 104               Smith

5.      How do I display row number with records? To achive this use rownum pseudocolumn with query, like SQL> SQL> select rownum, ename from emp; Output: 1                    Scott 2                    Millor 3                    Jiyo 4                    Smith

6.      Display the records between two range select rownum, empno, ename  from emp  where  rowid in  (select rowid from emp where rownum <=&upto  minus  select rowid from emp where rownum<&Start); Enter value for upto: 10 Enter value for Start: 7

   ROWNUM     EMPNO ENAME --------- --------- ----------         1      7782 CLARK         2      7788 SCOTT         3      7839 KING         4      7844 TURNER

7.      I know the nvl function only allows the same data type(ie. number or char or date Nvl(comm, 0)), if commission is null then the text “Not Applicable”  want to display, instead of blank space. How do I write the query?

 SQL> select nvl(to_char(comm.),'NA') from emp;

Output :

NVL(TO_CHAR(COMM),'NA') -----------------------

NA 300 500 NA 1400 NA NA

8.      Oracle cursor : Implicit & Explicit cursors Oracle uses work areas called private SQL areas to create SQL statements. PL/SQL construct to identify each and every work are used, is called as Cursor. For SQL queries returning a single row, PL/SQL declares all implicit cursors. For queries that returning more than one row, the cursor needs to be explicitly declared.

9.      Explicit Cursor attributes  There are four cursor attributes used in Oracle cursor_name%Found, cursor_name%NOTFOUND, cursor_name%ROWCOUNT, cursor_name%ISOPEN

10.  Implicit Cursor attributes  Same as explicit cursor but prefixed by the word SQL

SQL%Found, SQL%NOTFOUND, SQL%ROWCOUNT, SQL%ISOPEN

Tips : 1. Here SQL%ISOPEN is false, because oracle automatically closed the implicit cursor after executing SQL statements.        : 2.  All are  Boolean attributes.

11.  Find out nth highest salary from emp table  SELECT DISTINCT (a.sal) FROM EMP A WHERE &N = (SELECT COUNT (DISTINCT (b.sal)) FROM EMP B WHERE a.sal<=b.sal);

Enter value for n: 2       SAL ---------      3700

12.  To view installed Oracle version information  SQL> select banner from v$version;

13.  Display the number value in Words  SQL> select sal, (to_char(to_date(sal,'j'), 'jsp')) from emp; the output like,

      SAL (TO_CHAR(TO_DATE(SAL,'J'),'JSP')) --------- -----------------------------------------------------       800 eight hundred      1600 one thousand six hundred      1250 one thousand two hundred fifty If you want to add some text like, Rs. Three Thousand only. SQL> select sal  "Salary ",  (' Rs. '|| (to_char(to_date(sal,'j'), 'Jsp'))|| ' only.'))  "Sal in Words" from emp / Salary  Sal in Words ------- ------------------------------------------------------     800  Rs. Eight Hundred only.    1600  Rs. One Thousand Six Hundred only.    1250  Rs. One Thousand Two Hundred Fifty only.

14.  Display Odd/ Even number of records  Odd number of records: select * from emp where (rowid,1) in (select rowid, mod(rownum,2) from emp); 1 3 5 Even number of records: select * from emp where (rowid,0) in (select rowid, mod(rownum,2) from emp) 2 4 6

15.  Which date function returns number value?  months_between

16.  Any three PL/SQL Exceptions?  Too_many_rows, No_Data_Found, Value_Error, Zero_Error, Others

17.  What are PL/SQL Cursor Exceptions?  Cursor_Already_Open, Invalid_Cursor

18.  Other way to replace query result null value with a text  SQL> Set NULL ‘N/A’ to reset SQL> Set NULL ‘’

19.   What are the more common pseudo-columns?  SYSDATE, USER , UID, CURVAL, NEXTVAL, ROWID, ROWNUM

20.   What is the output of SIGN function?  1 for positive value, 0 for Zero, -1 for Negative value.

21.  What is the maximum number of triggers, can apply to a single table?  12 triggers.

Database Questions

1. What are the different types of joins? 2. Explain normalization with examples. 3. What cursor type do you use to retrieve multiple recordsets? 4. Diffrence between a "where" clause and a "having" clause 5. What is the difference between "procedure" and "function"? 6. How will you copy the structure of a table without copying the data? 7. How to find out the database name from SQL*PLUS command prompt? 8. Tadeoffs with having indexes 9. Talk about "Exception Handling" in PL/SQL? 10. What is the diference between "NULL in C" and "NULL in Oracle?" 11. What is Pro*C? What is OCI? 12. Give some examples of Analytical functions. 13. What is the difference between "translate" and "replace"? 14. What is DYNAMIC SQL method 4? 15. How to remove duplicate records from a table? 16. What is the use of ANALYZing the tables? 17. How to run SQL script from a Unix Shell? 18. What is a "transaction"? Why are they necessary? 19. Explain Normalizationa dn Denormalization with examples. 20. When do you get contraint violtaion? What are the types of constraints? 21. How to convert RAW datatype into TEXT? 22. Difference - Primary Key and Aggregate Key 23. How functional dependency is related to database table design? 24. What is a "trigger"? 25. Why can a "group by" or "order by" clause be expensive to process? 26. What are "HINTS"? What is "index covering" of a query? 27. What is a VIEW? How to get script for a view? 28. What are the Large object types suported by Oracle? 29. What is SQL*Loader? 30. Difference between "VARCHAR" and "VARCHAR2" datatypes. 31. What is the difference among "dropping a table", "truncating a table" and

"deleting all records" from a table. 32. Difference between "ORACLE" and "MICROSOFT ACCESS" databases. 33. How to create a database link ?

1. How do you list the files in an UNIX directory while also showing hidden files? ls -ltra

2. How do you execute a UNIX command in the background? Use the “&". 3. What UNIX command will control the default file permissions when files are

created? umask 4. Explain the read, write, and execute permissions on a UNIX directory. Read

allows you to see and list the directory contents. Write allows you to create, edit and delete files and subdirectories in the directory. Execute gives you the permissions to run programs or shells from the directory.

5. What is the difference between a soft link and a hard link? A symbolic (soft) linked file and the targeted file can be located on the same or different file system while for a hard link they must be located on the same file system.

6. Give the command to display space usage on the UNIX file system. df -lk 7. Explain iostat, vmstat and netstat. iostat reports on terminal, disk and tape I/O

activity. vmstat reports on virtual memory statistics for processes, disk, tape and CPU activity. netstat reports on the contents of network data structures.

8. How would you change all occurrences of a value using VI? %s/(old value)/(new value)/g

9. Give two UNIX kernel parameters that effect an Oracle install. SHMMAX & SHMMNI

10. Briefly, how do you install Oracle software on UNIX? Basically, set up disks, kernel parameters, and run orainst.

Shell ----- [1] How do I find out the names of files in a tar file called "arch1.tar"?

[2] Say I have a directory tree under '.' and I want to look for the names of text files called '*log' containing 'ORA-00054'. How could I do that?

[3] What's going on here?

$ ssh -n cyclops 'more /var/local/mail-list/*'

[4] What command would you use to display which user owns the current directory?

Technical Questions asked of UNIX Admins.

Some questions will have more than one answer. Some questions are written to reveal something about the admin's style and are purposely vague.

Because of the question wording it's possible for someone to respond correctly, but not with the answer I sought. Therefore this list is intended as a guide, not as a standard. (please don't email me for the answers... ;) john

=========================================================================1) what editor do you use? (hint: a wrong answer here will heavily

influence the interview... what is on ALL Unix systems? ;)

2) what shell do you use? (hint: a wrong answer here will affect your chances)

3) what is the best shell for root?

4) why is that the best shell for root?

5) list the operating systems you are familiar with and the versions.

6) how do you backup your system?

7) what commercial tools have you used for backup and archive?

8) what UID does root have across an NFS mount by default?

9) what file contains the mounted file systems in Solaris?

10) what file contains the mounted file systems in HP-UX?

11) what command identifies the NIS server you are bound to?

12) what is the name of the administrative tool for Sun?13) what is the name of the administrative tool for HP?14) what is the name of the administrative tool for IBM?

15) if you are going to modify CDE files, which directory should you edit:

/usr/dt... or /etc/dt... ?

16) what differs between the NIS entry in the /etc/passwd file btwn HP and Sun?

17) in Solaris 2.5 what is the name of the file with the NFS exported files?18) in Solaris 2.6 what is the name of the file with the NFS exported files?

19) identify some differences btwn CDE in Solaris 2.6 and Solaris 2.7?

20) How can you tell what is attached to the SCSI chain on a Sun system?21) How can you tell what is attached to the SCSI chain on an HP system?

22) What command will tell you have much memory a system has in Solaris?23) What command will tell you have much memory a system has in HP-UX?

24) Where are system messages logged in Solaris?25) Where are system messages logged in HP-UX?

26) How would you "break" an NFS mount on a system that has users on it?

27) Explain how you could stop and start a process without rebooting?

28) What command will tell you how long a system has been running?

29) What is LVM?30) what is an HFS?31) what is fsck?32) what is Jxfs or Vxfs?

33) how do you get a Sun system to single user mode? 34) how do you get an HP system to single user mode?

35) What files control basic hostname and network information on a Sun? (hint: 3)36) What files control basic hostname and network information on an HP? (hint: 2)

37) What command will provide status of your filesystems on a Sun?38) What command will provide status of your filesystems on a HP?39) What command will provide status of your filesystems on a Linux system?

40) What file do you edit to permit non-console login of root on a Solaris system?41) What file (with path) contains the information that appears when you right click on the background of a CDE login?42) What command, with path, launches OpenWindows on a SunOs 4.1.3 system?43) What command provides information on the health and performance of NFS?44) What command provides information on your network connection?

45) What are some of the tags in HTML that do not require a closing tag?

46) What command can you use to find the path to an application?

47) What option can you use with FTP to automatically transfer using wildcards?

48) What character(s) show up in an ascii file created in MSDos or Windoze

when FTP'd in Binary mode?

49) What does the ioscan command do?

50) What does the lanscan command do?

51) What command in Solaris shows disk partitions?

52) What are the tar commands to display the contents of an archive?

53) What directory are programs like perl and netscape installed in?

54) What is the recommended ratio of swap to memory for X-windows?

55) What command tells you who is logged into a file system?

56) What is the command to shutdown and halt a Sun system?57) What is the command to shutdown and halt an HP system?

58) How do you mount a filesystem?

59) What command can you use to identify a hostname or ip address?

60) What character is used to launch an application and run it in the background?

61) What command lists the current running jobs?

62) How do you kill a running job?

63) Where are startup scripts for an HP-UX 10.20 system?64) Where are startup scripts for a Solaris 2.6 system?

65) What command is used to display NIS host information for an IP address?

Technical - UNIX

1. How do you list the files in an UNIX directory while also showing hidden files?

2. How do you execute a UNIX command in the background? 3. What UNIX command will control the default file permissions when files

are created? 4. Explain the read, write, and execute permissions on a UNIX directory. 5. What is the difference between a soft link and a hard link? 6. Give the command to display space usage on the UNIX file system. 7. Explain iostat, vmstat and netstat. 8. How would you change all occurrences of a value using VI? 9. Give two UNIX kernel parameters that effect an Oracle install 10.Briefly, how do you install Oracle software on UNIX.