What is difference macros and prompts?

Answers were Sorted based on User's Feedback



What is difference macros and prompts?..

Answer / nmlabsonline.net

Macros is nothing but a conditions Total in project level
but prompt is dynamic condition (in Repositary level) this
is implimenting report level in particular filter
condition.......

Is This Answer Correct ?    0 Yes 0 No

What is difference macros and prompts?..

Answer / janardhanreddy

Macro: It is a collection of SQL queries preferably DML statments and it is stored as an object in DD(Data Dictionary). Unlike VIEWS (we will deal about Views in another post), a macro can have multiple sequels. It is known that a macro can handle many DML and it is restricted to only one DDL.

Reason: DDL statements like Create,Alter,Drop,Rename generally locks the DD for their processing, since macros transaction is an internal process it is highly dependent on DD. Therefore DDL can be last statement in a macro. - This is what provided as theoretical explanation .

Example:
CM AS // CM doesnt work with Queryman better try with BTEQ
or
CREATE MACRO MyMacroName AS
(
insert into (eno,name,ereqno) emp values (101,'Rajesh',43243259);
select * from emp;
//DDL stmt here (doesnt work with queryman)
)
Issue: There is an issue with macro that, DDL couldnt be even as last statement in a macro(with Queryman). I used Teradata 12 and I am getting Warning as Data Dictionary must be solitary. I will update after working with BTEQ.

Parameterized Macro:
//paramNum is passed as Parameter to Select statement.
//passed parameter shd be accessed using =:paramname

CREATE MACRO macro_name (paramNum integer) AS
{
DMLs here....
select ename,esal from emp where eno = :paramName ;
};

REPLACE Macro:

If you require more DMLs to be added to an existing macro, you can use
REPLACE MACRO AS
{[insert];
[update];
[delete];
[select];);

To Execute Macro:

EXEC []
eg: exec myfirsmacro_name;
exec myfirsmacro_name (invalue=1,invalue='abc');

To Drop:
DROP MACRO macro-name;

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Informatica Interview Questions

what is session override?

2 Answers   Cap Gemini,


how to join the 2 different table with different columns in informatica?

5 Answers   Accenture,


Scheduling properties,whats the default (sequential)

0 Answers  


what is the predefined port in dynamic lookup

2 Answers  


What is decode in static cache?

0 Answers  






What does “tail –f” command do and what is its use as an Informatica admin.

0 Answers  


Hi, This is Lakshmi,Anyone taking classes for datawarehouse-Informatica and BO with real time project

2 Answers  


One of the optimizing technique to improve the session performance is push down optimization,by using push down optimization we push as much as transformation logic to source/target database,but this degrades the d/b performance,how to overcome this?

0 Answers   TCS,


What is source qualifier?

6 Answers   SDS,


when will we go for unconnected lookup transformation in Informatica?

6 Answers   CTS, IBM,


how can u approach u r client

2 Answers   CTS,


what is scd?

6 Answers  


Categories