Problem in looping data in variable window
Hi All,
I am using loop at and i am displaying data in VAR window. But every time it loops it over writing the data in VAR window and finally its printing only the last record in the loop. Can we loop all the data in the VAR window just like what we do in general for MAIN window.
Just try to use Text element and give the values to be printed under text element, in print program in pass the WRITE_FORM with text element in loop and Endloop.
I think we can not use Variable window to print records from an internal table, suppose if the data in first page is full in variable window, and if u use same variable window in second page, it starts printing from 1st record in second page also.
Regards
Bala Krishna
Similar Messages
-
Problem with packed data type variable?
Hi all,
I have a problem while doing calculations with packed data type variables . As they are saving in the format '0,00'. so unable to do calulations because of ',' .
To convert these fields into str and replacing ',' with '.' is very time consuming because i have many packed data type variables.
Can you please provide any other alternative for over coming this problem? Is there any option while defining these variables?
Thanks,
Vamshi.Hi VAMSHI KRISHNA,
First check out SU01 Tcode (if u don't have permission then u can ask BASIS to do it)
Enter User Name
Execute
Goto Defaults Tab
Check Out Decimal Notation here... set it 1,234,567.89
SAVE it
Log Off once and again login with the same user id and check the result...
Hope it will solve your problem..
Thanks & Regards
ilesh 24x7 -
Problem opening ODBC data source in Windows 2003
I am having difficulty opening a ODBC data source in SQL
Server 2000 running on Windows 2003 using ColdFusion MX7 (it works
cleanly on the same database on windows 2000 server). Anyone has
any ideas.Here it is, there is an issue with our Search functionality with the new SDN:
Symptom
When setting location on a Crystal Reports XI Report using the Progress OpenEdge ODBC Driver in Crystal Reports 2008 or Crystal Reports 2011 get “Some tables could not be replaced, as no match was found in the new data source. Please specify the table required for any unmodified tables.”
Environment
Crystal Reports 2008 or 2011
Progress OpenEdge ODBC Driver
Reproducing the Issue
Open a Crystal Report created in CR XI Report using the Progress OpenEdge ODBC Driver in Crystal Reports 2008 or 2011
Set location to a new ODBC Data Source
Get error "some tables could not be replaced, as no match was found in the new data source. Please specify the table required for any unmodified tables.”
Cause
Crystal Reports XI only creates aliases for tables with special characters or duplicate names.
Crystal Reports 2008 introduces a change which requires aliases for all tables.
Aliases are not created when doing a Set Location on the whole data source.
If a Customer has hundreds of reports they cannot set location of each table and fix the aliases.
Resolution
Upgrade to Crystal Reports 2011 Support Pack 02 or higher
Under registry key [HKEY_LOCAL_MACHINE\SOFTWARE\SAP BusinessObjects\Suite XI 4.0\Crystal Reports\Database\ODBC] create string UseTableNameAsAlias and set it to PGPRO1019.DLL, PGOE1022.DLL. Registry file is attached.
Keywords
Set Location
Progress ODBC
Crystal Reports 2008 2011 -
Hello Friends,
I have a problem in SAP scripts while printing an internal table data in to a variable window. It is overwriting the contents.
Ex:
In my internal table (itab) with only one filed (text) have the below data.
Firt line
second line
third line
fourth line
I am looping the internal table and within the loop I am calling the write form.
In script I am writing like below
&itab-text&
In the output I am getting only last line.
Output:
fourth line.
But I need to print all lines one by one.
Please help me.
Regards.
Krishna.You can't print internal table data in Variable window, you have to print them in Main window
The function module WRITE_FORM_LINES allows multiple lines to be APPENDED to a non-main window. You should note that the text lines must have the SAPscript ITF format. In the absence of other information, the system uses identically named formatting attributes (character and paragraph formats) of the form to format the content of the text lines.
Here is an approach which allows multiple records / lines to be output in a variable window.
If you transfer your information from the internal table into the text lines, complete with appropriate formatting symbols, you will find that the text lines are output nicely formatted in your non-Main window.
loop at internal table into WCSCATALOG.
clear tline.
tline-tdformat = 'S1'.
concatenate '<B>' WCSCATALOG-CODEX '</> ,, ' WCSCATALOG-STXT into ltline-tdline.
append tline to tlines.
endloop.
call function 'WRITE_FORM_LINES' -
Problem in printing data in main and secondary windows.
Hi,
I have embedded tables in main window and secondary window, which are supposed to print the same data.
The table in the main window is printing correctly even if the data over flows, but there is a problem with the secondary window in printing the table.
when the data over flows , it starts printing the same from the first line and so the data in both the windows do not match, so kindly help me fix this issue.Hi,
I have a possible approach. Just try and update accordingly.
While the data in main window prints, append a temporary table of same type inside the Main area. Now let the secondary window be of exact size as that of main window and copy-paste the same table node inside this window, but changing the table name (Loop at ITAB into WA) to the new table name, appended in main area, leaving everything else unchanged.
Now inside the temporary table loop in secondary window, create program lines and just refresh that table when number of entries in table equals sy-tabix or just set a flag for same and refresh table in footer.
Thus if main window prints 10 entries, then these will be appended in another table. The same 10 entries will be printed again in secondary window and while at last entry, table will be refreshed, thus ready for appending new entries from next page's main window.
Hope this helps.
Karthik -
Overflow of Main window data in to variable windows
Hi,
I have a following scenario. I have a main window . I defined some other variable windows below the main window. My problem is that when the data is full in main window it is not triggering page break and printing variable window in the next page. Instead, the data is priting in the first page it self mingling with the data of the variable windows. Any solutions please?Are you giving the next page as the second page in the first page General Attributes?
Have you checked any checkboxs in the conditions tab of the table node?
Regards,
Satish
Message was edited by:
Satish Panakala -
Facing problem in saving data without overlapping in for loop
Hi,
I am facing problem in writting data withou overlapping if i run outer loop for 2 or more times and in inner for loop i am getting array in a way I want but when i try to build that array with logging temperature i am not able to do it. Please guide me through ths.
Thank You
Hnagpal
Solved!
Go to Solution.
Attachments:
data storage.vi 31 KB
what i am getting.xlsx 10 KB
what i want.xlsx 10 KBThanks odessy27, Matthew Kelton, for replying.
Matthew Kelton: Thanks for the solution i am adding outer loop so that i can increase the number of row. I am using it for some application which require me to save data several time and i used random number here but originally instead of random number there will be power meter reading and i want to save it every hour and plot it. I am also attaching a file what i made I don't know is this a good way or not. Actually i will also beneeded to plot a graph. But again how to increase a row and without replacing previous data i can write another row.
Yes i want to make one row for each iteration.
I attached both files in 2009 version.
Thank You
Himanshu Nagpal
Attachments:
desired result.xlsx 10 KB
data storage (1).vi 26 KB
data storage.vi 37 KB -
SCRIPT LOOP IN VARIABLE WINDOW
HI
I WOULD LIKE TO KNOW HOW IS IT POSSIBLE TO HAVE MULTIPLE LINES ITEMS IN VARIABLE WINDOW IN SCRIPT.
THANX IN ADV
MANOJA variable window can have different contents on different pages. in the printprogram you arrange this.
The possible with looping lines like in the main window isnot in a VAR window (i think).
However you can put several lines in your VAR window and fill this directly in your printprogramm.
It works otherwise but functional it is the same. You only have a maximum lines in your window but
that is with all windows except the MAIN.
hope you can do something with this.
Regards, Frank -
I have problem with data transfer between Windows Server 2012RT and Windows7 (no more than 14kbps) while between Windows Sever 2012RT and Windows8.1 speed is ok.
Hi,
Regarding the issue here, please take a look at the below links to see if they could help:
Slow data transfer speed in Windows 7 or in Windows Server 2008 R2
And a blog here:
Windows Server 2012 slow network/SMB/CIFS problem
Hope this may help
Best regards
Michael
If you have any feedback on our support, please click
here.
Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. -
User Report data bind variable problems
Hello,
I am trying to build a simple report in SQLDeveloper, using a DATE bind variable. But it fails with the error message:
Inconsistent datatype, expected DATE got NUMBER
SELECT * FROM FLOW_COMP_REC_SUMMARY_RU
where create_date = trunc(:TARGET_DATE)
and type = 'D'
ORDER BY MESSAGE_FLOW_ID
Running this query in SQLDeveloper worksheet executes properly after a dialog box pops up and I enter: current_date - 1
SELECT * FROM FLOW_COMP_REC_SUMMARY_RU
where create_date = trunc(&TARGET_DATE)
and type = 'D'
ORDER BY MESSAGE_FLOW_ID
I've searched but no clear solutions present themselves. If you have one it would be most appreciated.
ThanksYou'll have to convert the input to date yourself:
SELECT * FROM FLOW_COMP_REC_SUMMARY_RU
where create_date = TO_DATE(:TARGET_DATE, 'DD/MM/YYYY')
and type = 'D'
ORDER BY MESSAGE_FLOW_ID
Have fun,
K. -
Data pump problem on sync data from windows to linux
Hi,
i have production db on windows 2003 server, and syn data from production windows machine to linux server. using data pump exports, imports.
i have written an procedure to export schema level
and
procedure for import like
dbms_datapump.open(operation ='import',job_module='schema',job_name='imp');
dbms_datapump.add_file(handle='',filename='imp.dmp',directory='dir_datapump',filetype=dbms_datapump.ku$_file_type_dump_file);
dbms_datapump.metadata_filter(handle='',name='schema_expr',value='in('hr','oe')',object_type''table');
dbms_datapump.set_parameter(handle ='',name=table_exists_action,value=replace);
when i run the above procedure, error displays that table already exists ora-31684
but from the
impdp include=table table_exists_action=replace
i am able to do it.
can u suggest what iam missing.
Regards
AjayI will try to explain a little better using screenshots. This screenshot is from windows :
http://img510.imageshack.us/img510/1714/windowspg.jpg
At the top is says 'date taken' and ANY windows photo library software will sort it by this date. Below are the properties of the same file after it's copied to osx :
http://img153.imageshack.us/img153/6345/screenshot20100322at145.png
It contains lots of information about the picture but not when it was taken. So software such as iphoto or picasa sorts it by it's created date (which you can see at the top is Monday 12th January).
Why isn't OSX carrying over the exif data on when the photo was taken ? I can't see any iphoto options to sort by that date.
Message was edited by: Ollie UK
Message was edited by: Ollie UK -
Problem getting correct data from MS Access after doing an Update
Hi all,
I have a problem getting correct data after doing an update. This is the scenario
I am selecting some(Eg: All records where Column X = �7� ) records and update a column with a particular value (SET Column X = �c� ) in all these records by going through a while loop. In the while loop I add these records to a vector too, and pass it as the return value.
After getting this return value I go through a for loop and get each record one by one from the DB and check if my previous update has actually happened. Since No errors were caught while updating DB, I assume all records are updated properly but my record set shows one after another as if it has not been updated. But if I open the DB it is actually updated.
This does not happen to all records, always it shows like this
1st record Mode = �c�
2nd record Mode = �7�
3st record Mode = �c�
4nd record Mode = �7�
9th record Mode = �c�
10th record Mode = �7�
I am relatively new to java and this is someone elses code that I have to modify,So I am not sure if there some thing wrong in the code too
//Here is the method that gets records and call to update and add to vector
public static Vector getCanceledWorkOrders() throws CSDDBException{
//Variable declaration
try {
objDBConn = DBHandler.getCSDBCon();
strSQL = "SELECT bal bla WHERE [Detailed Mode])=?)";
objStmt = objDBConn.prepareStatement(strSQL);
objStmt.setString(1, '7');
objWOPRs = objStmt.executeQuery();
while (objWOPRs.next()) {
//Add elements to a vector by getting from result set
//updating each record as PROCESSING_CANCELLED_WO(c)
iRetVal = WorkOrderDetailingPolicy.updateRecordStatus(objPWODP.iWorkOrderNumber, objPWODP.strPersonInformed, EMSConstants.PROCESSING_CANCELLED_WO);
if (iRetVal == -1) {
throw new NewException("Updating failed");
catch (Exception e) {
vecWONumbers = null;
throw new CSDDBException(e.getMessage());
}finally{
try {
objWOPRs.close();
objStmt.close();
DBHandler.releaseCSDBCon(objDBConn);
catch (Exception ex) {}
//return vector
//here is the code that actually updates the records
public static int updateRecordStatus(int iWONumber, String strPerInformed , String strStatus) throws CSDDBException{
PreparedStatement objStmt = null;
Connection objDBConn = null;
String strSQL = null;
int iRetVal = -1;
try{
objDBConn = DBHandler.getCSDBCon();
objDBConn.setAutoCommit(false);
strSQL = "UPDATE Table SET [Detailed Mode] = ? WHERE bla bla";
objStmt = objDBConn.prepareStatement(strSQL);
objStmt.setString(1, strStatus);
objStmt.execute();
objDBConn.commit();
iRetVal = 1;
}catch(Exception e){
iRetVal = -1;
}finally{
try{
objStmt.close();
DBHandler.releaseCSDBCon(objDBConn);
}catch(Exception ex){}
return iRetVal;
//Here is the code that call the records again
public static WorkOrderDetailingPolicy getWorkOrders(int iWorkOrderNo) throws CSDDBException{
Connection objDBConn = null;
PreparedStatement objStmt = null;
ResultSet objWOPRs = null;
WorkOrderDetailingPolicy objPWODP = null;
String strSQL = null;
try {
objDBConn = DBHandler.getCSDBCon();
strSQL = "SELECT * FROM [Work Order Detailing] WHERE [Work Order No] = ?";
objStmt = objDBConn.prepareStatement(strSQL);
objStmt.setInt(1, iWorkOrderNo);
objWOPRs = objStmt.executeQuery();
if (objWOPRs.next()) {
objPWODP = new WorkOrderDetailingPolicy();
objPWODP.iWorkOrderNumber = objWOPRs.getInt("Work Order No");
//......Get Record values
catch (Exception e) {
objPWODP = null;
throw new CSDDBException(e.getMessage());
}finally{
try {
objWOPRs.close();
objStmt.close();
DBHandler.releaseCSDBCon(objDBConn);
catch (Exception ex) {}
return objPWODP;
}Hello,
Can you put an example of your problem online?
Are you sure you're not having problems with case sensitive data?
Thanks,
Dimitri -
What exactly is the diff between main window and variable window
what exactly is the diff between main window and variable window in SAP script?
hi,
MAIN WINDOW :- In a main window you display text and data, which can cover several pages (flow text). As soon as a main window is completely filled with text and data, the system continues displaying the text in the main window of the next page. It automatically triggers the page break.
You can define only have one window in a form as main window.
The main window must have the same width on each page, but can differ in height.
A page without main window must not call itself as next page, since this would trigger an endless loop. In such a case, the system automatically terminates after three pages.
VARIABLE WINDOW :- The contents of variable windows is processed again for each page, on which the window appears. The system outputs only as much text as fits into the window. Text exceeding the window size is truncated; the system does not trigger a page break. Unlike constant windows, the page windows declared as variable windows may have different sizes on different form pages.
As far as the processing of the window contents is concerned, the system currently treats constant and variable windows alike. The only difference is that constant windows have the same size throughout the form.
hope this will be useful.
If useful then reward points.
with regards,
Syed -
Printing problems MATRIXx 7.1.4 on Windows 2000
I am running MX 714 on a Windows 200 machine have problems printing.
From a graphics window when I select File>Print and select the desired printer I get.
pop-up window: hardlnx.exe - Application Error (instruction at "0x00401c23" referenced memory at "0x0000000008". The memory could not be "read".
I get the following message in the xmath window:
***A*** Process c:\data\ni\mx714\mx_71.4\xmath\modules\basic/hardlnx.exe failed to load (system error).
[main._stat4] = (define `hardlnx') (filnam, fileType, file, color, [xscale;yscale], portrait, res, print, _hpglOptions, window_id, render, hcsize);
The printer is networked and shared.
hardcopy:
hardcopy print="c:\data\ni\mx714\mx_71.4\xmath\bin\xmprint T0016005",{fg, portrait}
c:\data\ni\mx714\mx_71.4\xmath\bin\xmprint T0016005 C:\DOCUME~1\BT003232\LOCALS~1Temp/XmathGraphics1116.ps
[printing to T0016005 ...]
But nothing is send to the printer??
No further error messages.
What can I do.
BrianNick,
I have access to 4 networked printers (no local devices available)
HP LaserJet 5M (default)
2 HP Color LaserJet 4550 PS
Xerox WorkCentre Pro65 PS
(under Printers it reads e.g. T0016005 on ipp://clprt1.nwip.canadair.ca for the default LasetJet)
From the Graphics Window, I select File > Print.
I then get the Print Pop-Up window displayed.
I select the Printer I want to use and Select OK.
The print window dissappears and the error message window pops-up
The "hardlnx.exe" file is there and I can do "what hardlnx" and hardlnx -> which gives message used in invalid context.
I can create hardcopy files:
hardcopy file="c:\temp.ps", {fg,portrait} , also eps, emf, pict work as well.
Question: Should there be any NI System Environment Variables set?
e.g. I run hardcopy without any other keywords and get .. no default printer defined..
How do I set this? If I type set XMATH_PRINT=c:\........\xmprint T0016005 in a DOS window, it sets some sort of environment variable, but MATRIXx doesn't find this.
MATRIXx seems happier if I go through the Control Panel -> System -> Advanced -> Environment Variables and Add a new one called XMATH_PRINT but this is not straight forward.
After adding the XMATH_PRINT it appears to accept the printer, ...printing on T0016005.. but nothing comes out.
I do not have problems printing from any other application.
Thanks
Brian -
Problem with OEM backing up on windows system.
Hi to all,
I have a problem with backing up with a specific user.
I am currently running various "test" db's and am planning to back them up.
The Setup:
Host OS is windows 2003 server s2
Grid control 10.2.0.1
Database 10.2.0.2
Target Db is running on a windows 2003 server
The Situation:
From grid control I locate the db in question and go to the maintenance page and the backup settings. First of all I want to test the backup using the tab. Before this of course I enter the Host OS credentials into the system, let’s say "jamie", and add the appropriate password. By this point I have made sure that the user "jamie" is in the local security policy setting "log on as batch job" and that is in the group ora_dba (This is on both the machine I am backing up from and the target db machine.). For security reasons I have limited the share folder location to the user "jamie", making sure that sharing and security has the appropriate privileges to access the share.
I run a test backup using the tab within backup settings and await the results. The results come back unsuccessful. Reading through the log I see that the path to backup share is denied.
So to further the test I change the privileges within the share to "everyone" and that is for both sharing and security, just to see whether or not it’s the path itself rather than restrictions to the user. It is then a success. I checked to see who actually owned the file that was used within the test. It belonged to the local system on the target db, not to the user that I had specified within "Host OS Credentials".
Can anyone explain to me why and what is the reason behind putting in Host OS Credentials when the agent that is committing the back up is using the local domain system user account. I am aware that the Agent is part of a service within windows and belongs to the local domain. Ergo, why have host credentials.
And can anyone help me out with getting round this predicament if I still want security within the systems. I can’t just leave access to the share under "everyone", that'd be a really big hole in the system?!
Any help at all will be gratefully received.
If you’ve got any questions to help me solve the problem, please fire away.You may want to take a look at these metalink notes:
Ref.
Subject: ERROR in RMAN to Write to Shared Drives on Windows NT/2000
Doc ID: Note:246107.1 Type: PROBLEM
Last Revision Date: 08-JUL-2004 Status: PUBLISHED
Subject: How to Configure RMAN to Write to Shared Drives on Windows NT/2000
Doc ID: Note:145843.1 Type: BULLETIN
Last Revision Date: 21-OCT-2005 Status: PUBLISHED
~ Madrid
http://hrivera99.blogspot.com/
Maybe you are looking for
-
Ran the upgrade on Monday. Not a grid. Single instance. It failed and we were forced to roll back using an OS backup... The database upgrade assistant failed with an error that it 'could not complete the Enterprise Manager configuration with the foll
-
Changing my Apple ID account on my iPhone?
So I changed my Apple ID account on my iPhone and I can't update my old apps and I can't download apps I had before withy old Apple ID because it doesn't give me the option to download... How can I get my apps back?! Please help!
-
JDBC SQL Server Channel Calling Stored Procedure Won't Return Result Set
Good afternoon, Experts We're calling a stored procedure in a sender communcation channel. I can perform any SQL SELECT statement here, but for some reason when I execute the SP (EXECUTE StoredProcedureName) The Adapter Engine returns the following:
-
Installed FF 15 (32 bit) on a fresh copy of Windows 7 Ultimate edition (x64). Everything works fine except the embedded video. The video clip thumbnail is shown, when clicking on the clip the sound plays and the right-mouse click shows flash player o
-
Selection Screen - can it be better ?
Hello Experts, My selection screen contains about 15 selection (variables). They are shown as an flat list of input fields. Some blocks of this variables are in an relationship. In an normal ABAP selection-screen I would group it into blocks. Some va