Need to create Dynamic Varient
Hi,
Need to create Dynamic Varient
My Requirement is :
When the program runs on last day of the month, varient has to be set up to populate the
the File path as :
/PA1/Interfaces/FlatFiles/new_sales_history.txt
When the program runs on Working day + 1, then the other varient has to be set up to populate the File Path as :
/PA1/Interfaces/FlatFiles/sales_history.txt
Can anybody let me know how i can create Dynamic Varient...?
Any suggestions will be appreciated!
Regards,
Kittu
Consider the following option:
1) Create two parameters on selection screen. One for working day file and another for working day + 1 file.
2) Use logic inside program to determine if working day or not. Accordingly use the correct file name (from parameter).
3) Users can override the file parameters online. If needed, when the program is run online (SY-BATCH = ' '), issue a confirmation popup for the file to be used.
I am not sure "dynamic variants" is the way to go here because you will have to build another program/process of updating it everyday. But here is information about it anyways...
To create customer defined variables to be used in a variant, you will have to create it in table TVARV. See the following two links for further information:
http://help.sap.com/saphelp_45b/helpdata/en/c0/980398e58611d194cc00a0c94260a5/frameset.htm
https://www.sdn.sap.com/irj/scn/wiki?path=/display/abap/creatingdynamicvariantusingtable+TVARV
Similar Messages
-
How to create dynamic Connection String in SSIS Package???
Hi
I created OLEDB Source Connnection String for that Package,
i need Create OLEDB Destination Connection String Dynamically,
Same server name,but i need to add DW at the end of the Database
ex:
Source database name is Demo,
Destination database should come DemoDW.
i need to create Dynamic Destination Connection String..
any possible to Create
Thanks in advance
Pandiyan
pandiyanHi Pandiyanpvp,
According to your description, the OLEDB Destination Connection String should be dynamically based on the OLEDB Source Connection String. They are all the same, except adding “DW” at the end of the Database of OLEDB Source Connection String in OLEDB Destination
Connection.
To achieve this requirement, we can create a variable with the Database name of OLEDB Source Connection String, then use expression to control the OLEDB Source and OLEDB Destination Connection Strings. For more details, please refer to the following steps:
Create a variable named Source with the Database name of OLEDB Source Connection String as value.
Click the OLEDB Source Connection Manager to navigate to the Properties window.
Click “…” next to Expressions to add a ConnectionString Property with the expression like below:
"Data Source=.;Initial Catalog="+@[User::Source] + ";Provider=SQLNCLI11.1;Integrated Security=SSPI;Auto Translate=False;"
Click the OLEDB Destination Connection Manager to navigate to the Properties window.
Click “…” next to Expressions to add a ConnectionString Property with the expression like below:
"Data Source=.;Initial Catalog="+ @[User::Source] + "DB"+";Provider=SQLNCLI11.1;Integrated Security=SSPI;Auto Translate=False;"
If there are any other questions, please feel free to ask.
Thanks,
Katherine Xiong
Katherine Xiong
TechNet Community Support -
Create dynamic data type in structure
Hi Experts,
I am new to ABAP.
In my scenario data type is varying for the field. for that I need to create dynamic data type in structure, this structure I am using for internal table for OVS search input.
Please suggest the solution for this.
Advance thanks,
Regards,
BBCThanks for your quick reply,
I used your logic like this.
data:
ls_component type abap_componentdescr,
lt_component type abap_component_tab.
*... (1) define structure components :
clear ls_component.
ls_component-name = 'NVALUE'.
ls_component-type ?= cl_abap_typedescr=>describe_by_name( <fs_seg_v>-fieldname ).
insert ls_component into table lt_component.
*... (2) create structure
data lr_strucdescr type ref to cl_abap_structdescr.
data lr_data_struc type ref to data.
lr_strucdescr = cl_abap_structdescr=>create( lt_component ).
create data lr_data_struc type handle lr_strucdescr.
field-symbols <fs> TYPE any.
assign lr_data_struc->* to <fs>.
your logic is working fine.
here I am getting feild name (<fs_seg_v>-fieldname) from internal table.
But I need to assign same field name structure to query parameter.
FIELD-SYMBOLS: <ls_query_params> TYPE lty_stru_input.
Please can you suggest how I can refer the field name structure?
Regards,
BBC -
Problem with editable combo box and creating dynamic table values using js
Hai
I have used jquery.jec.js to make my dropdown list as editable... I need to create dynamic table values on the onChange event of dropdown using javascript.
Now am facing the problem in it...
I am getting duplicate rows in the table... think(assumption) this jquery.jec.js is calling the dropdown again creating duplicate values...
Please help me out.... Any help is appreciable... Thanks in advanceThanks elOpalo, for your valuable response....
I have found the correct way of doing.
Before i had my code like this,
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>test</title>
<script type="text/javascript" src="js/jquery-latest.js"></script>
<script type="text/javascript" src="js/jquery.jec.js"></script>
<script type="text/javascript">
$(function(){
$('#list').jec();
function giveAlert(){
alert('hello');
</script>
</head>
<body>
<form>
Combo Box:
<select id="list" name="list" onChange="giveAlert();">
<option value="1">one</option>
<option value="2">two</option>
</select>
</form>
</body>
</html>
Now i have changed as the following,
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>test</title>
<script type="text/javascript" src="js/jquery-latest.js"></script>
<script type="text/javascript" src="js/jquery.jec.js"></script>
<script type="text/javascript">
$(function(){
$('select.combo').jec();
$('select.combo')
.change(function() {
alert($(this).val());
}).change();
</script>
</head>
<body>
<form>
<table>
<tr>
<td>Combo Box:</td>
<td><select class="combo"><option value="b">banana</option><option value="a">apple</option></select></td>
</tr>
</table>
</form>
</body>
</html>
The problem is with the function i have called on the onChange Event.. Now i have defined it inside the jquery function of dropdown to make it as editable... -
Best way to create dynamic pdf's
I've a cfm template displaying an invoice (one image -logo,
and one table of
query results, invoice) to user.
It would be great to give them the option of downloading a
pdf of that page
(built dynamically from invoice id passed to the template).
I have mx6.something, not mx7, so am thinking cfdocument
isn't for me.
I am familair (only just) with cfcontent, but it's obvious I
need something
else to display the content as a pdf.
What is the best way to achieve this? Is the any free cfc's
or the like or?
Any help would be great, tks.
Cheers,
Lossed
__when the only tool you have is a hammer, everything looks
like a nail __Its a great feature with MX7 if you need to create dynamic
PDF's, however there is software out there that can dynamically
create them. One that I know of is located at
www.ActivePDF.com -
Creating dynamic link in column
Hi All,
I am using Jdev 11.1.1.2.0 . I am getting few urls that is comma seperated. I need to seperated different URL from the value and create no of link or golink equal to no of the value.Please suggest me how to do this.
I need to create dynamically link and put diffent url value in destination property of Link
How can i create dynamically link .I created a sample app for this. Please see if it is helpful.
http://adf-use-cases.googlecode.com/files/LinkApp.rar
I am displaying all the employees(first name) in a department as link. For now, the link is pointing to google. You can change according to your requirement.
The code is written in DepartmentVORowImpl.java
+public String getEmployeeName() {+
RowSet rowSet = getEmployees();
RowSetIterator ritr = rowSet.createRowSetIterator("new");
StringBuilder formattedLink = new StringBuilder("");
String requestURL = "http://www.google.com";
String hrefPrefix = "<a href='";
String targetProp = "' target='_blank' class='xfd' >";
String hrefSuffix = "</a>";
String employeeName = null;
+while (ritr.hasNext()) {+
Row row = ritr.next();
formattedLink.append(hrefPrefix).append(requestURL).append(targetProp).append(row.getAttribute("FirstName")).append(hrefSuffix).append(" | ");
ritr.next();
+}+
ritr.closeRowSetIterator();
rowSet.closeRowSet();
if (formattedLink != null && formattedLink.length() > 0)
employeeName =
formattedLink.substring(0, formattedLink.lastIndexOf(" | "));
return employeeName;
+}+ -
Creating dynamic dataTables **Very Urgent**
Hi all,
I m very new to JSF Technology. I m in need of creating dynamic dataTables. I need to populate the values from DB. At times, the number of columns varies. So, how can i create such kind of table? At least i need to know how can i create dataTable values using the Backing bean and mapping it to the JSF page, so that the browser will render that dataTable?
Please help me.. :)The following code (taken from the BalusC article) do the task:
// Create <h:column>.
HtmlColumn column = new HtmlColumn();
dynamicDataTable.getChildren().add(column);
// Create <h:outputText value="dynamicHeaders"> for <f:facet name="header"> of column.
HtmlOutputText header = new HtmlOutputText();
header.setValue(dynamicHeaders[i]);
column.setHeader(header);
// Create <h:outputText value="#{dynamicItem[" + i + "]}"> for the body of column.
HtmlOutputText output = new HtmlOutputText();
output.setValueExpression("value",
createValueExpression("#{dynamicItem[" + i + "]}", String.class));
column.getChildren().add(output); -
Hi,
When we need to create dynamic maxl scripts without using a batch commands or unix commands?Hi Nila,
I aggree with Daniel: you have to use a little bit more than MAXL to automate that. I dont know if you understand me correctly: You only need to create one shell script, 1st part: call maxl to export, 2nd part to manipulate the output, 3rd part to import the manipulated output.What I would like to say: You dont have to manipulate it manually. And after the creation the shell script can be scheduled to run every month, if you like... If you generally wouldnt like to use shell scripts you have a problem - I am not a MAXL guru but I would say it is not possible.
Kind regards
André -
Need to create a dynamic caption(column name) in a dynamic table
Hi All,
I have created dynamic table .But the dynamic column is not showing.I have created two column name that is name and empId .I have tried with following code
IWDCaption nameCap=(IWDCaption)view.createElement(IWDCaption.class,"nameCap");
nameCap.setText("Name");
tabColumn1.setHeader((IWDCaption)nameCap);
IWDCaption addCap=(IWDCaption)view.createElement(IWDCaption.class,"addCap");
addCap.setText("Address");
tabColumn2.setHeader((IWDCaption)addCap);
I m getting internal server error...But When i m comented the above code i can able to see tha dynamic table withput column name..Can anyone help me
SumanHi
IWDTableColumn tabColumn1 = (IWDTableColumn)view.createElement(IWDTableColumn.class,"N_Co");
IWDTableColumn tabColumn2 = (IWDTableColumn)view.createElement(IWDTableColumn.class,"A_Co");
IWDInputField nameText = (IWDInputField)view.createElement(IWDInputField.class,"N_Text");
nameText.bindValue(attrib1);
tabColumn1.setTableCellEditor((IWDTableCellEditor)nameText);
IWDInputField addText = (IWDInputField)view.createElement(IWDInputField.class,"A_Text");
addText.bindValue(attrib2);
tabColumn2.setTableCellEditor((IWDTableCellEditor)addText);
<b>I need to see the column name.....</b>
for that i have written the following code...
while writting the following code i m getting internal server error
IWDCaption nameCap = (IWDCaption)view.createElement(IWDCaption.class,"nameCap");
nameCap.setText("contribution_area");
tabColumn1.setHeader((IWDCaption)nameCap);
IWDCaption addCap=(IWDCaption)view.createElement(IWDCaption.class,"addCap");
addCap.setText("SUM");
tabColumn2.setHeader((IWDCaption)addCap); -
Dynamically need to create multiple text or select items.
Hi All,
There is a requirement in my application, we need to create multiple textbox or selectlist items, on click of "add" button in apex.
Any help on this how i can process the request to create multiple items dynamically on click of "add" button.
Regards,
Sruthitamiri!!APEX_ITEM
-
NEED HELP... Creating dynamic table from data file...
Hi
I'm writing an application for data visualization. The user can press the "open file" button and a FileChooser window will come up where the user can select any data file. I would like to take that data file and display it as a table with rows and columns. The user needs to be able to select the coliumns to create a graph. I have tried many ways to create a table, but nothing seems to work! Can anyone help me?! I just want to read from the data file and create a spreadsheet type table... I won't know how many rows and columns I'll need in advance, so the table needs to be dynamic!
If you have ANY tips, I'd REALLY appreciated.....Thank you for your help. I tried to use some of the code in the examples... I'm really new at this, so I'm not sure how to set it up. I added the code, but when I open a file, nothing happens. Here's the code I have so far...
package awt;
import java.awt.*;
import java.awt.event.*;
import java.io.*;
import java.net.*;
import java.util.*;
import javax.swing.*;
import javax.swing.event.*;
import java.text.*;
import javax.swing.border.*;
import javax.swing.table.*;
* @author
public class Main {
public static void main(String[] args) {
JFrame frame = new ScatterPlotApp();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.show();
class ScatterPlotApp extends JFrame implements ActionListener{
private JButton openButton, exitButton, scatButton, refreshButton;
private JMenuBar menuBar;
private JMenuItem openItem, exitItem;
private JFileChooser chooser;
private JMenu fileMenu;
private JTextPane pane;
private JTable table;
private DefaultTableModel model;
private JScrollPane scrollPane;
private Container contentPane;
/** Creates a new instance of ScatterPlotApp */
public ScatterPlotApp() {
setTitle("Data Visualizer");
Toolkit tk = Toolkit.getDefaultToolkit();
Dimension d = tk.getScreenSize();
int width = 867;
int height = 800;
setBounds((d.width - width)/2, (d.height - height)/2, width, height);
contentPane = getContentPane();
JPanel panel = new JPanel();
//pane = new JTextPane();
panel.setLayout(new FlowLayout(FlowLayout.CENTER));
contentPane.add(panel, BorderLayout.SOUTH);
//contentPane.add(pane, BorderLayout.NORTH);
scatButton = new JButton("Create ScatterPlot");
scatButton.addActionListener(this);
openButton= new JButton ("Open File");
openButton.addActionListener(this);
exitButton = new JButton ("Exit");
exitButton.addActionListener(this);
refreshButton = new JButton ("Reload Data");
refreshButton.addActionListener(this);
panel.add(openButton);
panel.add(scatButton);
panel.add(refreshButton);
panel.add(exitButton);
fileMenu = new JMenu("File");
openItem = fileMenu.add(new JMenuItem ("Open", 'O'));
openItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_O, Event.CTRL_MASK));
openItem.addActionListener(this);
exitItem = fileMenu.add(new JMenuItem ("Exit", 'X'));
exitItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_X, Event.CTRL_MASK));
exitItem.addActionListener(this);
JMenuBar menuBar = new JMenuBar();
fileMenu.setMnemonic('F');
menuBar.add(fileMenu);
setJMenuBar(menuBar);
public void actionPerformed(ActionEvent e){
Vector columnNames = new Vector();
Vector data = new Vector();
try{
Object source = e.getSource();
if (source == openButton || e.getActionCommand().equals("Open")){
chooser = new JFileChooser(".");
int status =chooser.showOpenDialog(this);
if (status ==JFileChooser.APPROVE_OPTION)
File file = chooser.getSelectedFile();
FileInputStream fin = new FileInputStream(file);
BufferedReader br = new BufferedReader(new InputStreamReader(fin));
String line;
//StringBuffer bf = new StringBuffer();
StringTokenizer st1 = new StringTokenizer(br.readLine(), ";");
while( st1.hasMoreTokens() )
columnNames.addElement(st1.nextToken());
// extract data
while ((line = br.readLine()) != null)
StringTokenizer st2 = new StringTokenizer(line, ";");
Vector row = new Vector();
while(st2.hasMoreTokens())
row.addElement(st2.nextToken());
data.addElement( row );
br.close();
model = new DefaultTableModel(data, columnNames);
table = new JTable(model);
scrollPane = new JScrollPane( table );
getContentPane().add( scrollPane, BorderLayout.NORTH );
while((line=br.readLine())!=null)
bf.append(line+"\n");
pane.setText(bf.toString());
//pane.setText(bf.toString());
else if (source == scatButton){
else if (source == exitButton || e.getActionCommand().equals("Exit")){
System.exit(0);
else if (source == refreshButton){
catch (Exception ex){
ex.printStackTrace();
} -
Need help populating dynamically-created fields
I have a form which uses Javascript to create table rows on
the fly so as to add items to a list dynamically. The table
consists of two fields -- an ID and let's call the other one
Attribute A. The user clicks "Add another one" and another row of
data entry fields pops up. My action page works fine to get the
value of these rows using the evaluate() function (I always
wondered what that did), but I want it to go back to the calling
page, have the calling page create the correct number of rows, and
populate them with the changed or inserted data that was just saved
-- the same way that an ordinary action page might save data and
then return you to the calling page.
The first row of this table is created through HTML and only
additional rows are created dynamically.
I have it all working up to and including the creation of the
correct number of fields as an "onload=(loadTheData)" in the
<body> tag, but how the heck and where do I populate them
with the data returned from the query?
Below is the Javascript and how it's called. I changed some
variable names to protect the innocent, but that's basically how it
works. So the Javascript is creating the fields -- one for each
record returned by the query -- but how can I assign the record
values in turn? Do I need WDDX? If so, how would that be
written?If you are going to use JavaScript to dynamically create the
list, then
look into the <cfwddx...> tag that is very useful for
translating
ColdFusion data structures into JavaScript data structures.
You can
then use the JavaScript data to populate your table.
But I would think it would be simplier to use the ColdFusion
data to
build the default table with existing data. Instead of just
creating
one row with ColdFusion create rows for the existing data
then just use
the JavaScript to add more rows on the client, just as you
are doing now.
P.S. evaluate() is usually an awkward choice to access
dynamical form
variables. I presume you are using something like
<cfset something = evaluate("form.aField_#aVar#")>
This can be easier with the use of array notation.
<cfset something = form['aField_' & aVar]>
OR
<cfset something = form['aField_#aVar#']>
To each his own, but knowing array notation is a very
powerful technique. -
Help needed in creating a dynamic poplist
Hi,
Can anybody please tell me how to create a dynamic poplist.
Can we create a dynamic poplist without using any controller code.
I have created a simple poplist for "Deptno".
Now I want to create a dynamic poplist for "Empname" , Which should be based on the 'Deptno' poplist entry.
When I select a department number from Deptno poplist, All the employees names under that perticular department should appear in my "Empname" poplist.
So please suggest me how to create "Empname" dynamic poplist.
Thanks,
Swaroopsee thread:
How to create dynamic poplist
--Mukul -
Creating dynamic value range, one week at a time
Every Monday, I query a table to get data for the past week, every Monday (last Monday) to Sunday. I do some calculations with the data and insert the data and dates into a table.
I then use cfchart to create a graph using this data. The drilldown uses the same weekly date range to produce a report. So the record count for the chart and the report should be the same.
What I just discovered is that more data can be added to the query table after I have already obtained the data. Since the data for the chart is already in the table, it is static. But the report is dynamice since it uses the weekly date range everytime the drilldown is selected. This causes the count of the report to be different than the count of the chart.
Instead of gathering data every Monday and inserting into a table, for the chart, how can I make the chart data dynamic ?
I need to plot a rolling 12 weeks worth of data, always from Monday to Sunday, inclusive. So if I decide to run the chart on a Wednesday, how would I gather the twelve weeks worth of data, always from Monday to Sunday ? I need to make this dynamc.
The reports always work because the drilldown is pasing it the dates, thats why the count is always correct. But I do not know how to do this with the chart, which needs to be dynamic also, since static will not work.
Any help appreciated. ThanksTrojfn,
For gathering the data and inserting the same in to a table, why can't you use the scheduled tasks?. -
How to mention numbers in array while creating dynamic sql
Hi,
I am creating a dynamic sql and in that I am selecting some rows from the table and storing it into the array.
I am firing this sql statement within trigger.
But i got the error:
ORA-06502: PL/SQL: numeric or value error: character to number conversion error
I took the same sql statement (the one which was created dynamically) in the procedure and tried to run it but it gave me the same error.
=========================================================
Begin
type NewValueArray is table of varchar2(4000);
nVal_Array NewValueArray;
Begin
Select
DISCOVERYHOSTNAME,
DISCOVERYMACPRIMARYPHYSICAL,
DISCOVERYSERIALNUMBER
into
nVal_Array(1),
nVal_Array(2),
nVal_Array(3)
from ALT_42_Consolidated
where rowid = 'AAEWNEABXAAAAkxAAA';
EXCEPTION
WHEN others THEN
Raise;
End;
=========================================================
I tried using to_number but still the same error.
Can some body please inform me where I am goofing.
Thanks!I got a different error, but you need to initialise your nval_array and make sure it can hold three values. The following should work:
declare
type NewValueArray is table of varchar2(4000);
nVal_Array NewValueArray := NewValueArray();
Begin
nval_array.extend(3);
Select col1, col2, col3
into nVal_Array(1), nVal_Array(2), nVal_Array(3)
from tab1
where rowid = 'AAAGJZAAGAAAAAWAAV';
EXCEPTION
WHEN others THEN
Raise;
End;
/
Maybe you are looking for
-
How do I install adobe flash player in Safari?
I enabled pop up windows, but it still gets cancelled in the activity window.
-
URGENT: CO and CO-PA Document
Hi! Are CO and CO-PA Documents different? May I know what are the differences? How do I explain what is a CO Document and CO-PA Documner to my user? From where do they get their values? Also, what does it mean by Company Document and Company Book. I
-
Wired clients going through AP-Manager interface
I've attached my config from my 2811. There are a couple things I can't figure out. Why is VLAN1 up / down? cao-va_colh#sh ip int brief Interface IP-Address OK? Method Status Protocol FastEthernet0/0 17
-
Picture problem on some channels
Hi I am new to Youview got my box yesterday not sure if this is normal but sometimes when I go to a channel I get a black screen with just audio. If I go up or down a channel then back to the channel I was on it ok. This only seems to happen on freev
-
Set time automatic does not stay checked
Just as the title says, the check box in the system prefs will not stay checked. I "Lock" the settings and when revisiting the setting after a reboot, it is unchecked and the time is still wrong. What do I need to do?? Thanks