CX_SY_CONVERSION_NO_NUMBER?While uploading an Excel File.
Hi,
I am trying to upload an excel which contains customer number, shipping point details , time details....... The upload program was working before upgrade to ECC 6.0.
But right now when i try to uplaod the file i get the following dump messege.
Unable to interpret "*000" as a number.
Can anyone tell me what is the correct number format and how I can resolve this problem.
Regards,
MD
Hi
You may check the excel value ,this error show you ,it's not a number!
thanks
Edited by: Tom zhang on Jul 3, 2009 3:37 AM
Similar Messages
-
Hi,
I am getting an error while trying to upload a excel file. I am using the function HR_KR_XSTRING_TO_STRING for conversion. The error message is "Unable to interpret as a number"First of all, are you sure you know what you are working with here. If this is standard Excel file in the Microsoft binary/propriatery format there is not function module or class in ABAP that can magically just transform this to a character string. You should search the forums as this has been discussed extensively. On that topic, please also do not post duplicate threads. I have already locked your other thread with the same basic question.
Instead of the binary/propriatery format of Excel, the file should be saved on the client as a text based format - like XML or Text Tab Delimited. You can then use several different options on the server to convert the XSTRING to STRING and process the content (becuase it was text based to begin with). You could use CL_BCS_CONVERT, the function modules in the function group SCMS_CONV, or the class CL_ABAP_CONV_IN_CE. -
ADF 11g : Live messages about status/errors while uploading a Excel file
Hi,
Im using ADF 11.1.1.2. In the ADF application, there is a module where the user will upload a excel sheet with lot of data(50,000 lines) in multi sheets. We are validating the data against certain business validations and inserting this data into Database tables once all the validations are successful. In case any validation errors are there we write them into a log file and send it to the user.
Now the requirement we are stuck with is to show the validation messages/errors on a screen while the upload is in progress. The messages are to be live i.e in case now the code is validating row 10 and there is a error then that error message with row number is to be displayed on the screen and when the validation process continues with row 11, we need to show message saying 'Row 11 validation in process...'.
thanks,
Manasa.For this you can use a progress bar together with an DefaultBoundedRangeModel where you run the validation in a thread. This thread put the messages somewhere where the UI picks them up.
On the other side, your requirement is hard to do. I did some math: 50,000 records to validate and you want to show a message for each row; If each message need only a second you end up with more then 12 hours of work. Nobody will stare at the screen for that long. If the validation takes longer then a second it gets worse. If you show the message for less then a second, the user can read it anyway, so you don't need to show a message for every row.
We do this kind of work in the background. The user has to ask for the progress of the process and can look at errors reported so far. This way the user can do something else even if the job runs for a long time.
Timo -
Hi,
I am getting an error while uploading an excel file in web Dynpro application. i am using the HR_KR_XSTRING_TO_STRING this function. I am getting the following error message 'Unable to interpret as a number'.First of all, are you sure you know what you are working with here. If this is standard Excel file in the Microsoft binary/propriatery format there is not function module or class in ABAP that can magically just transform this to a character string. You should search the forums as this has been discussed extensively. On that topic, please also do not post duplicate threads. I have already locked your other thread with the same basic question.
Instead of the binary/propriatery format of Excel, the file should be saved on the client as a text based format - like XML or Text Tab Delimited. You can then use several different options on the server to convert the XSTRING to STRING and process the content (becuase it was text based to begin with). You could use CL_BCS_CONVERT, the function modules in the function group SCMS_CONV, or the class CL_ABAP_CONV_IN_CE. -
I would like to upload a excel file using jsp
Hi,
I would like to upload the excel file using jsp in my netbeans ide. Please help.
I don Know what is the error in this jsp file. It is not showing any thing and the file is also not getting uploaded.
Please gothru the code below.
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ page import="java.io.*" errorPage="err.jsp"%>
<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link href="<html:rewrite page="/design.css" />" rel="stylesheet" type="text/css">
<title>Upload Page</title>
</head>
<body onKeyDown="DisablingBackFunctionality()" onLoad="DisablingBackFunctionality()">
<html:form action="download" >
<div style="position:absolute; left:100;top:200;">Select an excel File :<input type="file" name="uploadfile"></div>
<div style="position:absolute; left:190;top:250;"><input type="submit" name="Submit" value="Read"></div>
<div style="position:absolute; left:336;top:250;"><input type="reset" name="Reset" value="Clear"></div>
mainmenu
</html:form>
</body>
</html>
<%
String contentType = request.getContentType();
if ((contentType != null) && (contentType.indexOf("multipart/form-data") >= 0)) {
DataInputStream in = new DataInputStream(request.getInputStream());
int formDataLength = request.getContentLength();
byte dataBytes[] = new byte[formDataLength];
int byteRead = 0;
int totalBytesRead = 0;
while (totalBytesRead < formDataLength) {
byteRead = in.read(dataBytes, totalBytesRead, formDataLength);
totalBytesRead += byteRead;
String file = new String(dataBytes);
//out.println("<br> file :"+file);
String saveFile = file.substring(file.indexOf("filename=\"") + 10);
//out.println("<br> savefile :"+saveFile);
saveFile = saveFile.substring(0, saveFile.indexOf("\n"));
//out.println("<br> now file1 :"+saveFile);
saveFile = saveFile.substring(saveFile.lastIndexOf("\\") + 1, saveFile.indexOf("\""));
//out.println("<br> now file2 :"+saveFile);
//out.print(dataBytes);
String ext = "";
if (saveFile.indexOf(".") != -1) {
ext = saveFile.substring(saveFile.lastIndexOf("."));
int lastIndex = contentType.lastIndexOf("=");
//out.println("<br>lst index of"+lastIndex);
String boundary = contentType.substring(lastIndex + 1, contentType.length());
//out.println("<br> boundary"+boundary);
//out.println("<br> file :"+file);
int pos;
pos = file.indexOf("filename=\"");
//out.println("<br> now 0 :"+pos);
pos = file.indexOf("\n", pos) + 1;
//out.println("<br>now 1 :"+pos);
pos = file.indexOf("\n", pos) + 1;
//out.println("<br>now 2 :"+pos);
pos = file.indexOf("\n", pos) + 1;
//out.println("<br>now 3"+pos);
int boundaryLocation = file.indexOf(boundary, pos) - 4;
int startPos = ((file.substring(0, pos)).getBytes()).length;
int endPos = ((file.substring(0, boundaryLocation)).getBytes()).length;
FileOutputStream fileOut = new FileOutputStream("D:\\" + saveFile);
//FileOutputStream fileOut = new FileOutputStream(saveFile);
//fileOut.write(dataBytes);
fileOut.write(dataBytes, startPos, (endPos - startPos));
fileOut.flush();
fileOut.close();
session.setAttribute("fil", saveFile);
//out.println("File saved as " +saveFile);
%>
<script type="text/javascript" >
function DisablingBackFunctionality()
var URL;
var i ;
var QryStrValue;
URL=window.location.href ;
i=URL.indexOf("?");
QryStrValue=URL.substring(i+1);
if (QryStrValue!='X')
window.location=URL + "?X";
</script>
Please let me know the result as soon as possible. Its my very urgent.
Thanking Yu,
Muthu Kumar.RNo.
Mylenium -
I'm doing a test on uploading an Excel file using JAVA. Right now I have my code set up to upload to an Access database. Everything works great except the last record in my Excel file is not being uploaded. I can make it load the last record by adding redundant code { stSQL.executeUpdate(strSQL); }
outside the loop as shown below. This doesn't really make sense to me since I am printing the last SQL statement twice, once inside the loop and once outside the loop so why the SQL statement isn't executed is beyond me. Any thoughts? Thanks,
import java.io.*;
import java.sql.*;
import java.util.regex.*;
public class UploadExcel{
public static void main(String[] args){
Connection connection = null;
String TableName = "GSABill";
String strBeginSQL = "INSERT INTO " + TableName + " VALUES( ";
try{
int iCount = 0;
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection con = DriverManager.getConnection( "jdbc:odbc:Driver={Microsoft Excel Driver (*.xls)};DBQ=c:/test3.xls;DriverID=22;READONLY=false;" );
Connection Access = DriverManager.getConnection("jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)}; DBQ=c:/temp/test.mdb;Uid=Admin;Pwd=;");
Statement st = con.createStatement();
Statement stSQL = Access.createStatement();
ResultSet rs = st.executeQuery( "Select * from [Sheet1$]" );
ResultSetMetaData rsmd = rs.getMetaData();
int numberOfColumns = rsmd.getColumnCount();
int rows;
String strSQL;
strSQL = "";
while (rs.next()) {
strSQL = strBeginSQL;
iCount++;
strSQL = strBeginSQL + iCount + ", ";
for (int i = 1; i <= numberOfColumns; i++) {
String columnValue = rs.getString(i);
try{
if (!columnValue.equals("")){
strSQL = strSQL.substring(0, strSQL.length()-1) + "'" + columnValue + "', ";
} else {
strSQL = strSQL.substring(0, strSQL.length()-1) + "'', ";
} catch(Exception e) {
strSQL = strSQL.substring(0, strSQL.length()-1) + "'', ";
strSQL = strSQL.substring(0, strSQL.length() - 2) + ")";
System.out.println(strSQL);
stSQL.executeUpdate(strSQL);
System.out.println(strSQL);
stSQL.executeUpdate(strSQL);
stSQL.close();
st.close();
con.close();
} catch(Exception ex) {
System.err.print("Exception: ");
System.err.println(ex.getMessage());jsp file upload code (any type of file): (fileUpload.jsp)
<%@ page import="java.io.*,javax.servlet.http.HttpServletRequest,javax.servlet.ServletInputStream" %>
<%@ page import="java.io.FileWriter,java.io.IOException" %>
<%
String savePath = "", filepath = "", filename = "";
String contentType = "", fileData = "", strLocalFileName = "";
int startPos = 0;
int endPos = 0;
%>
<%!
//copy specified number of bytes from main data buffer to temp data buffer
void copyByte(byte [] fromBytes, byte [] toBytes, int start, int len)
for(int i=start;i<(start+len);i++)
toBytes[i - start] = fromBytes;
%>
<%
int BOF = 0, EOF = 0;
contentType = request.getContentType();
out.println("<br>Content type is :: " +contentType);
if ((contentType != null) && (contentType.indexOf("multipart/form-data") >= 0))
DataInputStream in = new DataInputStream(request.getInputStream());
DataInputStream in1 = in;
int formDataLength = request.getContentLength();
byte dataBytes[] = new byte[formDataLength];
int byteRead = 0;
int totalBytesRead = 0;
while (totalBytesRead < formDataLength)
byteRead = in1.read(dataBytes, totalBytesRead, formDataLength);
totalBytesRead += byteRead;
out.println("<br>totalBytesRead : " + totalBytesRead + " : formDataLength = " + formDataLength);
//String file = new String(dataBytes);
//out.println("<br>File Contents:<br>////////////////////////////////////<br>" + file + "<br>////////////////////////////////<br>");
byte[] line = new byte[128];
if (totalBytesRead < 3)
return; //exit if file length is not sufficiently large
String boundary = "";
String s = "";
int count = 0;
int pos = 0;
//loop for extracting boundry of file
//could also be extracted from request.getContentType()
do
copyByte(dataBytes, line, count ,1); //read 1 byte at a time
count+=1;
s = new String(line, 0, 1);
fileData = fileData + s;
pos = fileData.indexOf("Content-Disposition: form-data; name=\""); //set the file name
if(pos != -1)
endPos = pos;
}while(pos == -1);
boundary = fileData.substring(startPos, endPos);
//loop for extracting filename
startPos = endPos;
do
copyByte(dataBytes, line, count ,1); //read 1 byte at a time
count+=1;
s = new String(line, 0, 1);
fileData = fileData + s;
pos = fileData.indexOf("filename=\"", startPos); //set the file name
if(pos != -1)
startPos = pos;
}while(pos == -1);
do
copyByte(dataBytes, line, count ,1); //read 1 byte at a time
count+=1;
s = new String(line, 0, 1);
fileData = fileData + s;
pos = fileData.indexOf("Content-Type: ", startPos);
if(pos != -1)
endPos = pos;
}while(pos == -1);
filename = fileData.substring(startPos + 10, endPos - 3); //to eliminate " from start & end
strLocalFileName = filename;
int index = filename.lastIndexOf("\\");
if(index != -1)
filename = filename.substring(index + 1);
else
filename = filename;
//loop for extracting ContentType
boolean blnNewlnFlag = false;
startPos = endPos; //added length of "Content-Type: "
do
copyByte(dataBytes, line, count ,1); //read 1 byte at a time
count+=1;
s = new String(line, 0, 1);
fileData = fileData + s;
pos = fileData.indexOf("\n", startPos);
if(pos != -1)
if(blnNewlnFlag == true)
endPos = pos;
else
blnNewlnFlag = true;
pos = -1;
}while(pos == -1);
contentType = fileData.substring(startPos + 14, endPos);
//loop for extracting actual file data (any type of file)
startPos = count + 1;
do
copyByte(dataBytes, line, count ,1); //read 1 byte at a time
count+=1;
s = new String(line, 0, 1);
fileData = fileData + s;
pos = fileData.indexOf(boundary, startPos); //check for end of file data i.e boundry value
}while(pos == -1);
endPos = count - boundary.length();
//file data extracted
out.println("<br><br>0. Local File Name = " + strLocalFileName);
out.println("<br><br>1. filename = " + filename);
out.println("<br>2. contentType = " + contentType);
out.println("<br>3. startPos = " + startPos);
out.println("<br>4. endPos = " + endPos);
out.println("<br>5. boundary = " + boundary);
//create destination path & save file there
String appPath = application.getRealPath("/");
out.println("<br>appPath : " + appPath);
String destFolder = appPath + "images/banner/";
filename= destFolder + filename;
FileOutputStream fileOut = new FileOutputStream(filename);
fileOut.write(dataBytes, startPos, (endPos - startPos));
fileOut.flush();
fileOut.close();
out.println("<br>File saved as >> " + filename);
//file saved at destination
//out.println("<br>File data : <br><br>**************************<br>" + (new String(dataBytes,startPos, (endPos - startPos))) + "<br><br>**************************");
else
out.println("Error in uploading ");
%>
supporting html file:
<form method="post" action="fileUpload.jsp" name="upform" enctype="multipart/form-data">
<table width="60%" border="0" cellspacing="1" cellpadding="1" align="center" class="style1">
<tr>
<td align="left"><b>Select a file to upload :</b></td>
</tr>
<tr>
<td align="left">
<input type="file" name="uploadfile" size="50">
</td>
</tr>
<tr>
<td align="left">
<input type="hidden" name="todo" value="upload">
<input type="submit" name="Submit" value="Upload">
<input type="reset" name="Reset" value="Cancel">
</td>
</tr>
</table>
</form>
</body>
</html> -
Help with uploading an excel file to a table using an application
Hello,
Can anyone please help me out with this issue. I have apex application where in the end users upload an excel file to a table. For this I have followed the solution provided in this link
http://avdeo.com/2008/05/21/uploading-excel-sheet-using-oracle-application-express-apex/
Using the above solution, I was able to upload the excel data to a table "sample_tbl1" successfully with fields Id,acct_no,owner_name,process_dt. But the thing is I want accomdate a particular condition while uploading the file data, to check see if the acct_no already exists in another table say "sample_tbl2" or not. If acct_nos already exists in sample_tbl2 then give out an error displaying the list of account numbers that already exists in the database. Below is the code which I am using to upload file data to a table.
DECLARE
v_blob_data BLOB;
v_blob_len NUMBER;
v_position NUMBER;
v_raw_chunk RAW(10000);
v_char CHAR(1);
c_chunk_len number := 1;
v_line VARCHAR2 (32767) := NULL;
v_data_array wwv_flow_global.vc_arr2;
v_rows number;
v_sr_no number := 1;
l_cnt BINARY_INTEGER := 0;
l_stepid NUMBER := 10;
BEGIN
--Read data from wwv_flow_files</span>
select blob_content into v_blob_data
from wwv_flow_files
where last_updated = (select max(last_updated) from wwv_flow_files where UPDATED_BY = :APP_USER)
and id = (select max(id) from wwv_flow_files where updated_by = :APP_USER);
v_blob_len := dbms_lob.getlength(v_blob_data);
v_position := 1;
/* Evaluate and skip first line of data
WHILE (v_position <= v_blob_len ) LOOP
v_raw_chunk := dbms_lob.substr(v_blob_data,c_chunk_len,v_position);
v_char := chr(hex_to_decimal(rawtohex(v_raw_chunk)));
v_line := v_line || v_char;
v_position := v_position + c_chunk_len;
-- When a whole line is retrieved
IF v_char = CHR(10) THEN
-- Clear out
v_line := NULL;
EXIT;
END IF;
END LOOP;
-- Read and convert binary to char</span>
WHILE ( v_position <= v_blob_len ) LOOP
v_raw_chunk := dbms_lob.substr(v_blob_data,c_chunk_len,v_position);
v_char := chr(hex_to_decimal(rawtohex(v_raw_chunk)));
v_line := v_line || v_char;
v_position := v_position + c_chunk_len;
-- When a whole line is retrieved </span>
IF v_char = CHR(10) THEN
-- Convert comma to : to use wwv_flow_utilities </span>
v_line := REPLACE (v_line, ',', ':');
-- Convert each column separated by : into array of data </span>
v_data_array := wwv_flow_utilities.string_to_table (v_line);
-- Insert data into target table
EXECUTE IMMEDIATE 'insert into sample_tbl1(ID,ACCT_NO,OWNER_NAME,PROCESS_DT)
values (:1,:2,:3,:4)'
USING
v_sr_no,
v_data_array(1),
v_data_array(2),
to_date(v_data_array(3),'MM/DD/YYYY');
-- Clear out
v_line := NULL;
v_sr_no := v_sr_no + 1;
l_cnt := l_cnt + SQL%ROWCOUNT;
END IF;
END LOOP;
delete from wwv_flow_files
where last_updated = (select max(last_updated) from wwv_flow_files where UPDATED_BY = :APP_USER)
and id = (select max(id) from wwv_flow_files where updated_by = :APP_USER);
l_stepid := 20;
IF l_cnt = 0 THEN
apex_application.g_print_success_message := apex_application.g_print_success_message || '<p><span style="font-size:14;font-weight:bold">Please select a file to upload.</span></p>' ;
ELSE
apex_application.g_print_success_message := apex_application.g_print_success_message || '<p><span style="font-size:14;font-weight:bold;color:green">File uploaded and processed ' || l_cnt || ' record(s) successfully.</span></p>';
END IF;
l_stepid := 30;
EXCEPTION WHEN OTHERS THEN
ROLLBACK;
apex_application.g_print_success_message := apex_application.g_print_success_message || '<p><span style="font-size:14;font-weight:bold;color:red">Failed to upload the file. '||REGEXP_REPLACE(SQLERRM,'[('')(<)(>)(,)(;)(:)(")('')]{1,}', '') ||'</span></p>';
END;
{code}
Can anyone please help me, how do i accomdate the condition within my existing code.
thanks,
OrtonOrton,
From your code it appears that the account No comes in the second column of the file = > v_data_array(1)
So You can put a conditional block around the execute immediate code that inserts the records
For instance
SELECT count(1) INTO ln_account_no_exists from <"sample_tbl2> where account_no = v_data_array(1);
IF ( ln_account_no_exists > 0 ) THEN
--Account No: already exists
<Do what you want to do here >
ELSE
EXECUTE IMMEDIATE ...
END IF:
{code}
Inorder to handle the account no records which exists you can
<li>Raise an exception
<li> Write record to table or insert into collection and then use a report region in the page based on this table/collection to show error records
<li> Append errored account No:s to the Success Message Variable programmatically(this variable is used by PLSQL process success/error message )
{code}
IF ( record exists)
apex_application.g_print_success_message := apex_application.g_print_success_message||','|| v_data_array(1) ; -- Comma separated list of errored account no:s
ELSE ...
{code}
Hope it helps -
Upload an excel file to table data
Hi ,
I could succesfully develope an application for uploading an excel file and displaying the data in tabular format (i.e through table display ) . But on Action <<Export TO Table>> it is not showing the details in tabular format . After uploadinfg file it is providing successful msg but when i m clicking on Export to table it is not displaying table data .
Its a demo WD program in java given below
Could anybody please guide me in this approach ?
public void onActionUploadFileData(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
InputStream text = null;
int temp = 0 ;
String path ;
try
File file = new File(wdContext.currentContextElement().getResource().getResourceName().toString());
FileOutputStream output = new FileOutputStream(file);
if (wdContext.currentContextElement().getResource()!= null )
text = wdContext.currentContextElement().getResource().read(false);
while ((temp=text.read())!= -1)
output.write(temp);
output.flush();
output.close();
path = file.getAbsolutePath();
wdComponentAPI.getMessageManager().reportSuccess(path);
catch (Exception ex)
ex.printStackTrace();
public void onActionExport_To_Table(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
//@@begin onActionExport_To_Table(ServerEvent)
try {
Workbook workbook = Workbook.getWorkbook(new File(path));
Sheet sheet = workbook.getSheet(0);
int columns = sheet.getColumns();
int rows = sheet.getRows();
int i=0;
int j;
for (j=1;j<=rows;j++)
element = wdContext.nodeTableData().createTableDataElement();
Cell cell1 = sheet.getCell(i,j);
element.setEmpId(cell1.getContents());
Cell cell2 = sheet.getCell(i+1,j);
element.setFirstname(cell2.getContents());
Cell cell3 = sheet.getCell(i+2,j);
element.setLastname(cell3.getContents());
wdContext.nodeTableData().addElement(element);
catch (Exception ex)
ex.printStackTrace();
Edited by: Trina_Saheli on Feb 26, 2010 4:22 PMHi Trina,
Check onAction method(onActionExporttotable) of "Export to Table ". Print the c1.getContents(), c2.getContents,c3.getContents value with MessageManager while setting vaule to node attribute.
Once the all the attribute added to node TableData, print the table attribute in onActionExporttotable method itself.
Also check the TableData node properties which is bind to table of displaying in the screen.
Hopt it helps
Regards,
Arun -
Warning while downloading an Excel file from WD ABAP
Hi folks,
In one of requirements, Client wants to download all the data that is appearing on the screen ( WD ABAP Application ) to an Excel with a layout in different manner.
We achieved this with Simple Transformations.
Now the question is while downloading the excel file, the framework/other is throwing an Warning like
" The file you are trying to open, 'info.xls', is in a different format than specified by the extension. Verify that the file is not corrupted and is from a trusted source before opening the file. Do you want to open the file now? "
Note: All the users of my client are using MS Office 2002 / 2003.
I am using the following code........!
*------ Call Transformation for Excel OUTPUT
CALL TRANSFORMATION ZEXCEL_OUTPUT
SOURCE
t_dates = t_dates
t_info = t_info
RESULT XML l_xml_string.
REPLACE ALL OCCURRENCES OF '<?xml version="1.0" encoding="utf-16"?>' l_xml_string WITH '<?xml version="1.0"?><?mso-application progid="Excel.Sheet"?>'.
**-- Call Function Module for converting string data to XSTRING
CALL FUNCTION 'SCMS_STRING_TO_XSTRING'
EXPORTING
text = l_xml_string
mimetype = 'application/xml'
IMPORTING
buffer = l_xml_xstring
EXCEPTIONS
failed = 1
OTHERS = 2.
CALL METHOD cl_wd_runtime_services=>attach_file_to_response
EXPORTING
i_filename = 'info.xml'
i_content = l_xml_xstring
i_mime_type = 'application/vnd.ms-excel'.
With this code I am generating a file of type XML SPREADSHEET 2003. While opening this file I am getting the above message which the user unwanted......
Can any one help me on this -
> How to avoid this warning?
Thanks and Regards,
Aneel Danda
Edited by: danda aneel on Jul 13, 2010 1:43 PMFirstly, Thanks for Your quick Response, Thomas.
Even though what ever may be the file name I am passing either info.xml or Info.xls , In error info.xls is coming.
Kindly provide me an alternative on this XML doesn't seem like it would match the 'application/vnd.ms-excel'.
what is the supported format.?
Similarly, It is not considering the UTF-8 / UTF-16 for xml.........same result is appearing in the output.
Edited by: danda aneel on Jul 14, 2010 7:52 AM -
Issue while uploading the PAR file thru system admin- AdministrationConsole
Hi All,
I have downloaded the PAR file "com.sap.portal.navigation.lightdetailednavigationtree.par.bak" from system admin->support->Portal Runtime ->browse deployment->Web-Inf->deployment->PCD.
after downloaded to the desktop for manual change in one of the JSP file rather than importing into NWDS. I have removed the bak from the file and added the .Zip to the file and i extracted the file.
here inside i got the three folders i.e WEB-INF,PORTAL-INF and file_list. now i went to jsp file called "LightDetailedNavigationTree.JSP" , changed one small property value in the code from false to true. after that i again zip the folders strcuture make the file name as original in the form of .PAR file. now i am trying to upload it in the portal thru system admin->portal runtime->administration console, but i am getting the deployment error as mentioned in the below.
even though with error, the wrong version of the par file with extension .err was saved in the PCD folder strcture, and original file also still exists. now i wanted to remove the wrong version of the file from PCD, what is the procedure to delete the wrong version, here in administration console i found one button clean , but i could not able to locate the wrong file version , only original right version showing up in the clean dropdown??
Can u tell me what is the procedure to edit the PAR file manually after downloaded to the desktop, rather than going edit thru NWDS??
if we need to upload the PAR file after changes, do we need to delete the original PAR file before we upload the new version of the same PAR or it will be automatically overwrite the original file with the same name??
Still i am getting confusion, please let me know how to edit the PAR file manally and how to upload the PAR file with out any isse while uploading it in the portal thru system admin->administration console??
Any pointers in this regard would be the great help to me??
Error as i got while uploading the par file after the changes manually. (com.sap.portal.navigation.lightdetailednavigationtree.par)
2011-01-24_07-40-18
Application upload failed: com.sap.portal.navigation.lightdetailednavigationtree.par
java.util.zip.ZipException: Error opening zip file /usr/sap/BIS/DVEBMGS13/j2ee/cluster/server0/apps/sap.com/irj/servlet_jsp/irj/root/web-inf/deployment/pcd/com.sap.portal.navigation.lightdetailednavigationtree.par
* at java.util.zip.ZipFile.open(Native Method)*
* at java.util.zip.ZipFile.<init>(ZipFile.java:140)*
* at java.util.zip.ZipFile.<init>(ZipFile.java:155)*
* at com.sapportals.portal.prt.deployment.ArchiveIterator.iterate(ArchiveIterator.java:39)*
* at com.sapportals.portal.prt.deployment.UploadProcess.upload(UploadProcess.java:60)*
* at com.sapportals.portal.prt.deployment.DeploymentManager._uploadArchive(DeploymentManager.java:835)*
* at com.sapportals.portal.prt.deployment.DeploymentManager.uploadArchive(DeploymentManager.java:474)*
* at com.sapportals.portal.prt.deployment.DeploymentManager.uploadApplication(DeploymentManager.java:319)*
* at com.sap.ip.portal.admin.portalanywhere.ArchiveUploader.doUpload(ArchiveUploader.java:116)*
* at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)*
* at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)*
* at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)*
* at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)*
* at java.lang.reflect.Method.invoke(Method.java:391)*
* at com.sapportals.portal.prt.component.AbstractPortalComponent.handleRequestEvent(AbstractPortalComponent.java:706)*
* at com.sapportals.portal.prt.component.AbstractPortalComponent.handleEvent(AbstractPortalComponent.java:412)*
* at com.sapportals.portal.prt.pom.ComponentNode.handleEvent(ComponentNode.java:249)*
* at com.sapportals.portal.prt.pom.PortalNode.fireEventOnNode(PortalNode.java:368)*
* at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:707)*
* at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:235)*
* at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:541)*
* at java.security.AccessController.doPrivileged(AccessController.java:246)*
* at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:430)*
* at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)*
* at com.sap.engine.services.servlets_jsp.server.servlet.InvokerServlet.service(InvokerServlet.java:156)*
* at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)*
* at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)*
* at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)*
* at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)*
* at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)*
* at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1039)*
* at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)*
* at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)*
* at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)*
* at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)*
* at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)*
* at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)*
* at java.security.AccessController.doPrivileged(AccessController.java:219)*
* at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)*
* at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176)*
Can you please what are the steps if any specific while editing the PAR file manually and uploading it with out any issues??
Thanks in advance.
Regards,
PortalUser
Edited by: PortalUser100 on Jan 24, 2011 6:01 PM
Edited by: PortalUser100 on Jan 24, 2011 6:04 PM
Edited by: PortalUser100 on Jan 24, 2011 6:05 PMHi Shusil,
Thanks for your reply.
I have one more dought here.
the PAR file of lightdetailnavigation has been modified thru NWDS and deployed the PAR file by adding the required JARS.
Now my question is, the application server which i am used as local portal server installed in my desktop.
now this depoyed latest par file i have picked it from the workspace in the local desktop, and i am planning to upload the same PAR file in of the sandbox portal system of client , will it update successfully in the new portal apart from the deployed portal??
i am here used the path system admin->support->portal runtime -> administrate console ( this in the sand box system to upload the par file which was deployed in the local portal server in my desktop.
Thanks,
Portal user -
Error while uploading the PAR file of Production to UAT-
Hi Experts,
Could you please help me out in resolving the error which i'm facing while uploading the PAR file.
1. I have downloaded the par file from the production, imported to my NWDS.
2. Made changes to my HeadiView.jsp
3. I want to test my implementation in UAT.So i have uploaded the PAR to UAT system.
4. Below is the error i'm getting from the Log trace.
#1.#D27E2000F002008200000020000BD0FE0004436CD4EBF6C2#1200034614604#com.sap.porta
l.prt.runtime#sap.com/irj#com.sap.portal.prt.runtime#BVISHALA#17971##adcapsap18.
uk_QP0_16441150#BVISHALA#5d8f9460c01111dcafa2d27e2000f002#Thread[PRT-Async 2,5,P
RT-Async]##0#0#Error##Java###06:56_11/01/08_16441150
[EXCEPTION]
#1#com.sapportals.portal.prt.component.PortalComponentException: Error in in
it method
Component : com.tw.navigation.Masthead.HeaderiView
at com.sapportals.portal.prt.component.PortalComponentContext.init(Porta
lComponentContext.java:251)
at com.sapportals.portal.prt.core.broker.PortalComponentContextItem.refr
esh(PortalComponentContextItem.java:271)
at com.sapportals.portal.prt.core.broker.PortalComponentContextItem.getC
ontext(PortalComponentContextItem.java:316)
at com.sapportals.portal.prt.component.PortalComponentRequest.getCompone
ntContext(PortalComponentRequest.java:387)
at com.sapportals.portal.pb.PageBuilder.createIviewProfile(PageBuilder.j
ava:443)
at com.sapportals.portal.pb.PageBuilder.createiView(PageBuilder.java:391
at com.sapportals.portal.pb.PageBuilder.createAndAddiViews(PageBuilder.j
ava:233)
at com.sapportals.portal.pb.PageBuilder.doOnNodeReady(PageBuilder.java:6
36)
at com.sapportals.portal.prt.component.AbstractPortalComponent.handleEve
nt(AbstractPortalComponent.java:388)
at com.sapportals.portal.pb.PageBuilder.handleEvent(PageBuilder.java:816
at com.sapportals.portal.prt.component.CachablePortalComponent.handleEve
nt(CachablePortalComponent.java:703)
at com.sapportals.portal.prt.pom.ComponentNode.handleEvent(ComponentNode
.java:252)
at com.sapportals.portal.prt.pom.PortalNode.fireEventOnNode(PortalNode.j
ava:368)
at com.sapportals.portal.prt.pom.AbstractNode.addChildNode(AbstractNode.
java:340)
at com.sapportals.portal.navigation.PortalLauncher.doOnNodeReady(PortalL
auncher.java:318)
at com.sapportals.portal.prt.component.AbstractPortalComponent.handleEve
nt(AbstractPortalComponent.java:388)
at com.sapportals.portal.prt.pom.ComponentNode.handleEvent(ComponentNode
.java:252)
at com.sapportals.portal.prt.pom.PortalNode.fireEventOnNode(PortalNode.j
ava:368)
at com.sapportals.portal.prt.pom.AbstractNode.addChildNode(AbstractNode.
java:340)
at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(P
ortalRequestManager.java:642)
at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(
ServletConnection.java:240)
at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatc
her.java:524)
at java.security.AccessController.doPrivileged(AccessController.java:242
at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.ja
va:407)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.servlet.InvokerServlet.se
rvice(InvokerServlet.java:156)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcher
Impl.doWork(RequestDispatcherImpl.java:321)
at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcher
Impl.forward(RequestDispatcherImpl.java:377)
at com.sap.portal.navigation.Gateway.service(Gateway.java:126)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServle
t(HttpHandlerImpl.java:401)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleReq
uest(HttpHandlerImpl.java:266)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServle
t(RequestAnalizer.java:387)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServle
t(RequestAnalizer.java:365)
at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebCo
ntainer(RequestAnalizer.java:944)
at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(Requ
estAnalizer.java:266)
at com.sap.engine.services.httpserver.server.Client.handle(Client.java:9
5)
at com.sap.engine.services.httpserver.server.Processor.request(Processor
.java:175)
at com.sap.engine.core.service630.context.cluster.session.ApplicationSes
sionMessageListener.process(ApplicationSessionMessageListener.java:33)
at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRu
nner.java:41)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:3
7)
at java.security.AccessController.doPrivileged(AccessController.java:215
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.ja
va:100)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:1
70)
Caused by: com.sapportals.portal.prt.core.broker.PortalComponentInstantiationExc
eption: Could not instantiate implementation class com.btexx.pct.easyWCM.navigat
ion.masthead.HeaderiView of Portal Component com.tw.navigation.Masthead.HeaderiV
iew because: Could not find implementation class
at com.sapportals.portal.prt.core.broker.PortalComponentItemFacade.getIn
stanceInternal(PortalComponentItemFacade.java:242)
at com.sapportals.portal.prt.core.broker.PortalComponentItemFacade.getCo
mponentInstance(PortalComponentItemFacade.java:160)
at com.sapportals.portal.prt.core.broker.PortalComponentItem.getComponen
tInstance(PortalComponentItem.java:732)
at com.sapportals.portal.prt.component.PortalComponentContext.getCompone
nt(PortalComponentContext.java:103)
at com.sapportals.portal.prt.component.PortalComponentContext.init(Porta
lComponentContext.java:242)
... 44 more
Caused by: java.lang.ClassNotFoundException: com.btexx.pct.easyWCM.navigation.ma
sthead.HeaderiView
at java.lang.Class.forNameImpl(Native Method)
at java.lang.Class.forName(Class.java:152)
at com.sapportals.portal.prt.core.broker.PortalComponentItemFacade.getIn
stanceInternal(PortalComponentItemFacade.java:228)
... 48 more
Kindly help me to resolve this issue.
Many Thanks,
B.Vishali.Hi,
The problem might be caused by the version inconsistency of your J2EE and Portal Platform.
Please check the version of your J2EE and Portal.
Best Regards,
Assaf -
To upload a excel file to dB table through webdynpro ABAP
HI,
I am unable to upload a excel file directly by using func module "HR_KR_XSTRING_TO_STRING".
If file is in tab delimited then only, I am able to upload.
Suggest me if there are any other options to upload a excel file.Hi,
The below link gives you an explanation of how you can upload an excel file to web dynpro.
http://www.****************/Tutorials/WebDynproABAP/Upload/Page1.htm
Kindly read go through the below link, as this issue have been brought up before
http://forums.sdn.sap.com/thread.jspa?threadID=1831838
Thanks and regards.
Edited by: Suraj Ravindran Nair on Feb 24, 2012 6:24 AM -
Problem in uploading an excel file in wd abap
I am trying to upload an excel file in wd abap but on uploading it shows me the data in the form of some codes but when i try to do the same thing using text file it works well.Plese refer the code .
METHOD onactionon_upload .
TYPES : BEGIN OF itab_str1,
name(10) TYPE c,
age(10) TYPE c,
END OF itab_str1.
DATA : t_table1 TYPE STANDARD TABLE OF itab_str1,
i_data TYPE STANDARD TABLE OF string,
lo_nd_sflight TYPE REF TO if_wd_context_node,
lo_el_sflight TYPE REF TO if_wd_context_element,
l_string TYPE string,
fs_table TYPE itab_str1,
l_xstring TYPE xstring,
fields TYPE string_table,
lv_field TYPE string.
DATA : t_table TYPE if_main=>elements_data_tab,
data_table TYPE if_main=>elements_data_tab.
wd_context->get_attribute(
EXPORTING
name = 'DATASOURCE'
IMPORTING
value = l_xstring
CALL FUNCTION 'HR_KR_XSTRING_TO_STRING'
EXPORTING
in_xstring = l_xstring
IMPORTING
out_string = l_string.
SPLIT l_string AT cl_abap_char_utilities=>newline INTO TABLE i_data.
LOOP AT i_data INTO l_string.
SPLIT l_string AT cl_abap_char_utilities=>horizontal_tab INTO TABLE fields.
READ TABLE fields INTO lv_field index 1.
fs_table-name = lv_field.
READ TABLE fields INTO lv_field index 2.
fs_table-age = lv_field.
APPEND fs_table TO t_table1.
ENDLOOP.
lo_nd_sflight = wd_context->get_child_node( 'DATA_TAB').
lo_nd_sflight->bind_table( t_table1 ).
ENDMETHOD.Problem is not with the file format nor Upload element.
problem is with conversion function module, still now for conversion of xcel data to string format we dont have perfect function module.
CALL FUNCTION 'HR_KR_XSTRING_TO_STRING'
EXPORTING
in_xstring = l_xstring
IMPORTING
out_string = l_string.
That's a bug with xcel conversion As of now I dont find any fm which converts xcel data to string without any problem.
Regards
Srinvivas
Edited by: sanasrinivas on Dec 23, 2011 7:02 AM -
Error message while uploading the flat file
Hi Experts,
I am getting the error message while uploading the flat file.
Message class: MG
Number: 147
The message is: Several descriptions exist for the language JA.
Please guide me why this error is occuring.
Regards
Akshayhi,
how are you uploading the file and where ?
u can use open dataset , read dataset or gui_upload
check this link
http://help.sap.com/saphelp_nw04/helpdata/en/c8/e92637c2cbf357e10000009b38f936/frameset.htm -
Exception while creating a excel file in BPM 10g
Hi,
We are facing following issue while creating an excel file from BPM.
java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at fuegoblock.net.web.NewJspAjaxController.processMethodInvocation(NewJspAjaxController.java:264) at fuegoblock.net.web.NewJspAjaxController.service(NewJspAjaxController.java:46) at fuego.web.execution.servlet.ServletRedirector$ControllerRedirector.forward(ServletRedirector.java:197) at fuego.web.execution.servlet.ServletRedirector.redirect(ServletRedirector.java:58) at fuego.web.papi.TaskExecutor.processRedirect(TaskExecutor.java:224) at fuego.web.papi.TaskExecutor.execute(TaskExecutor.java:104) at fuego.workspace.servlet.ExecutorServlet.doAction(ExecutorServlet.java:117) at fuego.workspace.servlet.BaseServlet.doPost(BaseServlet.java:229) at fuego.workspace.servlet.BaseServlet.doGet(BaseServlet.java:220) at javax.servlet.http.HttpServlet.service(HttpServlet.java:707) at fuego.workspace.servlet.AuthenticatedServlet.service(AuthenticatedServlet.java:138) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227) at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125) at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292) at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at fuego.web.filter.SingleThreadPerSessionFilter.doFilter(SingleThreadPerSessionFilter.java:64) at fuego.web.filter.BaseFilter.doFilter(BaseFilter.java:63) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at fuego.web.filter.CharsetFilter.doFilter(CharsetFilter.java:48) at fuego.web.filter.BaseFilter.doFilter(BaseFilter.java:63) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321) at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121) at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202) at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108) at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201) at weblogic.work.ExecuteThread.run(ExecuteThread.java:173) Caused by: java.lang.NoClassDefFoundError: org/apache/poi/ss/usermodel/Workbook at xobject.Views.ReportingView.exportToExcel(ReportingView.xcdl:9) ... 35 more Caused by: java.lang.ClassNotFoundException: org.apache.poi.ss.usermodel.Workbook at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at java.lang.ClassLoader.loadClass(ClassLoader.java:248) ... 36 more
There is a JSP file which invokes the method of BPM, which inturn creates a excel file.
In JSP we are calling the method in the following way:
function exportSelectedItemsToExcel(){
var url="<f:invokeUrl var='reportingView' methodName='exportToExcel'/>";
url = url + "&bpmRespContentType=application/vnd.ms-excel";
var windowHandle = window.open(url,'windowName','width=800, height=600, resizable=1, menubar=1');
POI jars are used to create the excel.
Also we recently did the migration and applied a patchset of 10.3.3 on 10.3.2. In the previous verison(10.3.2) it was working perfectly fine. When i am trying to test it on localstudio, it is generating the excel file properly.
Have any one faced any such issues while migration or any other time?Manifests are saved with the .mf file extension. Rename your manifest mainfest.mf.
Maybe you are looking for
-
How to find out which PL/SQL Proc is Compiled with Debug?
Hi, is there any View where i can see, which PL/SQL Proc is compiled with the debug flag? Thanks Marco Message was edited by: mpatzwah
-
What is the best way to safeguard my files and pictures before I send off my MacBook Pro to get fixed? I am running Mavericks and use an AirPort Time Machine to back-up all my files.
-
How to process attachments using an XI-Adapter
Hi together, I have seen that there are a lot of problems processing attachments of XML messages in SAP XI 7.0. Unfortunately I have the same problem by using an XI sender adapter. My scenario is as follows: I will get an PurchaseOrderRequest_Out out
-
HT4807 anyone ever get this message? "The application Logic Pro can't be opened - 1712"
anyone ever get this message? "The application Logic Pro can't be opened - 1712"
-
Is iMovie still free to download for iPhone 5s?
I've been trying to download iMovie, however there is a $4.99 price tag. From what I know, it is supposed to be free for iPhone 5s. Was this app changed from being a free app to a paid app?