Get agent "run as" value from system tables
Hi,
When you create a job step (specifically an SSIS) you can set the "run as" value. Can anyone tell me where this value can be queried in system tables/views?
I'm looking in
SELECT * FROM msdb..sysjobsteps
SELECT * FROM msdb..sysjobs
but can't see the value I know the job step is set to.
Try the below:
SELECT
B.[job_id] AS [JobID]
, B.[name] AS [JobName]
, A.[step_name] AS [StepName]
, C.[name] AS [RunAs]
FROM
[msdb].[dbo].[sysjobsteps] AS A
INNER JOIN [msdb].[dbo].[sysjobs] AS B ON A.[job_id] = B.[job_id]
LEFT JOIN [msdb].[dbo].[sysproxies] AS C ON A.[proxy_id] = C.[proxy_id]
ORDER BY [JobName]
Similar Messages
-
Get old and new values from DBTABLOG table
Hi,
I am developing a report to display all changes to some fields of PKHD table over a date range. CDHDR & CDPOS do not capture the changes while DBTABLOG does. But the variable key field (LOGDATA) in DBTABLOG does hold encrypted values which need to be decrypted. Is there any FM or a way out to get them ?
Please let me know. Thanks a lot.
Regards
NeerajUse DBLOG_READ and then work with the data like in the following sample
* Constants (cf. SAP RSVTPTOP)
CONSTANTS: type_i4 LIKE x031l-fieldtype VALUE 'AC', "UF160698B
type_i2 LIKE x031l-fieldtype VALUE 'A8',
type_f LIKE x031l-fieldtype VALUE '88'. "UF160698E
* First - informations from directory
REFRESH fld_list.
CALL FUNCTION 'GET_FIELDTAB'
EXPORTING
langu = sy-langu
only = ' '
tabname = 'TEVEN'
withtext = 'X'
* IMPORTING
* HEADER =
* RC =
TABLES
fieldtab = fld_list
EXCEPTIONS
internal_error = 1
no_texts_found = 2
table_has_no_fields = 3
table_not_activ = 4
OTHERS = 5.
LOOP AT fld_list INTO fld WHERE keyflag = 'X'.
ADD fld-intlen TO keylen.
ENDLOOP.
* Then extract data log
REFRESH obj_list.
obj-tab = 'TEVEN'.
INSERT obj INTO TABLE obj_list.
CALL FUNCTION 'DBLOG_READ'
EXPORTING
from_day = s-aedtm-low
* FROM_TIME = '000000'
to_day = s-aedtm-high
* TO_TIME = '235959'
obj_list = obj_list
* ACCESS_DATABASE = 'X'
* ACCESS_ARCHIVES = ' '
* AUTO_ARCH_SEL = ' '
* USER_LIST =
CHANGING
log_list = log_list
EXCEPTIONS
archive_access_error = 1
no_archives_found = 2
OTHERS = 3.
* Extract data from returned tables
LOOP AT log_list INTO log.
LOOP AT fld_list INTO fld.
IF fld-keyflag = 'X'.
ASSIGN log-logkey+fld-offset(fld-intlen)
TO <hexa> TYPE 'X'.
ELSE.
fld-offset = fld-offset - keylen.
ASSIGN log-logdata+fld-offset(fld-intlen)
TO <hexa> TYPE 'X'.
fld-offset = fld-offset + keylen.
ENDIF.
CASE fld-inttype.
WHEN 's'.
f_type = type_i2.
WHEN 'I'.
f_type = type_i4.
WHEN 'F'.
f_type = type_f.
ENDCASE.
IF 'sIF' CS fld-inttype.
feld = <hexa>.
CALL FUNCTION 'DB_CONVERT_FIELD_TO_HOST'
EXPORTING
type = f_type
CHANGING
field = feld
EXCEPTIONS
wrong_param = 1
OTHERS = 2.
ASSIGN feld TO <hexa> TYPE 'X'.
ENDIF.
ASSIGN <hexa> TO <char> TYPE 'C'.
teven+fld-offset(fld-intlen) = <char>.
ENDLOOP.
* Here structure teven is filled
ENDLOOP.
Regards -
How to get all the column values from a table source
Hi,
I have created one table source on a employee table and some customized attributes using global settings>search attributes.
Now these customized attributes mapped with the table columns through attribute mapping from the sorce tab.
Using doOracleSearch method i passed last parameter i.e. Integer array of customized attributes.
After execution of doOracleSearch method i am getting the results but customized attributes are not coming.
getCustomAttributes method returns null instead of some values.
Please refer following code for more info:
Integer[] fetchAttr=new Integer[2];
fetchAttr[0]=new Integer(137);
fetchAttr[1]=new Integer(138);
result =
stub.doOracleSearch("BTM",
new Integer(1),
new Integer(10),
Boolean.TRUE,
Boolean.TRUE,
group,
"en",
"en",
Boolean.TRUE,
null,
null,
fetchAttr);
ResultElement[] resElements = result.getResultElements();
for(int i = 0; i < resElements.length; i++)
System.out.println("Title : " + resElements[0].getTitle());
System.out.println("Snippet : " + resElements[0].getSnippet());
System.out.println("URL : " + resElements[0].getUrl());
System.out.println("non default : " + resElements[0].getCustomAttributes()); // it returns null here
}Confirm the attributes you are asking SES for match those on the data source being searched. One thing to try is to simply tell SES to return all custom attributes for your search. Here is a snippet to build a list of all attribute IDs and pass them to your search...
// Create and set SOAP URL
OracleSearchService searchService = new OracleSearchService();
searchService.setSoapURL("http://myserver:7777/search/query/OracleSearch");
// Set attributes to fetch (all)
Attribute[] attributesAll = searchService.getAllAttributes("en");
ArrayList<Integer> attributeIds = new ArrayList<Integer>();
for(Attribute a: attributesAll)
attributeIds.add(a.getId());
Integer attributeIdArrayAll[] = new Integer[attributeIds.size()];
attributeIdArrayAll = attributeIds.toArray(attributeIdArrayAll);
// Query
OracleSearchResult result = searchService.doOracleSearch("some text", ..........[other params], attributeIdArrayAll);
// Print out results
ResultElement[] resElements = result.getResultElements();
for(int i = 0; i < resElements.length; i++)
// Get document
ResultElement doc = resElements;
// Print Title
System.out.println("Title: " + doc.getTitle());
// Print custom attributes
CustomAttribute[] attributes = doc.getCustomAttributes();
for(int j = 0; j < attributes.length; j++)
CustomAttribute attr = attributes[j];
System.out.println("[Custom Attribute] " + attr.getName() + ": " + attr.getValue());
Hope this helps. -
How to get multipe data set values from Decision Table.
Hi All,
I need to use SAP BRM for one of the scenario where based one some Code Group I need to get a set of questions and for each question a set of possible answers.
The structure of Decision Table will be like below :
Table 1 : To get set of questions based on Project Code
Input Output Output
Project Code
Question Id
Question Description
Table 2 : To get set of answers based on question
Input Output Output
Question ID
Answer Id
Answer Description
I already searched in forum to get the multiple values based on some input and that works fine for a single field with multiple outcome.
Handling Selective Multiple Actions in SAP Business Rules Management System
In my scenario I need to get a set of Id and description as multiple outcome.
Can anyone please let me know how this can be achieved in BRM.
Thanks in advance
RavindraCreate an XSD in the BRM project with the desired data structure and import the XSD alias in the 'Project Resources'. Add this XSD alias as input/output of the decision table.
Refer this:
Creating a Simple BRM Ruleset in 30 Easy Steps using NWDS 7.3 (Flow Ruleset with a Decision Table) -
How can i get first four highest values from a table
suppose we have salary table and we need first 4 highest salaries in one query or attemp
Or use an analytic:
SQL> select ename, sal from emp;
ENAME SAL
SMITH 800
ALLEN 1600
WARD 1250
JONES 2975
MARTIN 1250
BLAKE 2850
CLARK 2450
SCOTT 3000
KING 5000
TURNER 1500
ADAMS 1100
JAMES 950
FORD 3000
MILLER 1300
14 rows selected.
SQL> select ename, sal
2 from
3 (
4 select ename
5 ,sal
6 ,dense_rank() over (order by sal desc) dr
7 from emp
8 )
9 where dr <= 4;
ENAME SAL
KING 5000
SCOTT 3000
FORD 3000
JONES 2975
BLAKE 2850 -
Executed Step outcome value from the table
Hi,
How to get the Step outcome value from the table for the executed workitem.
Regards,
Rani.Hi Rani,
For database tables you can refer to tables:
SWWLOGHIST - History of a work item
SWWORGTASK - Assignment of WIs to Org.Units and Tasks
SWWUSERWI - Current Work Items Assigned to a User
SWWWIHEAD - Header Table for all Work Item Types
SWWWIAGENT - Gets agents assigned to a workitem
You can you FMs like SAP_WAPI_GET_WORKITEM_DETAIL, SAP_WAPI_CREATE_WORKLIST as per your requirement.
Hope this helps!
Regards,
Saumya -
How to get edited row values from ADF table?
JDev 11.
I have a table which is populated with data from Bean.
I need to save changes after user make changes in any table cell. InputText is defined for table column component.
I have defined ValueChangeListener for inputText field and AutoSubmit=true. So when user change value in inputText field, method is called:
public void SaveMaterial(ValueChangeEvent valueChangeEvent) {
getSelectedRow();
SaveMaterial(material);
This method should call getSelectedRow which take values from selected table row and save them into object:
private Row getSelectedRow(){
RichTable table = this.getMaterialTable();
Iterator selection = table.getSelectedRowKeys().iterator();
while (selection.hasNext())
Object key = selection.next();
table.setRowKey(key);
Object o = table.getRowData();
material = (MATERIAL) o;
System.out.println("Selected Material Desc = "+material.getEnumb());
return null;
Problem is that getSelectedRow method doesnt get new (edited) values, old values are still used.
I have tried to use ActiveButton with same method and it works fine in that case. New values are selected from active row and inserted into object.
JSF:
<af:table var="row" rowSelection="single" columnSelection="single"
value="#{ManageWO.material}" binding="#{ManageWO.materialTable}">
<af:column sortable="false" headerText="E-number">
<af:inputText value="#{row.enumb}" valueChangeListener="#{ManageWO.SaveMaterial}" autoSubmit="true"/>
</af:column>
<af:column sortable="false" headerText="Description">
<af:inputText value="#{row.desc}" valueChangeListener="#{ManageWO.SaveMaterial}" autoSubmit="true"/>
</af:column>
</af:table>
<af:activeCommandToolbarButton text="Save" action="#{ManageWO.EditData}"/>
What is a correct place from where save method should be called to get new (edited) values from ADF table?
Thanks.Did you look into the valueChangeEvent?
It has oldValue and newValue attributes.
public void SaveMaterial(ValueChangeEvent valueChangeEvent) {
Object oldVal = valueChangeEvent.getOldValue();
Object newVal = valueChangeEvent.getNewValue();
// check if you see what you are looking for.....
getSelectedRow();
SaveMaterial(material);
}Timo -
How to get string value from database table using Visual Studio 2005?
Hi,
Im developing plugin in illustrator cs3 using visual studio 2005. I need to get the values eneterd in database. Im able to get the integer values. But while getting string values it is returning empty value.
Im using the below code to get the values from database table
bool Table::Get(char* FieldName,int& FieldValue)
try
_variant_t vtValue;
vtValue = m_Rec->Fields->GetItem(FieldName)->GetValue();
FieldValue=vtValue.intVal;
CATCHERRGET
sprintf(m_ErrStr,"Success");
return 1;
Im using the below code to get the values.
AIErr getProjects()
char buf[5000];
int i;
std::string catName;
::CoInitialize(NULL);
Database db;
Table tbl;
errno_t err;
err = fopen(&file,"c:\\DBResult.txt","w");
fprintf(file, "Before Connection Established\n");
//MessageBox(NULL,CnnStr,"Connection String",0);
if(!db.Open(g->username,g->password,CnnStr))
db.GetErrorErrStr(ErrStr);
fprintf(file,"Error: %s\n",ErrStr);
fprintf(file, "After Connection Established\n");
if(!db.Execute("select ProjectID,ProjectName from projectsample",tbl))
db.GetErrorErrStr(ErrStr);
fprintf(file,"Error: %s\n",ErrStr);
int ProjectID;
int UserID;
int ProjectTitle;
char ProjectName[ProjectNameSize];
if(!tbl.ISEOF())
tbl.MoveFirst();
ProjectArrCnt=0;
for(i=0;i<128;i++)
buf[i]='\0';
int j=0;
while(!tbl.ISEOF())
if(tbl.Get("ProjectID",ProjectID))
fprintf(file,"Project ID: %d ",ProjectID);
ProjectInfo[ProjectArrCnt].ProjectID = ProjectID;
sprintf(buf,"%d",ProjectID);
//MessageBox(NULL, buf,"f ID", 0);
j++;
else
tbl.GetErrorErrStr(ErrStr);
fprintf(file,"Error: %s\n",ErrStr);
break;
//if(tbl.Get("ProjectTitle",ProjectName))
if(tbl.Get("ProjectName",ProjectName))
MessageBox(NULL,"Inside","",0);
fprintf(file,"ProjectTitle: %s\n",ProjectName);
//catName=CategoryName;
ProjectInfo[ProjectArrCnt].ProjectName=ProjectName;
//sprintf(buf,"%s",ProjectName);
MessageBox(NULL,(LPCSTR)ProjectName,"",0);
else
tbl.GetErrorErrStr(ErrStr);
fprintf(file,"Error: %s\n",ErrStr);
break;
ProjectArrCnt++;
//MessageBox(NULL, "While", "WIN API Test",0);
tbl.MoveNext();
//MessageBox(NULL, ProjectInfo[i].ProjectName.c_str(),"f Name", 0);
::CoUninitialize();
//sprintf(buf,"%s",file);
//MessageBox(NULL,buf,"File",0);
fprintf(file, "Connection closed\n");
fclose(file);
for(i=0;i<ProjectArrCnt;i++)
sprintf(buf,"%i",ProjectInfo[i].ProjectID);
//MessageBox(NULL,buf,"Proj ID",0);
//MessageBox(NULL,ProjectInfo[i].ProjectName.c_str(),"Project Name",0);
return 0;
In the above code im geeting project D which is an integer value. But not able to get the project name.
Please some one guide me.As I said in the other thread, this really isn't the place to ask questions about a database API unrelated to the Illustrator SDK. You're far more like to find people familliar with your problem on a forum that is dedicated to answering those kinds of questions instead.
-
CE function to get distinct values from Column table
Hi All,
Could you please let me know the appropriate CE function to get the distinct values from column table.
IT_WORK = SELECT DISTINCT AUFNR FROM :IT_WO_DETAILS;
Thank you.Hi,
If you have 10g, you can use Model( with model performance is better than connect by )
Solution
========================================================================
WITH t AS
(SELECT '0989.726332, 1234.567432, 3453.736379, 3453.736379, 0989.726332, 3453.736379, 1234.567432, 1234.567432, 0989.726332'
txt
FROM DUAL)
SELECT DISTINCT TRIM(CHAINE)
FROM T
MODEL
RETURN UPDATED ROWS
DIMENSION BY (0 POSITION)
MEASURES (CAST( ' ' AS VARCHAR2(50)) AS CHAINE ,txt ,LENGTH(REGEXP_REPLACE(txt,'[^,]+',''))+1 NB_MOT)
RULES
(CHAINE[FOR POSITION FROM 1 TO NVL(NB_MOT[0],1) INCREMENT 1] =
CASE WHEN NB_MOT[0] IS NULL THEN TXT[0] ELSE REGEXP_SUBSTR(txt[0],'[^,]+',1,CV(POSITION)) END );
=========================================================================
Demo
=======================================================================
SQL> WITH t AS
2 (SELECT '0989.726332, 1234.567432, 3453.736379, 3453.736379, 0989.726332, 3453.736379, 123
4.567432, 1234.567432, 0989.726332'
3 txt
4 FROM DUAL)
5 SELECT DISTINCT TRIM(CHAINE)
6 FROM T
7 MODEL
8 RETURN UPDATED ROWS
9 DIMENSION BY (0 POSITION)
10 MEASURES (CAST( ' ' AS VARCHAR2(50)) AS CHAINE ,txt ,LENGTH(REGEXP_REPLACE(txt,'[^,]+',''))+1 NB_MOT)
11 RULES
12 (CHAINE[FOR POSITION FROM 1 TO NVL(NB_MOT[0],1) INCREMENT 1] =
13 CASE WHEN NB_MOT[0] IS NULL THEN TXT[0] ELSE REGEXP_SUBSTR(txt[0],'[^,]+',1,CV(POSITION)) END );
TRIM(CHAINE)
3453.736379
1234.567432
0989.726332
SQL>
======================================================================== -
POPUP FM to get values from a table control?
I know about the FM POPUP_GET_VALUES to get one or more values from a popup dialog box. I would like to find a similar FM that allows getting values from a table control or something that allows entry of multiple lines of values. Is there such a thing, or do I need to write my own?
it depends on what values you want to enter, better write your own to have a control on the function.
-
How to get values from a table(in jsp) for validation using javascript.
hi,
this is praveen,pls tell me the procedure to get values from a table(in jsp) for validation using javascript.
thank you in advance.Yes i did try the same ..
BEGIN
select PROD_tYPE into :P185_OFF_CITY from
magcrm_setup where atype = 'CITY' ;
:p185_OFF_CITY := 'XXX';
insert into mtest values ('inside foolter');
END;
When i checked the mtest table it shos me the row inserted...
inside foolter .. Now this means everything did get execute properly
But still the vallue of off_city is null or emtpy...
i check the filed and still its empty..
while mtest had those records..seems like some process is cleaining the values...but cant see such process...
a bit confused..here..I tried on Load after footer...
tried chaning the squence number of process ..but still it doesnt help
some how the session variables gets changed...and it is changed to empty
Edited by: pauljohny on Jan 3, 2012 2:01 AM
Edited by: pauljohny on Jan 3, 2012 2:03 AM -
How to get input text values from adf table - Urgent
Hi Friends,
This is my requirement. I designed customized master - detail - detail page. I customized the page in below format.
1. Master Data Field (Input text,etc) .
2. Detail in table format ( Rows are mapped to child table) and i given two buttons for to create row and delete row. I designed the table based on the example provided in forum for to create customized table. The input text component is mapped to the rows.
Now i want to retrieve all the data's entered in the rows. The table is mapped to child table. When i read the values from the table its showing null.
If any one faced this problem and fixed it, please send me the solution.
Thanks & Regards
VBDid you look into the valueChangeEvent?
It has oldValue and newValue attributes.
public void SaveMaterial(ValueChangeEvent valueChangeEvent) {
Object oldVal = valueChangeEvent.getOldValue();
Object newVal = valueChangeEvent.getNewValue();
// check if you see what you are looking for.....
getSelectedRow();
SaveMaterial(material);
}Timo -
Syndicating Key mapping value from lookup table
Hi Experts,
I want to Syndicating Remote Key value from lookup table as per the remote system.
In syndicator, if I map destination field to the remote key of the lookup table, I am getting blank value.Hi Mrinmoy,
kindly check in the Data Manger whether have you maintained Remote keys for the lookup table. If yes then choose the specified remote system from Remote key override fields under Map properties in the syndicator.
Incase you cant find the remote system in the "remote key override" field for which remote key is assigned in Data manager, then you need to check the Type (outbound) of the remote system in Console admin node. Because only those Remote systems type set as Outbound can been found in Remote key Override in the syndicator.
After choosing the remote key you need to map the destination field with Remote key value as shown in the below image.
Regards
Rahul -
Can retrieve value from one table, but not the other (exception thrown)
Hi
I hope some friendly soul can help me out here. I have a local Access database file. I am able to get a value from all tables except for one, which throws this error: "System.NullReferenceException:
Object reference has not been specified to an object".
The rather simple lines of code when working is this:
Dim email As Object
value = MyDataSet.Tables("Table")(0)(1).ToString
Msgbox(email)
However, when simply changing from "Table" to "AnotherTable", the exception is thrown. I
have seriously no idea why. I've made sure the datatypes are the same and that the values are not NULL.
What gives?Hello,
Going with your last reply, you should be accessing data via the strong typed classes that get generated.
Example using Microsoft Northwind database accessing the customers table in a MS-Access database. Note the check for Rows, we could even go farther if we are questioning issue with the data via try-catch statements writing errors to the IDE Output window.
I would highly recommend never referencing rows without first checking if there are rows and secondly never reference columns by ordinal index, always use the column name. One example with ordinal positioning, suppose someone did SomeDataTable.Columns("SomeColName").SetOrdinal(3)
and you expect the ordinal position to be 1 ? things will crash-n-burn. Food for thought :-)
Public Class Form1
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Me.CustomersTableAdapter.Fill(Me.MainDataSet.Customers)
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
If MainDataSet.Customers.Rows IsNot Nothing Then
Dim FirstCompanyName As String = MainDataSet.Customers.FirstOrDefault.CompanyName
MessageBox.Show(FirstCompanyName)
Else
MessageBox.Show("No rows in customer table")
End If
End Sub
End Class
In this case we get the first record from below in Button1 Click
Please remember to mark the replies as answers if they help and unmark them if they provide no help, this will help others who are looking for solutions to the same or similar problem. -
Can one field of a variant of an ABAP4 program takes value from a table ?
When I run an ABAP4 program, there is one input field called Time Stamp. If I run the program directly (without selecting a variant), this Time Stamp field is filled with a field value from a table called TVARVC, but if I select a variant of this program, this Time Stamp field is filled with another field value of the table TVARVC. It seems that the variant value can be filled with a value in system table, am I right? If this is the case, then how it is programmed?
Thanks
Message was edited by: Kevin SmithHi Kevin
In the table TVARVC you should insert a new record which name (field NAME) have to begin with SAP_SCMA_ and the type (field TYPE)is P for parameter or S for select-options and the values (field LOW and/or HIGH) are your value.
So you have to create a variant and for input field Time Stamp set flag SELECTION VARIABLE and then push button SELECTION VARIABLES. Now you have to insert the name of your record of TVARVC.
So when user choose this variant the input field Time Stamp is filled with value you have entered in TVARVC.
Now in TVARVC you can insert another record (if you want it isn't avaible for SELECTION VARIABLE function in the variant, you should give it a name it doesn't begin with SAP_SCMA_) and put this value in the input field Time Stamp during INITIALIZATION event:
INITIALIZATION.
SELECT * FROM TVARVC WHERE NAME = ......
Time Stamp = TVARVC-LOW.
Max
P.S. you have opened two post with the same problem, close older one.
Message was edited by: max bianchi
Maybe you are looking for
-
Total weight of a post item in purchase order message
Hello ! I want to write in the sapscript form used to edit the purchase order the total weight of a post item. I found in the table EKPO the net weight, but iti is the weight of one article and not of the whole post item. Does someone know how I can
-
How to delete facebook acc from email+accounts
I have tried so much times to delete Facebook account but it says error code 0x83cf1202 what should I do, plz reply anyone
-
Movie iTunes from one computer to another
I purchased a new computer I would like to have my new computer to work the same way as my old one as far as the iTunes goes. What is the best and easy way to move my iTunes to my new computer? So that when I connect my I touch to my new computer all
-
Credit Memo posting using IDOC
Hi, I could post an invoice using IDOC using the function module IDOC_INPUT_INVOIC_MRM. I need to post a credit memo (MIRO) using IDOCs now. Any suggestions? thanks Srinivasa Vepa
-
Concatenate columns with distinct values in oracle
Hello Gurus, My table structre look like follwoing: TankListUS TankListCanada TankListIndia T111||T222 T444||T222 T555 Now when I run the query: select (TL.TankListUS || '||' || TL.TankListCanada || '||' || TL.TankListIndia)