[U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Kevin King
I have a test UOJ program communicating to a backend Unidata/AIX server that
seems to work fine with the exception (pun intended) of UniFile write.  The
file opens fine, we can read the record fine, but when attempting to update
the record, we get this:

asjava.uniobjects.UniFileException: The RPC failed
at asjava.uniobjects.UniFile.write(UniFile.java:1288)
at Test.main(Test.java:46)

Here's the offending code:

43 UniFile uFile = uSession.open(PRODUCT);
44 UniDynArray record = new UniDynArray(uFile.read(001!JM7012CK-6EU-F));
45 record.replace(73,TEST TEST TEST);
46 uFile.write(001!JM7012CK-6EU-F,record);

Probably something stupidly simple; any ideas?

-Kevin
http://www.PrecisOnline.com
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Charles_Shaffer
File permissions?

Charles Shaffer
Senior Analyst
NTN-Bower Corporation




Kevin King precisonl...@gmail.com
Sent by: u2-users-boun...@listserver.u2ug.org
01/11/2010 08:24 AM
Please respond to U2 Users List

 
To: U2 Users List u2-users@listserver.u2ug.org
cc: 
Subject:[U2] UOJ The RPC Failed on Unifile.write()


I have a test UOJ program communicating to a backend Unidata/AIX server 
that
seems to work fine with the exception (pun intended) of UniFile write. The
file opens fine, we can read the record fine, but when attempting to 
update
the record, we get this:

asjava.uniobjects.UniFileException: The RPC failed
at asjava.uniobjects.UniFile.write(UniFile.java:1288)
at Test.main(Test.java:46)

Here's the offending code:

43 UniFile uFile = uSession.open(PRODUCT);
44 UniDynArray record = new UniDynArray(uFile.read(001!JM7012CK-6EU-F));
45 record.replace(73,TEST TEST TEST);
46 uFile.write(001!JM7012CK-6EU-F,record);

Probably something stupidly simple; any ideas?

-Kevin
http://www.PrecisOnline.com
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

-- 
This email was Anti Virus checked by Astaro Security Gateway. 
http://www.astaro.com


___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread John Woollam
If your Unifile is also a SQL Table, and the data you put into 73 is
illegal for that table, it will cause a write failure as the SQL
checking will not allow you to write it.

John Woollam  |  Group Financial Systems  |  Travis Perkins PLC  |
01604 682751
-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Kevin King
Sent: 11 January 2010 14:25
To: U2 Users List
Subject: [U2] UOJ The RPC Failed on Unifile.write()

I have a test UOJ program communicating to a backend Unidata/AIX server
that
seems to work fine with the exception (pun intended) of UniFile write.
The
file opens fine, we can read the record fine, but when attempting to
update
the record, we get this:

asjava.uniobjects.UniFileException: The RPC failed
at asjava.uniobjects.UniFile.write(UniFile.java:1288)
at Test.main(Test.java:46)

Here's the offending code:

43 UniFile uFile = uSession.open(PRODUCT);
44 UniDynArray record = new
UniDynArray(uFile.read(001!JM7012CK-6EU-F));
45 record.replace(73,TEST TEST TEST);
46 uFile.write(001!JM7012CK-6EU-F,record);

Probably something stupidly simple; any ideas?

-Kevin
http://www.PrecisOnline.com
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

html
head
meta http-equiv=Content-type content=text/html; charset=UTF-8
/head
body
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'This e-mail and any 
attachments are confidential and intended solely for the use of the addressee 
only. If you have received this message in error, you must not copy, distribute 
or disclose the contents; please notify the sender immediately and delete the 
message. /SPAN/P
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'This message is 
attributed to the sender and may not necessarily reflect the view of Travis 
Perkins plc or its subsidiaries (Travis Perkins). Agreements binding Travis 
Perkins may not be concluded by means of e-mail communication. /SPAN/P
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'E-mail transmissions are 
not secure and Travis Perkins accepts no responsibility for changes made to 
this 
message after it was sent. Whilst steps have been taken to ensure that this 
message is virus free, Travis Perkins accepts no liability for infection and 
recommends that you scan this e-mail and any attachments. /SPAN/P
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'Part of Travis Perkins 
plc. Registered Office: Lodge Way House, Lodge Way, Harlestone Road, 
Northampton, NN5 7UG. /SPAN/P
/BODY
/HTML

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Kevin King
File permissions are wide open.  I am intrigued however by the SQL mention.
The file in question is defined in the VSG under a separate SQL name
(PRODUCT_1).  And oddly enough I keep getting a RPC parameter mismatch
error when I try to view the mapped attributes with the VSG.  Certainly the
VSG definitions aren't used by UOJ are they?
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread John Woollam
We find that even in a simple, running on Unix, Databasic program, if
you try to write illegal data to a SQL table then you get a WRITE
FAILURE error, so we guess that the SQL integrity checking is working
even on a direct write from any source.

John Woollam  |  Group Financial Systems  |  Travis Perkins PLC  |
01604 682751

-Original Message-
From: u2-users-boun...@listserver.u2ug.org
[mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Kevin King
Sent: 11 January 2010 15:02
To: U2 Users List
Subject: Re: [U2] UOJ The RPC Failed on Unifile.write()

File permissions are wide open.  I am intrigued however by the SQL
mention.
The file in question is defined in the VSG under a separate SQL name
(PRODUCT_1).  And oddly enough I keep getting a RPC parameter mismatch
error when I try to view the mapped attributes with the VSG.  Certainly
the
VSG definitions aren't used by UOJ are they?
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

html
head
meta http-equiv=Content-type content=text/html; charset=UTF-8
/head
body
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'This e-mail and any 
attachments are confidential and intended solely for the use of the addressee 
only. If you have received this message in error, you must not copy, distribute 
or disclose the contents; please notify the sender immediately and delete the 
message. /SPAN/P
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'This message is 
attributed to the sender and may not necessarily reflect the view of Travis 
Perkins plc or its subsidiaries (Travis Perkins). Agreements binding Travis 
Perkins may not be concluded by means of e-mail communication. /SPAN/P
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'E-mail transmissions are 
not secure and Travis Perkins accepts no responsibility for changes made to 
this 
message after it was sent. Whilst steps have been taken to ensure that this 
message is virus free, Travis Perkins accepts no liability for infection and 
recommends that you scan this e-mail and any attachments. /SPAN/P
P style=MARGIN-TOP: 0pt; MARGIN-BOTTOM: 0ptSPAN 
style=FONT-SIZE: 8.2pt; FONT-FAMILY: 'MS Sans Serif'Part of Travis Perkins 
plc. Registered Office: Lodge Way House, Lodge Way, Harlestone Road, 
Northampton, NN5 7UG. /SPAN/P
/BODY
/HTML

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Kevin King
Well, I finally got the file mapping to view in the VSG, and the field being
updated is a simple 30 character alphanumeric.  Just for grins I changed the
program to read the record and write it instantly without changing anything,
and the RPC error persists.

I wonder if this might have something to do with the version of Unidata
running on that server?  When I type version @ TCL I get this:

UniObjects... 5.2 Yes
The current account is version 6.1.

Weird, huh?  I think the production box for this site is 6.1 and they
reloaded this dev instance from production after a hard disk fail.  And
we're using a reasonably current UOJ version; could that discrepancy explain
the issues?
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Kevin King
Follow up: I created a new file and was able to write a new record into the
new file from UOJ with no problems at all.  Both files are static hashed.
Thinking maybe there could be some SQL implication I copied the VOC pointer
to a new name and tried accessing the data via that name and the RPC error
persists.  Both the old file and new file are in the same directory, same
permissions, same ownership, and I can read and write to the new file but
not the old one.

Any other things I could check?
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Colin Alfke
What about the write permissions on the file in VSG?
You can run updatevoc from a shell to clean up the version mis-match.

Hth
Colin Alfke
Calgary, Canada

-Original Message-
From: Kevin King
Sent: January 11, 2010 8:21 AM
To: U2 Users List
Subject: Re: [U2] UOJ The RPC Failed on Unifile.write()

Follow up: I created a new file and was able to write a new record into the
new file from UOJ with no problems at all.  Both files are static hashed.
Thinking maybe there could be some SQL implication I copied the VOC pointer
to a new name and tried accessing the data via that name and the RPC error
persists.  Both the old file and new file are in the same directory, same
permissions, same ownership, and I can read and write to the new file but
not the old one.

Any other things I could check?

___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Kevin King
The only privileges on the file are OWNER, and even connecting as the owner
of the file doesn't change the error.  So just for grins I setup PUBLIC with
all privileges and ... no change.

Again, I'm trying to connect to PRODUCT but in the VSG it's called PRODUCT_1
if that makes any difference?
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users


Re: [U2] UOJ The RPC Failed on Unifile.write()

2010-01-11 Thread Kevin King
Mystery solved!  And of course, it had nothing to do with UOJ at all.  The
file had an index defined which was calling an SB+ subroutine
(SB.SMART.QUERY).  Once that field was removed from the index the updates
are proceeding according to plan.

Thanks everyone for your nudging and advice!
___
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users