Table is locked by app server
I am using MS SQL Server 2000 with MS SQL Server JDBC Driver and JBoss 3.2.3.
I have a stored procedure. This stored procedure does one insert in Table1 and multiple inserts in Table2. The stored procedure starts with a begin transaction; if any of the inserts fails (I check @@error) then i rollback transaction; if everything works ok then i do a commit transaction.
I have a Stateless Session Bean one of its method is calling this stored procedure.
If the stored procedure runs successfully then every thing is ok. But if one of the inserts in stored procedure fails, i see 2 bad things happening:
* no SQLException is thrown
* the Table1 gets locked and only unlocks when i close application server.
Any explanation?
Thanks
ok to perform simple tests, I:
* create 2 identical tables "ttt" and "ttt1" for testing purpose with each's one column not accepting nulls:
CREATE TABLE [dbo].[ttt] (
[id] [int] IDENTITY (1, 1) NOT NULL PRIMARY KEY,
[col1] [varchar(50)] NULL ,
[col2] [varchar(50)] NULL ,
[col3] [varchar(50)] NOT NULL )
CREATE TABLE [dbo].[ttt1] (
[id] [int] IDENTITY (1, 1) NOT NULL PRIMARY KEY,
[col1] [varchar(50)] NULL ,
[col2] [varchar(50)] NULL ,
[col3] [varchar(50)] NOT NULL ) * Simplify the stored proc to insert one row in ttt and one row in ttt1. The ttt row will be successfully inserted while ttt1 row insertion will fail as i try to insert null in a non-null column:
CREATE PROCEDURE ta_ProcessPayroll
AS
BEGIN
declare @v_CommitTransaction int
declare @v_ErrorCode int
declare @v_ErrorMessage varchar(300)
SET NOCOUNT OFF
SET @v_CommitTransaction = 0
SET @v_ErrorCode = 0
-- Manage separate transaction if not invoked from within another transaction.
if ( @@trancount = 0 )
begin
begin transaction ta_ProcessPayroll
set @v_CommitTransaction = 1
end
insert into ttt (col1, col2, col3) values ('A', 'B', 'C')
set @v_ErrorCode = @@error
if ( @v_ErrorCode <> 0 )
begin
set @v_ErrorMessage = cast( @@PROCID as varchar(300) )+ ': failed with error code ' + cast( @v_ErrorCode as varchar(20) )
goto error_handler
end
insert into ttt1 (col1, col2, col3) values ('A1', 'B1', null)
set @v_ErrorCode = @@error
if ( @v_ErrorCode <> 0 )
begin
set @v_ErrorMessage = cast( @@PROCID as varchar(300) )+ ': failed with error code ' + cast( @v_ErrorCode as varchar(20) )
goto error_handler
end
if ( @v_CommitTransaction = 1 )
begin
commit transaction ta_ProcessPayroll
end
error_handler:
if ( @v_ErrorCode <> 0 )
begin
if ( @v_CommitTransaction = 1 )
begin
rollback transaction ta_ProcessPayroll
end
RAISERROR( @v_ErrorMessage, 16, 1 )
end
END
GO* use this java code in a SSB's method to execute the stored proc :
Connection conn = null;
CallableStatement stmt = null;
try {
conn = ConnectionHelper.getConnection(); // get connection (use JNDI)
stmt = conn.prepareCall("{call ta_ProcessPayroll()}");
stmt.execute();
} catch (SQLException sqle) {
sqle.printStackTrace();
} finally {
}Now I execute the stored proc through my java code and get the SQLException but the table ttt gets locked while table ttt1 does not get locked.
I checked it through query analyzer tool of sql server by typing " select * from ttt " and it hangs instead of giving me result set until i cancel it. No such thing happens when i type " select * from ttt1 " in query analyzer. When I type "select * from ttt with (nolock)" I can see the row being inserted by my stored proc.
Now here is what I observe:
* If i shut down my JBoss right away the lock on ttt gets released. When I query it there is no data in it which is good as the transaction gets rollback.
* If I dont shut down my JBoss and instead go to another jsp in the same web application which retrieves data from another table, then the llock on ttt gets released. But when I query it I can see 1 row in there which was put by my stored proc. So the transaction do not gets rollback.
I have a feeling I am missing some thing on my java code side. Please explain.
Thanks
Similar Messages
-
Issue with lock file in Oracle 10g app server - MDB not running
Hi,
I have Oracle 10g & MQ 6 on my laptop. I generated JNDI bindings for app server-MQ by giving ip address of my machine first. Then i changed it to "localhost" & generated new set of .bindings file.
With this new set i am able to send messages from my program to a queue. I also have an MDB which should listen to the same queue.
However now my mdb is not listening to the queue & i suspect it is due to host address change, - because each time i start the server, i see a lock file created "OracleASRouter_store.lock" - under j2ee\home\persistance. And below is the content of the same -
"O10.1.4.245:/C:/Program Files/Oracle/oc4j_extended_101330/j2ee/home/persistence/"
As per few suggestions on this site, I deleted this file & restated app server, deleted whole content of persistance folder, restarted app server. But each time i see this file created and also see the ip address in log.xml under j2ee\home\log\oc4j
Error message in this log.xml file is
<MESSAGE>
<HEADER>
<TSTZ_ORIGINATING>2007-09-19T11:22:35.265-04:00</TSTZ_ORIGINATING>
<COMPONENT_ID>j2ee</COMPONENT_ID>
<MSG_ID>J2EE EJB-02009</MSG_ID>
<MSG_TYPE TYPE="WARNING"></MSG_TYPE>
<MSG_LEVEL>1</MSG_LEVEL>
<HOST_ID>IFLEXNY-EXT99</HOST_ID>
<HOST_NWADDR>10.1.4.245</HOST_NWADDR>
<MODULE_ID>ejb.runtime</MODULE_ID>
<THREAD_ID>10</THREAD_ID>
<USER_ID>chetanmi</USER_ID>
</HEADER>
<CORRELATION_DATA>
<EXEC_CONTEXT_ID><UNIQUE_ID>10.1.4.245:65858:1190215355296:0</UNIQUE_ID><SEQ>0</SEQ></EXEC_CONTEXT_ID>
</CORRELATION_DATA>
<PAYLOAD>
<MSG_TEXT>[STGMQ:STGMQEJB:TestMDB] Unexpected exception by JMS provider: javax.jms.MessageEOFException: initializeConnection.</MSG_TEXT>
<SUPPL_DETAIL><![CDATA[javax.jms.MessageEOFException: initializeConnection
at com.evermind.server.jms.JMSUtils.make(JMSUtils.java:1075)
at com.evermind.server.jms.JMSUtils.toJMSException(JMSUtils.java:1155)
at com.evermind.server.jms.TCPJMSRemoteServer.initializeConnection(TCPJMSRemoteServer.java:154)
at com.evermind.server.jms.TCPJMSRemoteServer.initializeConnection(TCPJMSRemoteServer.java:110)
at com.evermind.server.jms.TCPJMSRemoteServer.<init>(TCPJMSRemoteServer.java:68)
at com.evermind.server.jms.EvermindConnection.<init>(EvermindConnection.java:122)
at com.evermind.server.jms.EvermindQueueConnection.<init>(EvermindQueueConnection.java:70)
at com.evermind.server.jms.EvermindQueueConnectionFactory.unprivileged_createQueueConnection(EvermindQueueConnectionFactory.java:101)
at com.evermind.server.jms.EvermindQueueConnectionFactory.access$000(EvermindQueueConnectionFactory.java:44)
at com.evermind.server.jms.EvermindQueueConnectionFactory$1.execute(EvermindQueueConnectionFactory.java:81)
at com.evermind.server.jms.InContainerProxy.doSecureOp(InContainerProxy.java:157)
at com.evermind.server.jms.EvermindQueueConnectionFactory.createQueueConnection(EvermindQueueConnectionFactory.java:78)
at com.evermind.server.jms.EvermindQueueConnectionFactory.createQueueConnection(EvermindQueueConnectionFactory.java:69)
at com.evermind.server.ejb.MessageDrivenConsumer.createNonXAResources(MessageDrivenConsumer.java:567)
at com.evermind.server.ejb.MessageDrivenConsumer.initializeJMSResources(MessageDrivenConsumer.java:491)
at com.evermind.server.ejb.MessageDrivenConsumer.processMessages(MessageDrivenConsumer.java:208)
at com.evermind.server.ejb.MessageDrivenConsumer.run(MessageDrivenConsumer.java:169)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:298)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.io.EOFException
at java.io.DataInputStream.readInt(DataInputStream.java:358)
at com.evermind.server.jms.JMSRemoteServer.readCheck(JMSRemoteServer.java:678)
at com.evermind.server.jms.JMSRemoteServer.readProtocol(JMSRemoteServer.java:696)
at com.evermind.server.jms.TCPJMSRemoteServer.initializeConnection(TCPJMSRemoteServer.java:134)
... 16 more
]]></SUPPL_DETAIL>
</PAYLOAD>
</MESSAGE>
<MESSAGE>
<HEADER>
<TSTZ_ORIGINATING>2007-09-19T11:22:35.312-04:00</TSTZ_ORIGINATING>
<COMPONENT_ID>j2ee</COMPONENT_ID>
<MSG_ID>J2EE EJB-02014</MSG_ID>
<MSG_TYPE TYPE="WARNING"></MSG_TYPE>
<MSG_LEVEL>1</MSG_LEVEL>
<HOST_ID>IFLEXNY-EXT99</HOST_ID>
<HOST_NWADDR>10.1.4.245</HOST_NWADDR>
<MODULE_ID>ejb.runtime</MODULE_ID>
<THREAD_ID>10</THREAD_ID>
<USER_ID>chetanmi</USER_ID>
</HEADER>
<CORRELATION_DATA>
<EXEC_CONTEXT_ID><UNIQUE_ID>10.1.4.245:65858:1190215355296:0</UNIQUE_ID><SEQ>0</SEQ></EXEC_CONTEXT_ID>
</CORRELATION_DATA>
<PAYLOAD>
<MSG_TEXT>[STGMQ:STGMQEJB:TestMDB] All message consumer threads have terminated due to provider errors, stopping MDB.</MSG_TEXT>
</PAYLOAD>
</MESSAGE>
And my MDB is NOT WORKING. Please let me know how to deal with this.
Your suggestions would be much appreciated.
Regard,
ChetanLine # 127 is creating a new application object using ApplicationFactory.
ApplicationFactory aFactory =
(ApplicationFactory) FactoryFinder.getFactory(
FactoryFinder.APPLICATION_FACTORY);
application = aFactory.getApplication();
The only way that can throw a null pointer is when aFactory is NULL. I really doubt this case because, the same thing is doen in init() of FacesServlet. If it had failed there, the exception should have occured during server startup.
This leaves me more and more confused....I am desperate for some help now :((
Ramesh -
About Dead Lock on apps tables in 11.5.10.2
Hi All,
How to find and Kill dead lock on apps table (11.5.10) ?
Reg
Chirag PatelChirag,
Please refer to the following notes, it should be helpful.
Note: 109061.1 - How to Check Whether an AOL Table is Locked
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=109061.1
Note: 223559.1 - Oracle Application Object Library Table Lock Data Collection Test
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=223559.1
Note: 732271.1 - R12 Oracle Application Object Library (FND): Table Lock Data Collection Test
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=732271.1 -
HELP - DB2 v9 & App Server PE 9.0 - PING Connection Pool Failure - HELP
I've been playing around with Studio Creator and DB2 v9 without any issues.
So I figured I would installed App Server PE 9 and use this as my production server that I would deploy to from studio creator.
However, in my efforts to set up db2/v9 I have been trying to ping a connection pool without any luck. I get the following message:
Operation 'pingConnectionPool' failed in 'resources' Config Mbean. Target exception message: Connection could not be allocated because: [sunm][DB2 JDBC Driver]Resource Limits Reached( ALLOCATE MEMORY FOR NEW SQLSTT FAILED ). Diagnostic Info: FUNCTION ID = 0049 , PROBE POINT = 0400 , TRACE POINT = 0030 , SUBCODE1 = 8B0F0000, SUBCODE2 = 78A68A98, SUBCODE3 = 00000000, ERROR MSG = Parser: Memory allocation error.
My datasource class name is com.sun.sql.jdbcx.db2.DB2DataSource.
And my resource type is javax.sql.datasource
I have copied smbase.jar, smdb2.jar and smutil.jar into c:\sun\appserver\lib
and I have all of the properties (serverName, portNumber, databaseName, user, password) created and set accordingly.
Any help would be greatly appreciated.Here is how I got the DB2 Express-C and Sun PE 9.0 to work. ( at least base connectivity wise )
1. ) You have to have at least the DB2 Client installed on the system that will be communicating to the DB2 instance.
2.) The following jars will be needed ( depending on the driver type used) . db2java.zip, db2jcc.jar, and db2jcc_license_cu.jar and use them in the App Server ->JVM settings -> Path Settings -> Classpath Suffix
3.) The next setup is dependent on the Type driver you use
I used the Type 4 and this is the resource setup I used.
Connection Pool:
Name: DB2TestPool
Datasource Classname: com.ibm.db2.jcc.DB2SimpleDataSource
Resource Type: javax.sql.ConnectionPoolDataSource
Properties:
user: xxxxxx
password: xxxxxx
databaseName: TEST
serverName: <hostname of machine>
portnumber: 50000
driverType: 4
URL: jdbc:db2://<hostname>:<port>/<database>
JDBC Resource:
JNDI Name: jdbc/TEST
Pool Name: DB2TestPool
With this configuration I was able to ping the database as well as connect to create an entity bean from a table. This should give you a starting point.
I have yet to deploy my application, but should be doing that sometime today to verify that a connection can be made and used from within the application. -
Transfer a file from App Server to a FTP site.
Hi, Abapers.
I need your help. Probably, this topic has already been posted in a similar way, but we need an answer to solve our problem.
We have to sent a PDF file from a directory of our app server (AIX) to a FTP directory... which would the FM sequence we should use to goal it?
Best Regards.Hi Santiago,
create fm to send file from APP server to FTP site.
if you want to Post file from desktop to Appl use Transaction - CG3Y
if you want to Post file from Appl to Desktop use Transaction - CG3Z
copy the code below....
* Author: Prabhudas Date: 02/21/2006 *
* Name: Z_FTP_FILE_TO_SERVER *
* Title: FTP File on R/3 Application Server to External Server *
*"*"Local Interface:
*" IMPORTING
*" REFERENCE(DEST_HOST) TYPE C
*" REFERENCE(DEST_USER) TYPE C
*" REFERENCE(DEST_PASSWORD) TYPE C
*" REFERENCE(DEST_PATH) TYPE C
*" REFERENCE(SOURCE_PATH) TYPE C
*" REFERENCE(FILE) TYPE C
*" REFERENCE(BINARY) TYPE CHAR1 OPTIONAL
*" REFERENCE(REMOVE_FILE) TYPE CHAR1 OPTIONAL
*" TABLES
*" FTP_SESSION STRUCTURE ZMSG_TEXT OPTIONAL
*" EXCEPTIONS
*" CANNOT_CONNECT
*" SOURCE_PATH_UNKNOWN
*" DEST_PATH_UNKNOWN
*" TRANSFER_FAILED
*" COMMAND_FAILED
DATA: w_password TYPE zftppassword,
w_length TYPE i,
w_key TYPE i VALUE 26101957,
w_handle TYPE i,
w_command(500) TYPE c.
REFRESH ftp_session.
* Scramble password (new Unicode-compliant routine)
w_length = STRLEN( dest_password ).
CALL FUNCTION 'HTTP_SCRAMBLE'
EXPORTING
SOURCE = dest_password
sourcelen = w_length
key = w_key
IMPORTING
destination = w_password.
* Connect to FTP destination (DEST_HOST)
CALL FUNCTION 'FTP_CONNECT'
EXPORTING
user = dest_user
password = w_password
host = dest_host
rfc_destination = 'SAPFTPA'
IMPORTING
handle = w_handle
EXCEPTIONS
not_connected = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
RAISING cannot_connect.
ENDIF.
* Optionally, specify binary file transfer
IF binary = 'X'.
w_command = 'bin'.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
handle = w_handle
command = w_command
TABLES
data = ftp_session
EXCEPTIONS
command_error = 1
tcpip_error = 2.
IF sy-subrc <> 0.
CONCATENATE 'FTP command failed:' w_command
INTO w_command SEPARATED BY space.
MESSAGE ID 'ZW' TYPE 'E' NUMBER '042'
WITH w_command
RAISING command_failed.
ENDIF.
ENDIF.
* Navigate to source directory
CONCATENATE 'lcd' source_path INTO w_command SEPARATED BY space.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
handle = w_handle
command = w_command
TABLES
data = ftp_session
EXCEPTIONS
command_error = 1
tcpip_error = 2.
IF sy-subrc <> 0.
CONCATENATE 'FTP command failed:' w_command
INTO w_command SEPARATED BY space.
MESSAGE ID 'ZW' TYPE 'E' NUMBER '042'
WITH w_command
RAISING source_path_unknown.
ENDIF.
* Navigate to destination directory
CONCATENATE 'cd' dest_path INTO w_command SEPARATED BY space.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
handle = w_handle
command = w_command
TABLES
data = ftp_session
EXCEPTIONS
command_error = 1
tcpip_error = 2.
IF sy-subrc <> 0.
CONCATENATE 'FTP command failed:' w_command
INTO w_command SEPARATED BY space.
MESSAGE ID 'ZW' TYPE 'E' NUMBER '042'
WITH w_command
RAISING dest_path_unknown.
ENDIF.
* Transfer file
CONCATENATE 'put' file INTO w_command SEPARATED BY space.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
handle = w_handle
command = w_command
TABLES
data = ftp_session
EXCEPTIONS
command_error = 1
tcpip_error = 2.
IF sy-subrc <> 0.
CONCATENATE 'FTP command failed:' w_command
INTO w_command SEPARATED BY space.
MESSAGE ID 'ZW' TYPE 'E' NUMBER '042'
WITH w_command
RAISING transfer_failed.
ENDIF.
* Disconnect from destination host
CALL FUNCTION 'FTP_DISCONNECT'
EXPORTING
handle = w_handle.
* Optionally, remove file from source directory
IF remove_file = 'X'.
CONCATENATE source_path '/' file INTO w_command.
CONCATENATE 'rm' w_command INTO w_command SEPARATED BY space.
OPEN DATASET '/dev/null' FOR OUTPUT FILTER w_command.
CLOSE DATASET '/dev/null'.
ENDIF.
Regards,
Prabhudas -
Downloading a file from App Server to User's Desktop
Hi All,
I know that there are many threads on file upload and download :-)
I have tried to browse through most of them and could not find my solution.
The requirement is to place a file in the unix app server directory and allow the user to download it using a link, to the user's desktop. In case you think that this has already been answered in an old thread, kindly give me the pointer. Any sample code for doing this, would be great.
I know how to upload a file from desktop to table/app server. I know how to download a file from a BLOB column in database.
Thanks,
AmitYou would not be able to use file upload or download beans, as they interact with the database and not the filesystem.
You would need to write a simple file reader routing in plain java.
Tapash -
Download PDF file from APP server!
Hi!
Has anyone tried uplaoding and downloding a PDF table from app server as I tried from a normal method by Open dataset, Transfer but it wont work.
Please provide any inputs.
Thanks.Hi park,
1. Using open data set, transfer , close etc,
also it will work.
( it will download / upload any kind of file from app server)
2. Just make sure the
FULL PATHNAME and the FILENAME
are mentioned in EXACT CASE
(small/CAPITAL).
3. U can check thru transaction AL11, to see the file and path.
regards,
amit m. -
Comparison b/w itable and app server file
Hi All,
I have Postal code data (KNA1-PSTLZ) in internal table. And I have input file in the app server, in that I have a data of Postal code in range like
Postal code FROM Postal code TO
(KNA1-PSTLZ) (KNA1-PSTLZ)
20001 22999
35001 38599
And so on ..so my requirement is I have to compare with internal table postal code to that file postal code, if it matches I have to do something, other wise I have to ignore, pls give me brief logic hw to compare.
Akshitha." to get the data from app server to internal table.
OPEN DATASET p_ufile FOR INPUT IN TEXT MODE.
IF sy-subrc <> 0.
EXIT.
ENDIF.
DO.
READ DATASET p_ufile INTO in_file.
IF sy-subrc <> 0.
EXIT.
ENDIF.
APPEND in_file.
CLEAR in_file.
ENDDO.
CLOSE DATASET p_ufile.
LOOP AT in_file.
SPLIT in_file AT c_tab INTO
wa_citm_b-type
wa_citm_b-vbeln
wa_citm_b-posnr
wa_citm_b-uepos.
APPEND wa_citm_b TO lt_citm_b.
ENDLOOP.
loop at table_appsrv.
if KNA1-PSTLZ eq table_appsrv-postal code..
"do our something here.
else.
skip.
endif.
endloop.
Award points if helpful -
Create attachment of a file stored on the app server for mail
Hello All:
I am working on sending a mail with attachemnts (file from the app server), i am aware of numerous solutions posted on the forum ....i am able to create an attachment and send mail. the problem i am facing is the attachment is corrupted . can some one guide me as what i am ding wrong . here's the code
DATA: REC(80) TYPE C.
DATA: L_SIZE TYPE DRAO-ORLN.
DATA: L_LINES TYPE I.
DATA: L_DATA_TAB TYPE TABLE OF RCGREPFILE.
DATA: L_DATA_TAB1 TYPE TABLE OF RCGREPFILE.
DATA: L_DATA_WA TYPE RCGREPFILE.
DATA: N_FILE TYPE RCGIEDIAL-IEFILE.
P_FILE = '/usr/sap/MIE/SYS/global/PDFSpools/30978.pdf'.
N_FILE = P_FILE.
CONCATENATE 'C:temp' RQ2NAME '.pdf' INTO ELPATH.
* Read Data from the App server
OPEN DATASET P_FILE FOR INPUT IN BINARY MODE .
DO.
READ DATASET P_FILE INTO REC.
IF SY-SUBRC NE 0.
EXIT.
ELSE.
L_ANN = REC.
APPEND L_ANN TO T_PDF .
ENDIF.
ENDDO.
CLOSE DATASET P_FILE.
* How do i get the filesize ?
CLEAR L_ANN.
DESCRIBE TABLE T_PDF LINES LIN_TEXT.
LOOP AT T_PDF INTO L_ANN.
APPEND L_ANN TO T_ANN.
ENDLOOP.
* Using this i get the file size
* CALL FUNCTION 'C13Z_RAWDATA_READ'
* EXPORTING
* I_FILE = N_FILE
* IMPORTING
* E_FILE_SIZE = L_SIZE
* E_LINES = L_LINES
* TABLES
* E_RCGREPFILE_TAB = L_DATA_TAB
* EXCEPTIONS
* NO_PERMISSION = 1
* OPEN_FAILED = 2
* OTHERS = 3.
* CLEAR L_ANN.
* DESCRIBE TABLE L_DATA_TAB LINES LIN_TEXT.
* LOOP AT L_DATA_TAB INTO L_DATA_WA.
* L_ANN-LINE = L_DATA_WA-ORBLK.
* APPEND L_ANN TO T_ANN.
* ENDLOOP.
DOC_CHNG-OBJ_NAME = 'URGENT'.
DOC_CHNG-EXPIRY_DAT = SY-DATUM + 10.
DOC_CHNG-OBJ_DESCR = TEXTS.
DOC_CHNG-SENSITIVTY = 'O'.
* DOC_CHNG-DOC_SIZE = LIN_TEXT * 255.
CLEAR OBJPACK-TRANSF_BIN.
OBJPACK-HEAD_START = 1.
OBJPACK-HEAD_NUM = 0.
OBJPACK-BODY_START = 1.
* OBJPACK-BODY_NUM = LIN_TEXT.
OBJPACK-DOC_TYPE = 'RAW'.
APPEND OBJPACK.
NOMFITXER = ELPATH.
CALL FUNCTION 'SPLIT_FILENAME'
EXPORTING
LONG_FILENAME = NOMFITXER
IMPORTING
PURE_EXTENSION = EXTENSIO.
OBJPACK-TRANSF_BIN = 'X'.
OBJPACK-HEAD_START = 1.
OBJPACK-HEAD_NUM = 1.
OBJPACK-BODY_START = 1.
OBJPACK-BODY_NUM = LIN_TEXT.
OBJPACK-DOC_TYPE = EXTENSIO.
OBJPACK-OBJ_NAME = RQ2NAME.
CONCATENATE RQ2NAME EXTENSIO
INTO NOMFITXER SEPARATED BY '.'.
OBJPACK-OBJ_DESCR = NOMFITXER.
OBJPACK-DOC_SIZE = L_SIZE * 255.
APPEND OBJPACK.
CALL FUNCTION 'BAPI_USER_GET_DETAIL'
EXPORTING
USERNAME = SY-UNAME
TABLES
RETURN = BAPIRETUR
ADDSMTP = DADESUSER.
READ TABLE BAPIRETUR WITH KEY TYPE = 'E'.
IF SY-SUBRC NE 4.
ELSE.
READ TABLE DADESUSER INDEX 1.
* REMITENT = DADESUSER-E_MAIL.
REMITENT = SY-UNAME.
ENDIF.
TEXTS = 'TEST MAIL'.
APPEND TEXTS.
DESTINATARIS-RECEIVER = SY-UNAME.
DESTINATARIS-REC_TYPE = 'B'.
DESTINATARIS-EXPRESS = 'X'.
* DESTINATARIS-COM_TYPE = 'INT'.
* DESTINATARIS-NOTIF_DEL = 'X'.
* DESTINATARIS-NOTIF_NDEL = 'X'.
APPEND DESTINATARIS.
CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
EXPORTING
DOCUMENT_DATA = DOC_CHNG
PUT_IN_OUTBOX = 'X'
SENDER_ADDRESS = REMITENT
* SENDER_ADDRESS_TYPE = 'SMTP'
COMMIT_WORK = ' '
IMPORTING
SENT_TO_ALL = ENVIAT
* NEW_OBJECT_ID =
* SENDER_ID =
TABLES
PACKING_LIST = OBJPACK
* OBJECT_HEADER =
CONTENTS_BIN = T_ANN
CONTENTS_TXT = TEXTS
* CONTENTS_HEX =
* OBJECT_PARA =
* OBJECT_PARB =
RECEIVERS = DESTINATARIS
EXCEPTIONS
TOO_MANY_RECEIVERS = 1
DOCUMENT_NOT_SENT = 2
DOCUMENT_TYPE_NOT_EXIST = 3
OPERATION_NO_AUTHORIZATION = 4
PARAMETER_ERROR = 5
X_ERROR = 6
ENQUEUE_ERROR = 7
OTHERS = 8.
Message was edited by: Poornanand Mandalika. Code was formatted using the <b>Code</b> button!!Assuming you are using Apache?
You could place your Word docs in the same folder as your current Apex images directory (or a sub-directory off it) then reference them with a URL of the form http://yourserver/i/sample_word_file.doc. Alternatively you could add a new Alias entry to your dads.conf file (found in your Apache/modplsql/conf directory) to expose the folder on your webserver that contains your Word files via a URL such as http://yourserver/word_docs/
E.g.
Alias /word_docs/ "c:\my_docs\technical_word_docs/"
Andy -
Office Web App Server 2013: cannot edit word document with own WOPI Server
Hi all,
I tried to build our own WOPI Server to connect to Office Web App Server 2013 SP1. Viewing documents
in IE was possible quite easy to achieve. Now it comes to editing.
When I try to edit a document, I got a german message “Sie verfügen leider nicht über die Berechtigung zum Bearbeiten dieses Dokuments“.
This means something like „Sorry, you do not have any permission to modify this document”.
I enabled editing on the OWAS-Server while setup procedure
(Until now, I only have an InternalUrl but no ExternalUrl.)
PS C:\ > New-OfficeWebAppsFarm –InternalUrl “https://win-owas...”
–CertificateName "win-owas…" –EditingEnabled
ULS log shows
BaseDocument says editing is not supported [WebEditingEnabled: True] [SupportsEditing: True] [PinnedUsersRights: Read]
So far, I implemented these three REST service methods:
[OperationContract]
[WebInvoke
"GET":"api/wopi/files/{name}?access_token={access_token}"
"GET":"api/wopi/files/{name}/contents?access_token={access_token}"
"POST":"api/wopi/files/{name}/contents?access_token={access_token}"
Office Web App Server was downloaded from “Microsoft Volume Licensing Center”. I installed latest updates from Microsoft.
Did anybody succeed in writing to own WOPI an can give me some hints?
Thank you in advance.Hi,
The discovery xml contains many lines. The one for editing docx is:
<action
name="edit"
urlsrc="https://win-owas.cado.camos.de/we/wordeditorframe.aspx?"<ui=UI_LLCC=""&><rs=DC_LLCC=""&><showpagestats=PERFSTATS=""&>"
ext="docx" requires="locks,cobalt,update"/>
I am calling it this way:
<iframe
src="https://win-owas.cado.camos.de/we/wordeditorframe.aspx?WOPISrc=http%3a%2f%2fpc-ms.cado.camos.de%3a8000%2fWOPI%2fapi%2Fwopi%2Ffiles%2FAbout_Keyboard_Input.docx&access_token=5268690b-19c6-496d-8ae6-b694f8e7bd0c"
I’m not sure whether or not I implemented "locks,cobalt,update" correct, but I do not see any ‘edit-’network traffic from OWAS-Server to WOPI-Server. So I cannot debug anything. I will (re)check the articles you mentioned.
Thank you for your help. -
Cannot preview attachments using Office Web App Server 2013 ( Preview )
Got a lab environment to test Office Web App Server integration with Exchange 2013
i have followed the instructions given here
http://technet.microsoft.com/en-US/jj219455
http://technet.microsoft.com/library/2591b1be-92c4-4192-9f5e-e4e6b319170a
After all required configuration , i am still unable to preview the office documents from OWA
Receiving the following messages by clicking on the Preview link next to the attachment:
Word Document : "Sorry, there was a problem and we can't open this document. If this happens again, try opening the document in Microsoft Word."
Excel Document: "We couldn't find the file you wanted. It's possible the file was renamed, moved or deleted"
PowerPoint: "Sorry, we ran into a problem. Please try again"
As suggested i even see the Application Log the 140 and 142 Event IDs for MSExchange OWA
Already configured to enable the rendering of attachments through OWAS both on public and private computers:
This is what I can see in the ULS log on the Web App Server
WAC Server HttpModule: Beginning request at target [/p/PowerPointFrame.aspx?PowerPointView=SlideShowView&ui=en-US&rs=en-US&WOPISrc=https%3a%2f%2f<Server>%3a443%2fowa%2fuser02%2540<Domain>%2fwopi%2ffiles%2f%40%2fowaatt%3fowaatt%3dLFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%252bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%253d&]
in session [b373a48e-9fca-445b-a7b2-2966f11b18de]
b373a48e-9fca-445b-a7b2-2966f11b18de
UserSessionId=b373a48e-9fca-445b-a7b2-2966f11b18de
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI CheckFileInfo: Start [url:https://<Server>:443/owa/user02%40<Domain>/wopi/files/@/owaatt?owaatt=LFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%2bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%3d]
b373a48e-9fca-445b-a7b2-2966f11b18de
URL generated for WOPI CheckFile Request: https://<Server>:443/owa/user02%40<Domain>/wopi/files/@/owaatt?owaatt=LFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%2bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%3d&access_token=REDACTED_1086&access_token_ttl=0
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI Proof Data: AccessToken Hash '669582051' [1086 bytes], URL 'HTTPS://<Server>/OWA/USER02%40<Domain>/WOPI/FILES/@/OWAATT?OWAATT=LFMTMS01LTIXLTIWODU5NZU2NJITMTE4ODQ1NZE5NY04MDY2NJG5MC0XMTI5VUTGXJ%2BT0AGBAQEAQE1JDE5TSELQZJBHWWTXUTFTZI8YQ3HTSGZXS3IZB1GWZGVFWVHJDKLHBGWWC3F0DNJIQJBZZ0D2EXBDVCTAEEU%3D&ACCESS_TOKEN=REDACTED_1086&ACCESS_TOKEN_TTL=0'
[1354 bytes], TimeStamp '635169449614353585' [8 bytes]
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI Proof: Using Current private key (to sign) that matches Current public key BgIAAACkAABSU0ExAAgAAAEAAQDhPcfARgzhUlTFzo1jhCPHeoylNWp6pBbq6QM6CVQkbFyp4/I+mDzK4JA+AA3BFWLtpQEB7zIEbdjzhdsuYWYAJWBfvfX/3m2E3WRNhcPV8I2rA2T6qWj5Fb6eMNnoz4n2/1sqUXfyIA8mADXUebe9JNyJ+icPluUX+vTNm4m2IWbEgWmJNkgi9OUAq2hmd2lJifbJW8jNr1qzqBCE3ITFwr0L2svMrxfe5nKXVHbZa0EBYxMwHoc3ZkE0dZ0NPle9pq3MObg2+D5RN/w/B0axTJD7G/fQDpZbdsfvKA8mlyCn/vbNpooq5LgvGowTAWmG/tr1kWetfjePAbjBkIK5
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI Proof - Successfully signed the data with the Current private key [4 ms]
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI Proof Keys - WS Farm State has no Old key (this is expected if recently installed)
b373a48e-9fca-445b-a7b2-2966f11b18de
Cannot create WOPI Proof Token - could not find valid Old proof key data
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync (WOPICheckFile,WACSERVER) Starting [mode: GET, url: https://<Server>:443/owa/user02%40<Domain>/wopi/files/@/owaatt?owaatt=LFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%2bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%3d&access_token=REDACTED_1086&access_token_ttl=0]
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync (WOPICheckFile,WACSERVER) End Called
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync::GetResponseCallback - ContentLength:9327
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync::FProcessReadReturn - cbRead:9327
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync::FProcessReadReturn - cbRead:0
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync (WOPICheckFile,WACSERVER) Setting Completion [Time in ms: 3, Bytes Read: 9327 ContentLength: 9327]
b373a48e-9fca-445b-a7b2-2966f11b18de
HttpRequestAsync (WOPICheckFile,WACSERVER) SetCompletion Track start | setting trackers | WebRequest.Create() | Create() returned | setting request headers | setting user agent | setting keep alive | setting timeout callback | Start calling StartResponseProcessing
| StartResponseProcessing._req.BeginGetResponse() | BeginGetResponse() returned | StartResponseProcessing RETURNS | Start RETURNS | End.AsyncWaitHandle.WaitOne() | GetResponseCallback isSync:False | _req.EndGetResponse() | EndGetResponse() returned | RecordResponse
OK | _response.GetResponseStream() | _response.GetResponseStream() RETURNED | DoReadLoopFinished | _getStream.BeginRead() | ReadCallback.sync returning | BeginRead() -> sync:True | DoReadLoopFinished.FProcessReadReturn() | FProcessReadReturn._getStream.EndRead()
| EndR... b373a48e-9fca-445b-a7b2-2966f11b18de
...ead() -> 9327 | FProcessReadReturn._responseStream.Write() | FProcessReadReturn RETURNS True | FProcessReadReturn() -> true | _getStream.BeginRead() | ReadCallback.sync returning | BeginRead() -> sync:True | DoReadLoopFinished.FProcessReadReturn()
| FProcessReadReturn._getStream.EndRead() | EndRead() -> 0 | FProcessReadReturn._responseStream.Write() | FProcessReadReturn RETURNS False | FProcessReadReturn() -> false | DoReadLoopFinished RETURNS true | GetResponseCallback DoReadLoopFinished ->
TRUE | SetCompletion False | b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI Http Request Completed [host machine name:, version:, host correlation:]
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI: Could not deserialize file metadata [url:https://<Server>:443/owa/user02%40<Domain>/wopi/files/@/owaatt?owaatt=LFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%2bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%3d,
e:There was an error deserializing the object of type Microsoft.Office.OpenWebApplication.WopiCheckFileResponse. Encountered unexpected character '<'.]
b373a48e-9fca-445b-a7b2-2966f11b18de
WOPI: Invalid file metadata [url:https://<Server>:443/owa/user02%40<Domain>/wopi/files/@/owaatt?owaatt=LFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%2bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%3d,
triggers:(No Version No FileName No OwnerId), data:<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <!-- Copyright (c) 2011 Microsoft Corporation. All rights reserved. --> <!-- OwaPage = ASP.auth_logon_aspx -->
<!-- {57A118C6-2DA9-419d-BE9A-F92B0F9A418B} --> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html> <head> <meta http-equiv="X-UA-Compatible" content="IE=10"
/> <link rel="shortcut icon" href="/owa/auth/15.0.775/themes/resources/favicon.ico" type="image/x-icon"> <meta ...
b373a48e-9fca-445b-a7b2-2966f11b18de
...http-equiv="Content-Type" content="text/html; CHARSET=utf-8"> <meta name="Robots" content="NOINDEX, NOFOLLOW"> <title>Outlook Web App</title> <link type="text/css"
rel="stylesheet" href="/owa/auth/15.0.775/themes/resources/logon.css"> <script type="text/javascript" src="/owa/auth/15.0.775/scripts/premium/flogon.js"></script> <script type="text/javascript"
src="/owa/auth/15.0.775/scripts/premium/flayout.js"></script> <script type="text/javascript"> <!-- var a_fRC = 1; var g_fFcs = 1; var a_fLOff = 0; var a_fCAC = 0;
var a_fEnbSMm = 0; /// <summary> /// Is Mime Control installed? /// </summary> function IsMimeCtlInst(progid) { if (!a_fEnbSMm) return false; var oMimeVer = null; try
{ // TODO: ingore this on none IE browser // //oMimeVer = new ...
b373a48e-9fca-445b-a7b2-2966f11b18de
...ActiveXObject(progid); } catch (e) { } if (oMimeVer != null) return true; else return false; } /// <summary> /// Render out the S-MIME control
if it is installed. /// </summary> function RndMimeCtl() { if (IsMimeCtlInst("MimeBhvr.MimeCtlVer")) RndMimeCtlHlpr("MimeNSe2k3", "D801B381-B81D-47a7-8EC4-EFC111666AC0", "MIMEe2k3",
"mimeLogoffE2k3"); if (IsMimeCtlInst("OwaSMime.MimeCtlVer")) RndMimeCtlHlpr("MimeNSe2k7sp1", "833aa5fb-7aca-4708-9d7b-c982bf57469a", "MIMEe2k7sp1", "mimeLogoffE2k7sp1");
if (IsMimeCtlInst("OwaSMime2.MimeCtlVer")) RndMimeCtlHlpr("MimeNSe2k9", "4F40839A-C1E5-47E3-804D-A2A17F42DA21", "MIMEe2k9", "mimeLogoffE2k9"); } /// <summary>
/// Helper function to factor out the rendering of the S/MIME control. /// </summary> func...
b373a48e-9fca-445b-a7b2-2966f11b18de
...tion RndMimeCtlHlpr(objid, classid, ns, id) { document.write("<OBJECT id='" + objid + "' classid='CLSID:" + classid + "'></OBJECT>"); document.write("<?IMPORT namespace='"
+ ns + "' implementation=#" + objid + ">"); document.write("<" + ns + ":Logoff id='" + id + "' style='display:none'/>"); } --> </script>
<script> var mainLogonDiv = window.document.getElementById("mainLogonDiv"); var layout = DetermineLayout(); var
showPlaceholderText = false; var mainLogonDivClassName; if (layout == LayoutTypeEnum.Mouse) { mainLogonDivClassName = "mouse";
} else if (layout == LayoutTypeEnum.TouchNarrow) { mainLogonDivClassName = "tnarrow"; showPlaceholderText
= true; ...
b373a48e-9fca-445b-a7b2-2966f11b18de
... // Output meta tag for viewport scaling document.write('<meta name="viewport" content="width = 320, initial-scale = 1.0, user-scalable = no" />'); }
else { mainLogonDivClassName = "twide"; showPlaceholderText = true; }
function setPlaceholderText() { window.document.getElementById("username").placeholder = "domain\\user name";
window.document.getElementById("password").placeholder = "password"; window.document.getElementById("passwordText").placeholder = "password";
} function showPasswordClick() { var showPassword = window.document.getElementById("showPasswordCheck").checked;
window.document.getElementById("password"...
b373a48e-9fca-445b-a7b2-2966f11b18de
...).type = showPassword ? "input" : "password"; } </script> </head> <body class="signInBg" style="background: #f2f2f2 url('/owa/auth/15.0.775/themes/resources/bg_gradient_login.png')
repeat-x"/> <noscript> <div id="dvErr"> <table cellpadding="0" cellspacing="0"> <tr> <td><img src="/owa/auth/15.0.775/themes/base/warn.png"
alt=""></td> <td style="width:100%">To use Outlook Web App, browser settings must allow scripts to run. For information about how to allow scripts, consult the Help for your browser. If your browser doesn't
support scripts, you can download <a href="http://www.microsoft.com/windows/ie/downloads/default.mspx">Windows Internet Explorer</a> for access to Outlook Web App.</td> </tr> </table>
</div> </noscript> <form action...
b373a48e-9fca-445b-a7b2-2966f11b18de
...="/owa/auth.owa" method="POST" name="logonForm" ENCTYPE="application/x-www-form-urlencoded" autocomplete="off"> <input type="hidden" name="destination" value="https://<Server>/owa/user02@<Domain>/wopi/files/@/owaatt?owaatt=LFMtMS01LTIxLTIwODU5NzU2NjItMTE4ODQ1NzE5Ny04MDY2Njg5MC0xMTI5VUtGxj%2bT0AgBAQEAQE1jdE5tSElqZjBHWWtXUTFtZi8yQ3htSGZxS3Izb1gwZGVFWVhjdklhbGwwc3F0dnJiQjBzZ0d2eXBDVCtaeEU%3d&access_token=REDACTED_1086&access_token_ttl=0">
<input type="hidden" name="flags" value="4"> <input type="hidden" name="forcedownlevel" value="0"> <!-- Default to mouse class, so that things don't
look wacky if the script somehow doesn't apply a class --> <div id="mainLogonDiv" class="mouse"> <script> var mainLogonDiv = window.document.getElementById("mainLogonDiv");
... b373a48e-9fca-445b-a7b2-2966f11b18de
... mainLogonDiv.className = mainLogonDivClassName; </script> <div class="sidebar"> <div class="owaLogoContainer">
<img src="/owa/auth/15.0.775/themes/resources/olk_logo_white.png" class="owaLogo" aria-hidden="true" /> <img src="/owa/auth/15.0.775/themes/resources/olk_logo_white_small.png"
class="owaLogoSmall" aria-hidden="true" /> </div> </div> <div class="logonContainer"> <div id="lgnDiv" class="logonDiv"
onKeyPress="return checkSubmit(event)"> <div class="signInImageHeader" role="heading" aria-label="Outlook Web App ">
<img class="mouseHeader" src="/owa/auth/15.0.775/themes/resources/owa_text_blue.png" alt="Outlook Web App " /> </div>
<div class="signInInp...
b373a48e-9fca-445b-a7b2-2966f11b18de
...utLabel" id="userNameLabel" aria-hidden="true">Domain\user name:</div> <div><input id="username" name="username" class="signInInputText" role="textbox" aria-labelledby="userNameLabel"/></div>
<div class="signInInputLabel" id="passwordLabel" aria-hidden="true">Password:</div> <div><input id="password" onfocus="g_fFcs=0" name="password" value=""
type="password" class="signInInputText" aria-labelledby="passwordLabel"/></div> <div class="showPasswordCheck signInCheckBoxText">
<input type="checkbox" id="showPasswordCheck" class="chk" onclick="showPasswordClick()" /> <span>Show password</span>
</div> <div class="signInError" role="alert" tabIndex="0"> </div> <div id="expltxt"
class="signInExpl" role="alert"> ...
b373a48e-9fca-445b-a7b2-2966f11b18de
... </div> <div class="signInEnter"> <div onclick="clkLgn()" class="signinbutton" role="button" tabIndex="0" >
<img class="imgLnk"
src="/owa/auth/15.0.775/themes/resources/Sign_in_arrow.png" alt=""><span class="signinTxt">sign
in</span> </div> <input name="isUtf8" value="1" type="hidden"/> </div>
<div class="hidden-submit"><input type="submit" tabindex="-1"/></div> </div> </div> <div id="cookieMsg" class="logonDiv"
style="display:none"> <div class="signInHeader">Outlook Web App </div> <div class="signInExpl">Please enable cookies for this Web site.<br><br>Cookies are
currently disabled by your browser. Outlook Web...
b373a48e-9fca-445b-a7b2-2966f11b18de
... App requires that cookies be enabled. <br><br>For information about how to enable cookies, see the Help for your Web browser.<br><br><br></div> <div class="signInEnter" >
<div onclick="clkRtry()" style="cursor:pointer;display:inline"> <img class="imgLnk" src="/owa/auth/15.0.775/themes/resources/Sign_in_arrow.png"
alt=""><span class="signinTxt" tabIndex="0">retry</span> </div> </div> </div> </div> </form>
<script> if (showPlaceholderText) { setPlaceholderText(); } </script> </body> </html> ]
b373a48e-9fca-445b-a7b2-2966f11b18de
FileUnknownException loading powerpointframe: Microsoft.Office.Web.Common.EnvironmentAdapters.FileUnknownException: WOPI Check File at Microsoft.Office.Web.Apps.Common.WopiDocument.CheckWopiFile() at Microsoft.Office.Web.Common.BaseDocumentCache.CheckBaseDocumentInternal(BaseDocument
baseDoc, BaseUser user, Boolean requiresVersion, String canary, Boolean checkCanary, Boolean fUseCacheLookup) at Microsoft.Office.Server.Powerpoint.Web.UI.PptWebControl.CheckFileInfo()
b373a48e-9fca-445b-a7b2-2966f11b18de
ViewOpenEarlyHelper: no presentation Id, failing.
b373a48e-9fca-445b-a7b2-2966f11b18de
IsAuthenticated: False, IsAnonymous: False, AuthType:
b373a48e-9fca-445b-a7b2-2966f11b18de
Secure connection detected, redirecting service endpoint from ppt/view.svc/jsonAnonymous to ppt/view.https.svc/jsonAnonymous
b373a48e-9fca-445b-a7b2-2966f11b18de
WACServer HttpModule: EndRequest Called b373a48e-9fca-445b-a7b2-2966f11b18de
Any suggestions ...Hi,
Here is a similar thread for your reference:
http://social.technet.microsoft.com/Forums/en-US/ded515c8-cc0f-4ad4-bed6-e56a0636be79/exchange-office-web-apps-preview-does-not-work-in-owa-web?forum=exchangesvrclients
Hope it hleps you!
Thanks.
We
are trying to better understand customer views on social support experience, so your participation in this
interview project would be greatly appreciated if you have time.
Thanks for helping make community forums a great place. -
How to access JDBC Resource registered in Sun Java System App Server ?
I want to create a stand-alone JDBC application with Java SE using Swing technologies and JNDI technology. The purpose of using JNDI technology is to avoid change of Java Source Code every time I move the database to different location. This Java application will be used in a standalone PC installed with Windows XP Professional with no LAN / WAN connection. Of course, Internet connection is available with the PC.
I use JavaDB to store the data tables and the location of the database is D:\E-DRIVE\SAPDEV. Tomorrow, if I move this database to C:\SAPDEV or any network drive, I do not want to change the Java Source code. I want to use JNDI which, if I am not wrong, helps developers to avoid manual change of Java source code whenever the database location is changed. Changes have to be made only in the JNDI Name which contains all relevant information about the database in order to get connection no matter where the database SAPDEV is stored; it can be placed under D:\E-DRIVE directory or C:\ directory of the hard disk. To implement my intention, I started developing Java application as per the steps mentioned below:
Step 1:
To proceed, first, I sought the help of Sun Java System Application Server Admin Console. I created JNDI object for Connection Pool using the menu path Common Tasks->Resources->JDBC->Connection Pools.
JNDI Name : ABAPRPY
Resource Type : javax.sql.DataSource
Datasource class : org.apache.derby.jdbc.ClientDataSource
Description : ABAP Program Repository
The Connection Pool creation has options for General, Advanced and Additional Settings tabs and I made all the settings relevant to the database I created in D:\E-DRIVE\SAPDEV.
To confirm whether the above settings are correct, I pressed the Ping push button which is available in the General tab of the connection pool creation screen. The system responded with the message Ping Succeeded.
Step 2:
I created a JDBC Resource using the menu path Common Tasks->Resources->JDBC->JDBC Resources.
JNDI Name : jdbc/SAPDEV
Pool Name : ABAPRPY
Description : Database Connection for SAPDEV database
Status : Enabled
I can see all the above settings recorded in the domain.xml which is placed in the folder
C:\Sun\AppServer\domains\domain1\config
Step 3:
I have made sure that Sun Java System Application Server is up and running in the background with JavaDB server. I created a Java Program making sure the following JAR files are included in the classpath:
appserv-admin.jar
appserv-ee.jar
appserv-rt.jar
javaee.jar
fscontext.jar
Plus, the lib directory of JDK 1.6 & C:\Sun\AppServer\domains\domain1\config
Source code of the program is as follows: I used NetBeans IDE to create my project file.
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.naming.*;
import javax.activation.DataSource;
public class JNDILookup {
public static void main(String[] args) {
try {
InitialContext initCtx = new InitialContext();
DataSource ds = (DataSource) initCtx.lookup("java:comp/env/jdbc/sapdev>");
} catch (NamingException ex) {
Logger.getLogger(JNDILookup.class.getName()).log(Level.SEVERE, null, ex);
When I attempted to compile the above program in NetBeans IDE ,no compilation error reported. But while executing the program, I got the following run-time error message:
SEVERE: null
javax.naming.NameNotFoundException: No object bound for java:comp/env/jdbc/sapdev> [Root exception is java.lang.NullPointerException]
at com.sun.enterprise.naming.java.javaURLContext.lookup(javaURLContext.java:224)
at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:396)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at SAPConnect.JNDILookup.main(JNDILookup.java:21)
Caused by: java.lang.NullPointerException
at com.sun.enterprise.naming.java.javaURLContext.lookup(javaURLContext.java:173)
... 3 more
Now, I want to come out of this situation; at the same time, I want to preserve the settings I have made in the Sun Java System Application Server Admin Console. That is, I want to programmatically access the data source using Connection Pool created in Sun Java System Application Server Admin Console.
I request dear forum members to provide me an appropriate solution.
Thanks and regards,
K. Rangarajan.jay44 wrote:
Bare in mind I am attempting the context.lookup() from inside the container (my code is in a session bean). I have accessed the server and have my bean "say hello" first to verify the bean works OK, then I call a method with this rather standard code:
String jndiDataSourceName ="Second_EJB_Module_DataBase";
Logger.getLogger(DynamicPU.class.getName()).log(Level.INFO,"Programatically acquiring JNDI DataDource: "+ jndiDataSourceName);
InitialContext ctx;
try {
ctx = new InitialContext();
ds =(DataSource)ctx.lookup("java:comp/env/jdbc/"+jndiDataSourceName);
} catch (NamingException ex) {
Logger.getLogger(DynamicPU.class.getName()).log(Level.SEVERE, null, ex);
return "Exception generated trying to preform JDBC DataSource lookup. \n"+ex.toString();
But when I run the code the server log shows the initial context is created Ok, but an exception is thrown becasue the resource name is not found:
(and i have tried vriations of ctx.lookup("jdbc/"+jndiDataSourceName) etc etc
You are fine here. It works in container because the InitialContext properties have been supplied already. That was the link I forwarded earlier. The InitialContext you create locally needs to locate the container JNDI. That is what the properties specify.
Where I am confused is where you indicate the stack below is from the server log. So, you initiate a standalone (java main method) application, create an InitialContext, and you see the results in your app server log?
LDR5010: All ejb(s) of [EJB_Module_1] loaded successfully!
Programatically acquiring JNDI DataDource: Second_EJB_Module_DataBase
The log message is null.
javax.naming.NameNotFoundException: Second_EJB_Module_DataBase not found
at com.sun.enterprise.naming.TransientContext.doLookup(TransientContext.java:216)
at com.sun.enterprise.naming.TransientContext.lookup(TransientContext.java:188)
at com.sun.enterprise.naming.TransientContext.lookup(TransientContext.java:192)...
at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:555)
This is strange since I can see this resource (a JDBC connection named Second_EJB_Module_DataBase) is configured on the server from the server's admin console.
That is why you can obtain a lookup from within the container (app server).
For this lookup to work it may be that one must map the name inside an ejb-jar.xml deployed with the application, but I have also read some resources like jdbc connection should have a default name. Does anyone know if my lookup() should work without using an ejb-jar.xml mfile to explcitly map the reource for my application?
Both EBJ's and data sources can be referenced via JNDI. It's a remote lookup (that is normally optimized if it is running in the same JVM). You should not have any dependencies on a JDBC data source being set-up on ejb-jar.xml. That file can of course impact your EJB's. However, data sources are normally set-up on a container-specific basis (e.g., you probably did it through a console, but there is a spec somewhere about how to set up a data source via a resource the app server looks for; it varies from app server to app server). However, once you have that container-specific data source set-up, JNDI operates vendor-neutral. You should be able to take the code above and move it to JBoss or Weblogic or Tomcat or whatever (this is an ideal, in practice, the vendors sometimes put a data source in a name you would not expect, but again, you can use their JMX console to see what the JNDI name is).
(As I stated above if I have to use a deployment discriptor to get at this JNDI datasource, then solution is not "programmatic" as newly configured datasources could not be accessed without redeploying the entire application).
As JSchell alluded to, you will always have at least something vendor-specific. JNDI itself (the code you wrote) is totally portable. However, you have to set the various JNDI environment properties to a given vendor's spec. Ideally, you should not need a vendor's actual InitialContext application, but it's a possibility. Once you can safely cast to Context, you should be vendor-neutral (if not, demand your money back).
So that is exactly where I am stuck, trying to get the lookup to work and wondering if it should work without and xml file mapping the resource for my app.
What we ended up doing for standalone was to provide our own JNDI. If you look at the open source project JOTM, there are examples on how to use that with XBean (if integrating with Spring, as we did), you can easily set up a data source that runs standalone exactly as you get in the container. Another benefit is you get full JTA/JTS support and the ability to run XA transactions. (This might all be alphabet soup, but the app server gives it to you, and this is the way we ended up doing the same: JNDI + JTA + JTS + XA). It ends up the same application code uses a "vanilla" InitialContext and all we have to do is write one or two xml files (one for our app server, a couple for JOTM), and our actual code works the same.
I still think you have a shot at getting to the container's JNDI, just not using their full-blown app server JAR.
I think there must be a simple way to do this with an ejb-jar.xml, I am no expert in JNDI, I could be missing something simple, I will keep at it and post an answer here if I come up with it.
Thanks, jayIt is simple to code. Getting it to integrate with your app server, yes, that can be challenging. But it has nothing to do with EJB's. Write a simple test. Using nothing but DataSource and InitialContext. Let us know where you get stuck.
- Saish -
Peoplesoft HRMS 9.1, Peopletools 8.50 - PS PS fails when firing up app serv
Hi everyone.
I am working on setting up an environment under Oracle Enterprise Linux 5.4 (64 bit) running Oracle 11gR1 (11.0.6), Peopletools 8.50 (64 bit), Tuxedo 10gR3, Weblogic, Peoplesoft HRMS 9.1 (64 bit). Both Peopletools 8.50 and Peoplesoft HRMS 9.1 are relatively new. We are probably one of the first to set this up and we have an issue.
All of the software has been installed and configured. All database sql, datamover, and other scripts have been executed. Also, the database is fully populated.
We encounter an error when going into psadmin and trying to boot the domain HC:
CMDTUX_CAT:1685: ERROR: Application initialization failure
CMDTUX_CAT:827: ERROR: Fatal error encountered; initiating user error handler
We also receive the following errors:
Do you wish to see the error messages in the APPSRV.LOG file? (y/n) [n] :y
PSADMIN.3612 (0) [10/19/09 15:48:31](0) Begin boot attempt on domain HC
PSAPPSRV.3643 (0) [10/19/09 15:48:42](0) PeopleTools Release 8.50 (Linux) starting. Tuxedo server is APPSRV(99)/1
PSAPPSRV.3643 (0) [10/19/09 15:48:42](0) Cache Directory being used: /home/oracle/psft/pt/8.50/appserv/HC/CACHE/PSAPPSRV_1/
PSAPPSRV.3643 (0) [10/19/09 15:48:43](3) File: SQL Access ManagerSQL error. Stmt #: 2 Error Position: 0 Return: 404 - ORA-01017: invalid username/password; logon denied
PSAPPSRV.3643 (0) [10/19/09 15:48:43](1) GenMessageBox(200, 0, M): SQL Access Manager: File: SQL Access ManagerSQL error. Stmt #: 2 Error Position: 0 Return: 404 - ORA-01017: invalid username/password; logon denied
PSAPPSRV.3643 (0) [10/19/09 15:48:43](1) GenMessageBox(0, 0, M): Database Signon: Could not sign on to database HC with user PS.
PSAPPSRV.3643 (0) [10/19/09 15:48:43](0) Server failed to start
PSADMIN.3612 (0) [10/19/09 15:48:49](0) End boot attempt on domain HC
Do you wish to see the error messages in the TUXLOG.101909 file? (y/n) [n] :y
155108.sa2tech47.domain.com!PSADMIN.3722: Begin attempt on domain HC
155112.sa2tech47.domain.com!tmadmin.3743.3663685232.-2: TMADMIN_CAT:1330: INFO: Command: boot -A
155114.sa2tech47.domain.com!tmboot.3744.925238816.-2: 10-19-2009: Tuxedo Version 10.3.0.0, 64-bit
155114.sa2tech47.domain.com!tmboot.3744.925238816.-2: CMDTUX_CAT:1851: INFO: TM_BOOTTIMEOUT is set to 120 seconds
155114.sa2tech47.domain.com!tmboot.3744.925238816.-2: CMDTUX_CAT:1855: INFO: TM_BOOTPRESUMEDFAIL option is selected
155116.sa2tech47.domain.com!BBL.3745.1611062368.0: 10-19-2009: Tuxedo Version 10.3.0.0, 64-bit, Patch Level (none)
155116.sa2tech47.domain.com!BBL.3745.1611062368.0: LIBTUX_CAT:262: INFO: Standard main starting
155118.sa2tech47.domain.com!tmboot.3748.2436493632.-2: 10-19-2009: Tuxedo Version 10.3.0.0, 64-bit
155118.sa2tech47.domain.com!tmboot.3748.2436493632.-2: CMDTUX_CAT:1851: INFO: TM_BOOTTIMEOUT is set to 120 seconds
155118.sa2tech47.domain.com!tmboot.3748.2436493632.-2: CMDTUX_CAT:1855: INFO: TM_BOOTPRESUMEDFAIL option is selected
155118.sa2tech47.domain.com!PSWATCHSRV.3750.3590176352.-2: 10-19-2009: Tuxedo Version 10.3.0.0, 64-bit
155118.sa2tech47.domain.com!PSWATCHSRV.3750.3590176352.-2: LIBTUX_CAT:262: INFO: Standard main starting
155118.sa2tech47.domain.com!PSAPPSRV.3751.286221264.0: 10-19-2009: Tuxedo Version 10.3.0.0, 64-bit
155118.sa2tech47.domain.com!PSAPPSRV.3751.286221264.0: LIBTUX_CAT:262: INFO: Standard main starting
155119.sa2tech47.domain.com!PSAPPSRV.3751.286221264.0: LIBTUX_CAT:250: ERROR: tpsvrinit() failed
155119.sa2tech47.domain.com!tmboot.3748.2436493632.-2: tmboot: CMDTUX_CAT:827: ERROR: Fatal error encountered; initiating user error handler
155123.sa2tech47.domain.com!BBL.3745.1611062368.0: CMDTUX_CAT:26: INFO: The BBL is exiting system
155126.sa2tech47.domain.com!PSADMIN.3722: End boot attempt on domain HC
Issue is that when trying to connect and fire up the app server it fails on authentication with PS/PS. I have not changed any of the passwords. I also have searched and even run a fix located at:
http://tech.groups.yahoo.com/group/psftdba/message/577
I have also gone back and checked that:
1. The environment for weblogic is exported.
2. The weblogic daemon wlserver is running.
3. The environment for tuxedo is exported.
4. The tlisten daemon is running.
5. The tlisten listener is configured in /etc/services for port 3050.
6. Tested the sysadm, people accounts to ensure that I can log into the Oracle database. No passwords have been changed. Also checked that all of the tables exist and that they are populated with data.
7. Terminated the daemons and removed the ones that were hung using system resources using ipcrm.
8. Checked the UDDCONFIG file that was created by Peoplesoft to ensure that it was being read.
9. Went back and rechecked the installation and post-installation documentation for Tuxedo 10gR3, Weblogic, Peoplesoft PT 8.50, and Peoplesoft HRMS 9.1.
10. Went back and checked that all binaries and libraries were installed. (I did this prior to the install, but went back and checked again.)
11. Searched the error log files and looked up the codes presented. Checking on possible solutions (this is where I am now).
Anything that anyone can add would be most appreciated. I have log files from the server (of which I am still going through) that I can make available to anyone that is willing to help..
I will share any other findings as they become available and as I make progress.
Thanks in advance!
Walt
[email protected]"PSAPPSRV.3643 (0) 10/19/09 15:48:43(3) File: SQL Access ManagerSQL error. Stmt #: 2 Error Position: 0 Return: 404 - ORA-01017: invalid username/password; logon denied
PSAPPSRV.3643 (0) 10/19/09 15:48:43(1) GenMessageBox(200, 0, M): SQL Access Manager: File: SQL Access ManagerSQL error. Stmt #: 2 Error Position: 0 Return: 404 - ORA-01017: invalid username/password; logon denied"
sounds like something to do with connect-id or access-id.
are you able to login to datamover using sysadm user ?
if yes ...can you try to login and run
set log c:\temp\test1.log;
UPDATE PSSTATUS SET OWNERID = 'SYSADM';
UPDATE PSOPRDEFN SET SYMBOLICID = 'SYSADM1', OPERPSWD = 'upg2009', ENCRYPTED = 0 WHERE OPRID = 'VP1';
UPDATE PSACCESSPRFL SET ACCESSID = 'SYSADM', SYMBOLICID = 'SYSADM1', ACCESSPSWD = 'fin23SQL', VERSION = 0, ENCRYPTED = 0;
GRANT SELECT ON PSSTATUS TO people;
GRANT SELECT ON PSOPRDEFN TO people;
GRANT SELECT ON PSACCESSPRFL TO people;
REM - ENCRYPT PASSWORD
SET LOG c:\temp\encrypt.log;
ENCRYPT_PASSWORD *;
Also check PSDBOWNER, it should contain only one row and DB Name should be in caps/lower same case as DB name ...somting it also causes issue. -
Or I guess a related question is what version of apache comes with the latest App Server Patch Set (10.1.3.4.0)?
We are running OAS 10.1.3.3.x and we are having issues with URLs that end in a number but which have query parameters at the end.
E.g. http://<stuff_here>/1?type=table&format=html
The URLs come from REST-ful GET operations. It seems like the HTTP server just ignores the query parameters completely.
When we run against stand-alone OC4J which includes an embedded HTTP server, such URLs work as expected.
We are hoping that perhaps the latest patch set for the full Oracle Application Server 10g will overcome this issue.
But if we need to move to a later Oracle HTTP Server (like the one that comes as an option for the Oracle 11g database installation) we would be willing to do so.
Comments related to this are welcome.
Thanks
JimHi,
Does anyone have experiece getting Apex working with secured BI publisher?
The error I am getting when PDF printing from Apex to BI pub is:
"ORA-20001: The printing engine could not be reached because either the URL specified is incorrect or a proxy URL needs to be specified.
Error failed
OK "
Please note, network services in 11G are already configured; thus I am able to print from Apex to non-secured BI pub.
Thanks,
Jed -
Spool to PDF. Approach is Spool- app server then app server to local pdf
Hello Experts,
My requirement is: I want to create PDF file from spool number. As my program works in background and FM WS_DOWNLOAD/GUI_DOWNLOAD wonu2019t work in batch mode, I am trying to find its alternative.
I am tiring to upload the internal table PDF[] return by FM CONVERT_OTFSPOOLJOB_2_PDF to application server. But while writing file in text mode, program dumps as it wont support all characters. Hence I am tiring to write in binary mode. Main problem occurs when I download the file from application server, I want to save that file in PDF format on local machine.
I am able to download file from app server to local m/c but that pdf file does not open and says conversion problem. I am sure there must be some steps which I am missing. Might be there is some Fm which convert bin to Text/ASCII.
Can anyone help me this?
-ShwetaIf you can avoid using the spool and instead use OTF, this may be easier. Sorry if this doesn't apply.
I tried going from SAPScript to OTF and writing the lines of the PDF table in binary mode but that didn't work for me for some reason.
data: lv_pdf_file type xstring,
lv_size type i,
lt_pdf_lines type STANDARD TABLE OF tline.
* pt_otf is passed from the CLOSE_FORM FM
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
FORMAT = 'PDF'
IMPORTING
BIN_FILESIZE = lv_size
BIN_FILE = lv_pdf_file
TABLES
otf = pt_otf
lines = lt_pdf_lines
EXCEPTIONS
ERR_MAX_LINEWIDTH = 1
ERR_FORMAT = 2
ERR_CONV_NOT_POSSIBLE = 3
ERR_BAD_OTF = 4
OTHERS = 5
open dataset lv_file for output in binary mode.
transfer lv_pdf_file to lv_file.
close dataset lv_file.
Maybe you are looking for
-
so i upgraded my iphone to the new ios 5, and for some reason i dont have any new features, no imessages or anything. it didnt ask me to set anything up, is there a way i can fix this?
-
Parameters of Date Datatype for stored Procedure
I have a stored procedure where i hav two date parameters..initial i had the parameter datatype as varchar and in query i used the format to_date(fromdate ,'dd/mm/yyyy') My fromdate is in the format 31-01-2010 everything worked fine...now i changed t
-
SBO 2007A PL46 - Inventory Audit Report same warehouse exist for twice
Hi All, Is anyone encounter the same error? As when i trying to generate the Inventory Audit Report for all the warehouses and check the option "Group By Warehouses", i get the results that the same warehouse are appear twice in the report. As for th
-
VBAP-ANZSN not getting updated when writing serial number to order
Hey ABAP, i got some Problem with serial numbers. We have a rental process, where user gives in serial number at time of delivery. Since we need to create orders based on original order, we need to take the serialnumber from the delivery and write it
-
I have (among others) 3 entries in Address Book with birthday dates: 1978-04-22, 1981-08-21 and 1982-12-23. Non of them are shown in ical. But there is more. When i search for these people in ical search box i get following results: all these persons