Vous êtes sur la page 1sur 2

Have you ever encountered an error called "depth not equal"?

Ans: When two components are linked together if their layout doesnot match then this problem can occur during the compilation of the graph. A solution to this p roblem would be to use a partitioning component in between if there was change i n layout. What is the function you would use to transfer a string into a decimal? Ans: In this case no specific function is required if the size of the string and decimal is same. Just use decimal cast with the size in the transform function and will suffice. For example, if the source field is defined as string(8) and t he destination as decimal(8) then (say the field name is field1).out.field :: (d ecimal(8)) in.field If the destination field size is lesser than the input then use of string_substr ing function can be used likie the following. say destination field is decimal(5). out.field :: (decimal(5))string_lrtrim(string_substring(in.field,1,5)) /* string _lrtrim used to trim leading and trailing spaces */ In RDBMS the relationship between the two tables is represented as Primary key a nd foreign key relationship.Wheras the primary key table is the parent table and foreignkey table is the child table.The criteria for both the tables is there s hould be a matching column. What are Cartesian joins? Ans: Joins two tables without a join key. Key should be {}. What is the purpose of having stored procedures in a database? Ans: Main Purpose of Stored Procedure for reduse the network trafic and all sql statement executing in cursor so speed too high. Why might you create a stored procedure with the 'with recompile' option? Recompile is useful when the tables referenced by the stored proc undergoes a lo t of modification/deletion/addition of data. Due to the heavy modification activ ity the execute plan becomes outdated and hence the stored proc performance goes down. If we create the stored proc with recompile option, the sql server wont c ache a plan for this stored proc and it will be recompiled every time it is run. What is a cursor? Within a cursor, how would you update fields on the row just f etched? Ans: The oracle engine uses work areas for internal processing in order to the e xecute sql statement is called cursor.There are two types of cursors like Implec it cursor and Explicit cursor.Implicit cursor is using for internal processing a nd Explicit cursor is using for user open for data required. How would you find out whether a SQL query is using the indices you expect? Ans: Explain plan can be reviewed to check the execution plan of the query. This would guide if the expected indexes are used or not. How can you force the optimizer to use a particular index? Ans: use hints /*+ */, these acts as directives to the optimizer select /*+ index(a index_name) full(b) */ *from table1 a, table2 bwhere b.col1 = a.col1 and b.col2= 'sid'and b.col3 = 1; When using multiple DML statements to perform a single unit of work, is it prefe rable to use implicit or explicit transactions, and why. Ans: Because implicit is using for internal processing and explicit is using for user open data requied.

Describe the elements you would review to ensure multiple scheduled "batch" jobs do not "collide" with each other. Ans: Because every job depend upon another job for example if you first job resu lt is successfull then another job will execute otherwise your job doesn't work. Describe the process steps you would perform when defragmenting a data table. Ans: This table contains mission critical data. There are several ways to do this: 1) We can move the table in the same or other tablespace and rebuild all the ind exes on the table. alter table move this activity reclaims the defragmented space in the table analyze table table_name compute statistics to capture the updated statistics. 2)Reorg could be done by taking a dump of the table, truncate the table and impo rt the dump back into the table. Explain the difference between the truncate and "delete" commands. Ans: The difference between the TRUNCATE and DELETE statement is Truncate belong s to DDL command whereas DELETE belongs to DML command.Rollback cannot be perfor med incase of Truncate statement wheras Rollback can be performed in Delete stat ement. "WHERE" clause cannot be used in Truncate where as "WHERE" clause can be used in DELETE statement. What is the difference between a DB config and a CFG file? Ans: A .dbc file has the information required for Ab Initio to connect to the da tabase to extract or load tables or views. While .CFG file is the table configur ation file created by db_config while using components like Load DB Table. Describe the Grant/Revoke DDL facility and how it is implemented. Ans:Basically,This is a part of D.B.A responsibilities GRANT means permissions f or example GRANT CREATE TABLE ,CREATE VIEW AND MANY MORE . REVOKE means cancel the grant (permissions).So,Grant or Revoke both commands dep end upon D.B.A