How to get the previous group on XML element
My XML structure goes like this.<? XML version = "1.0" encoding = "UTF-8"? >
< SA321 >
PT BOOK < P_BOOK > < / P_BOOK >
< P_YEAR > 2009 < / P_YEAR >
< LIST_G_FAMILY >
< G_FAMILY >
< PARENT_FAMILY > 2240 < / PARENT_FAMILY >
< FAM_CODE_DESC > Cruiser informatico < / FAM_CODE_DESC >
< SUBTOT_FLAG > Y < / SUBTOT_FLAG >
< NEW_USED > NEW < / NEW_USED >
< LIST_G_ASSET >
< G_ASSET >
< ASSET_DESCR > 2240 - Cruiser informatico < / ASSET_DESCR >
< ACQUISITION_YEAR > 2009 < / ACQUISITION_YEAR >
JANUARY < EFFECTIVE_MONTH > < / EFFECTIVE_MONTH >
< EFFECTIVE_YEAR > 2009 < / EFFECTIVE_YEAR >
< ASSET_AMOUNT > 3000 < / ASSET_AMOUNT >
< EXEMPT_GAIN_AMOUNT > 450 < / EXEMPT_GAIN_AMOUNT >
< EXPECTED_LIFE_YRS / >
< PRV_FY_NBV > 0 < / PRV_FY_NBV >
< RATES_DEC > 37.5 < / RATES_DEC >
< RATE_FROM_LAW > 50 < / RATE_FROM_LAW >
< RATES_DEC1 / >
< 1 > 0 < / 1 >
< FISCAL_LIMIT > 1275 < / FISCAL_LIMIT >
< DEPRN_RATE > 25 < / DEPRN_RATE >
< PY_DEPRN_RESERVE > 0 < / PY_DEPRN_RESERVE >
< YTD_DEPRN > 749.99 < / YTD_DEPRN >
< ACCUM_DEPRN > 749.99 < / ACCUM_DEPRN >
< NET_BOOK_VALUE > 2250.01 < / NET_BOOK_VALUE >
< YTD_IMPAIRMENT > 0 < / YTD_IMPAIRMENT >
< IMPAIRMENT_RESERVE > 0 < / IMPAIRMENT_RESERVE >
< ACCUM_LOST_RATES > 0 < / ACCUM_LOST_RATES >
< DEPR_REINT_LOSS_NOTEXP > 0 < / DEPR_REINT_LOSS_NOTEXP >
< GAIN_AMOUNT > 600 < / GAIN_AMOUNT >
< GAIN_YEAR > 2006 < / GAIN_YEAR >
< > 110270 ASSET_ID < / ASSET_ID >
< > 110270 ASSET_ID < / ASSET_ID >
< REINT_NOT_ACC > 437.5 < / REINT_NOT_ACC >
< PY_COL15 > 0 < / PY_COL15 >
< LIST_G_COL15 >
< G_COL15 >
< COL15_TOT > 0 < / COL15_TOT >
< COL16_TOT / >
< COL_16 > 0 < / COL_16 >
< / G_COL15 >
< / LIST_G_COL15 >
< / G_ASSET >
< G_ASSET >
< ASSET_DESCR > 2240 - Cruiser informatico < / ASSET_DESCR >
< ACQUISITION_YEAR > 2009 < / ACQUISITION_YEAR >
JUNE < EFFECTIVE_MONTH > < / EFFECTIVE_MONTH >
< EFFECTIVE_YEAR > 2009 < / EFFECTIVE_YEAR >
< ASSET_AMOUNT > 1500 < / ASSET_AMOUNT >
< EXEMPT_GAIN_AMOUNT > 0 < / EXEMPT_GAIN_AMOUNT >
< EXPECTED_LIFE_YRS / >
< PRV_FY_NBV > 0 < / PRV_FY_NBV >
< RATES_DEC > 40 < / RATES_DEC >
< RATE_FROM_LAW > 50 < / RATE_FROM_LAW >
< RATES_DEC1 / >
< 1 > 0 < / 1 >
< FISCAL_LIMIT > 750 < / FISCAL_LIMIT >
< DEPRN_RATE > 20 < / DEPRN_RATE >
< PY_DEPRN_RESERVE > 0 < / PY_DEPRN_RESERVE >
< YTD_DEPRN > 316.95 < / YTD_DEPRN >
< ACCUM_DEPRN > 166.95 < / ACCUM_DEPRN >
< NET_BOOK_VALUE > 1333.05 < / NET_BOOK_VALUE >
< YTD_IMPAIRMENT > 150 < / YTD_IMPAIRMENT >
< IMPAIRMENT_RESERVE > 150 < / IMPAIRMENT_RESERVE >
< ACCUM_LOST_RATES > 2.92 < / ACCUM_LOST_RATES >
< DEPR_REINT_LOSS_NOTEXP > 0 < / DEPR_REINT_LOSS_NOTEXP >
< GAIN_AMOUNT > 0 < / GAIN_AMOUNT >
< GAIN_YEAR / >
< > 110289 ASSET_ID < / ASSET_ID >
< > 110289 ASSET_ID < / ASSET_ID >
< REINT_NOT_ACC > 89,32 < / REINT_NOT_ACC >
< PY_COL15 > 0 < / PY_COL15 >
< LIST_G_COL15 >
< G_COL15 >
< COL15_TOT > 0 < / COL15_TOT >
< COL16_TOT / >
< COL_16 > 0 < / COL_16 >
< / G_COL15 >
< / LIST_G_COL15 >
< / G_ASSET >
< / G_FAMILY >
< / LIST_G_FAMILY >
< / SA321 >
Now, I have a query like the following.
Select *.
FROM (SELECT sap_getFileContent ('o5875854.xml', 'DIR') report_data)
T FROM dual)
xmltable)
"SA321/LIST_G_FAMILY/G_FAMILY/LIST_G_ASSET/G_ASSET.
by the way of xmltype (t.report_data)
path of VARCHAR2 (50) column column1 ' / SA321, LIST_G_FAMILY, G_FAMILY, PARENT_FAMILY.
, path VARCHAR2 (100) Column2 "ASSET_DESCR."
, Column3 VARCHAR2 (50) path 'EFFECTIVE_MONTH '.
, NUMBER column4 path 'EFFECTIVE_YEAR '.
, path NUMBER column 5 "ASSET_AMOUNT".
, path NUMBER column6 "EXEMPT_GAIN_AMOUNT".
, path NUMBER column7 'EXPECTED_LIFE_YRS '.
, path NUMBER column8 'YTD_DEPRN '.
, path NUMBER column9 "PY_DEPRN_RESERVE".
, path NUMBER column10 'RATE_FROM_LAW '.
, column11 NUMBER path '1 '.
, path NUMBER column12 'FISCAL_LIMIT '.
, path NUMBER column13 'YTD_IMPAIRMENT '.
, path NUMBER column14 'ACCUM_LOST_RATES '.
, path NUMBER column15 'YTD_IMPAIRMENT '.
, path NUMBER column16 ' LIST_G_COL15/G_COL15/COL_16.
) x ;
the query always returns NULL for collumn1. Can someone help me please.
Concerning
SAP
Hello
Your example of XML code is not correct, there is no LIST_G_ASSET element closing tag.
But I guess that's not the real problem.
the query always returns NULL for collumn1.
The important thing to understand is that the paths that you declare in the COLUMNS clause are relative to the context item is past the main XQuery expression. He knows more about the rest of the document, in particular of his ancestors.
In this case, you try to process a node whose absolute path would be
/SA321/LIST_G_FAMILY/G_FAMILY/PARENT_FAMILY
in a document which the node root is G_ASSET.
The solution is to divide the query into two parts, the first one finds PARENT_FAMILY and the collection of G_ASSET and the second more shreds the collection G_ASSET is passed the first XMLTable in relational lines:
SQL> SELECT x1.column1
2 , x2.*
3 FROM XMLTable(
4 '/SA321/LIST_G_FAMILY/G_FAMILY'
5 passing xmltype(bfilename('TEST_DIR','o5875854.xml'), nls_charset_id('AL32UTF8'))
6 columns
7 column1 VARCHAR2(50) path 'PARENT_FAMILY'
8 , assets XMLType path 'LIST_G_ASSET'
9 ) x1
10 , XMLTable(
11 '/LIST_G_ASSET/G_ASSET'
12 passing x1.assets
13 columns
14 column2 VARCHAR2(100) path 'ASSET_DESCR'
15 , column3 VARCHAR2(50) path 'EFFECTIVE_MONTH'
16 , column4 NUMBER path 'EFFECTIVE_YEAR'
17 , column5 NUMBER path 'ASSET_AMOUNT'
18 , column6 NUMBER path 'EXEMPT_GAIN_AMOUNT'
19 , column7 NUMBER path 'EXPECTED_LIFE_YRS'
20 , column8 NUMBER path 'YTD_DEPRN'
21 , column9 NUMBER path 'PY_DEPRN_RESERVE'
22 , column10 NUMBER path 'RATE_FROM_LAW'
23 , column11 NUMBER path 'CASE1'
24 , column12 NUMBER path 'FISCAL_LIMIT'
25 , column13 NUMBER path 'YTD_IMPAIRMENT'
26 , column14 NUMBER path 'ACCUM_LOST_RATES'
27 , column15 NUMBER path 'YTD_IMPAIRMENT'
28 , column16 NUMBER path 'LIST_G_COL15/G_COL15/COL_16'
29 ) x2
30 ;
COLUMN1 COLUMN2 COLUMN3 COLUMN4 COLUMN5 COLUMN6 COLUMN7 COLUMN8 COLUMN9 COLUMN10 COLUMN11 COLUMN12 COLUMN13 COLUMN14 COLUMN15 COLUMN16
---------- -------------------------------- ----------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ----------
2240 2240-Equipamento informatico JANUARY 2009 3000 450 749,99 0 50 0 1275 0 0 0 0
2240 2240-Equipamento informatico JUNE 2009 1500 0 316,95 0 50 0 750 150 2,92 150 0
Tags: Database
Similar Questions
-
How to get the value of an xml element attributes
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0
I'm trying to parse an XML document
< response >
< well uwi = "102112900816W400" > < / well >
< production >
< PRODUCING_ENTITY >
< NUMBER YEAR = '2009' >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< NUMBER YEAR = '2010' >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< NUMBER YEAR = '2011' >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< NUMBER YEAR = '2012' >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< / PRODUCING_ENTITY >
< / production >
< / well >
< well uwi = "100092900816U400" > < / well >
< production >
< PRODUCING_ENTITY >
< NUMBER YEAR = "1999" >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< NUMBER YEAR = '2000' >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< NUMBER YEAR = '2001' >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< NUMBER YEAR = "2003" >
< NUMBER of MONTHS = LAST_DAY '1' = "31" / >
< NUMBER of MONTHS = LAST_DAY '2' = "28" / >
< NUMBER of MONTHS = LAST_DAY "3" = "30" / >
< / YEAR >
< / PRODUCING_ENTITY >
< / production >
< / well >
< / answer >
For the purposes of the practice, I have saved this in my table tdw_test_xml_files;
My goal is to get the /WELL/@uwi and /YEAR/@NUMBER
UWI YEAR
------ ---------------
102112900816W400 2009
102112900816W400 2010
102112900816W400 2011
102112900816W400 2012
100092900816U400 1999
100092900816U400 2000
100092900816U400 2001
100092900816U400 2003
I tried this... but I can't get the value of the attribute for the element < YEAR >
Select r.uwi, r.year
of tdw_test_xml_files.
XMLTABLE
(
"for $WELL in $ response/WELL/good.
for $DEPT to $UWIIDX in $WELL, Production, PRODUCING_ENTITY, YEAR
return < RESULT >
University of the West Indies West <>{fn:data($WELL/@uwi)} < / UWI >}
{
$WELL/production/PRODUCING_ENTITY/YEAR [$UWIIDX]-> (I don't know how to extract the value of the attribute here)
}
< / RESULT > '
passing FILECONTENT as 'GOOD '.
columns
UWI VARCHAR (50),
YEAR vARCHAR2 (24)
) r
/
If I do this; I get the Cartesian plan result set, which is not my goal
SELECT xtab.*, xtab2.*
OF tdw_test_xml_files, XMLTable (' for $i in/Response/Well)
Return $i"
PASSAGE filecontent
Uwi varchar2 COLUMNS (50) PATH'@uwi'
rn for ORDINALITE
) xtab
, XMLTable (' for $i in/Response/Well/Production/PRODUCING_ENTITY/YEAR)
Return $i"
PASSAGE filecontent
COLUMNS year varchar2 (50) PATH'@NUMBER'
) xtab2;
Any help will be highly appreciated thanks...I'm just curious to know how make the query now in unique XMLTable, not that I am forced by using x number of xmltable; - P, just look more clean...
Here goes:
SQL> SELECT x.* 2 FROM tdw_test_xml_files t 3 , XMLTable( 4 'for $i in /Response/Well 5 , $j in $i/Production/PRODUCING_ENTITY/YEAR 6 , $k in $j/MONTH 7 return element r { 8 $i/@uwi 9 , element year {data($j/@NUMBER)} 10 , element month {data($k/@NUMBER)} 11 }' 12 passing t.filecontent 13 columns uwi varchar2(50) path '@uwi' 14 , yr varchar2(4) path 'year' 15 , mon varchar2(2) path 'month' 16 ) x 17 ; UWI YR MON ------------------------------ ---- --- 102112900816W400 2009 1 102112900816W400 2009 2 102112900816W400 2009 3 102112900816W400 2010 1 102112900816W400 2010 2 102112900816W400 2010 3 102112900816W400 2011 1 102112900816W400 2011 2 102112900816W400 2011 3 102112900816W400 2012 1 102112900816W400 2012 2 102112900816W400 2012 3 100092900816U400 1999 1 100092900816U400 1999 2 100092900816U400 1999 3 100092900816U400 2000 1 100092900816U400 2000 2 100092900816U400 2000 3 100092900816U400 2001 1 100092900816U400 2001 2 100092900816U400 2001 3 100092900816U400 2003 1 100092900816U400 2003 2 100092900816U400 2003 3 24 rows selected
-
I'm new in indesign scripting, please tell me how to write a script to get the contents of an XML element and then sort all the content
Hello
Can the code below is useful for you, but I do not know how to sort.
Change the tag based on your employment application.
-
How to pass the content of an xml element in the text frame in inDesign Script
var XMLFile = File.openDialog ("select XML Files... ») ;
var doc = app.activeDocument;
If (!) App.Documents.Length)
{alert ("ERROR: Document not opened");}
return;
}
doc.importXML (XMLFile);
var firstFigureNode = doc.xmlElements [0] .xmlElements [1] .xmlElements [0];
var lableNode = firstFigureNode.xmlElements [0];
var lableNodeText = lableNode.contents;
myFrame var = doc.textFrames.add ({geometricBounds: [-13, 13, 3, -3]});
lableNodeText.move (LocationOptions.AFTER, myFrame.texts [0]);
========================================================
My requirement is: == > > move the content of an xml element in the text by inDesign Script block, but XML InDesign file Structure should not be change & data in the XML Structure should remain as it was before...
I tried to code above, but it does not work...
Please can someone help me in solving this problem...
It does not work correctly...
It moves firstFigureNode in myFrame...
firstFigureNode.placeXML (myFrame);
===>> For Apple Script try below Code ===>>
myFrame markup using firstFigureNode
-
Hi Experts,
Can someone tell me to get the previos months beginning and end date...
If m 20-dec-2012 then output should be 1 November 2012 and November 30, 2012...
Thnx in advance...977490 wrote:
Hi Experts,Can someone tell me to get the previos months beginning and end date...
If m 20-dec-2012 then output should be 1 November 2012 and November 30, 2012...
Thnx in advance...
Use
select trunc(trunc(sysdate,'MM')-1,'MM') "First Day of Last Month", trunc(sysdate,'MM')-1 "Last Day of Last Month" from dual
20-dec-2012
Select TRUNC (trunc (to_date (20-dec-2012', 'mon-dd-yyyy'), "LUN")-1, 'MY')
"First day of the month pr."
trunc (to_date (20-dec-2012', 'mon-dd-yyyy'), "LUN")-1
"Last day of the previous month.
of the doublePublished by: Rahul India on January 24, 2013 14:37
-
How to get the previous month and year accordingly
Hi friends,
I wanted to select the month as a number like 4 and the new year 2011
but I want to choose the previous month from sysdate
as if the sysdate is June 10, 2011
It should give me 5 months and
in the year, it should give as 2011
If the sysdate is January 1, 2012
the month should be like 12 and year should be in 2011
Thank youHello
776317 wrote:
Thank you very much I just the 0 being the prefix... can you pls how to avoid that too well plsTO_CHAR ( ADD_MONTHS (SYSDATE, -1) , 'FMmm yyyy' )
For more information on the FM, wee manual SQL language modifier works:
http://download.Oracle.com/docs/CD/B28359_01/server.111/b28286/sql_elements004.htm#sthref456 -
How to get the previous record that meets a criterion?
Hello!
I am trying to create a query that adds information which finally fixed an element for a given 'pause'.
I have a table, let's call it actionHistory, which looks like:
ID | timestamp | action | author
------------------------------------------------
101477 | 2010-05-10 09:10:20 | Difficulty | Tim
101477 | 2010-05-10 09:10:30 | change | John
101477 | 2010-05-10 09:10:40 | breaking | Maggie
101477 | 2010-05-10 09:10:50 | Difficulty | Rick
222222 | 2010-05-10 09:10:30 | change | Lewis
222222 | 2010-05-11 09:10:40 | breaking | Maggie
222222 | 2010-05-11 09:10:50 | Difficulty | Tim
222222 | 2010-05-12 09:10:40 | Difficulty | Maggie
222222 | 2010-05-13 09:10:40 | breaking | Albert
I'm looking for is the following result:
ID | timestamp | action | author | lastFixBy
-----------------------------------------------------------
101477 | 2010-05-10 09:10:20 | Difficulty | Tim |
101477 | 2010-05-10 09:10:30 | change | John |
101477 | 2010-05-10 09:10:40 | breaking | Maggie | Tim
101477 | 2010-05-10 09:10:50 | Difficulty | Rick |
222222 | 2010-05-10 09:10:30 | change | Lewis |
222222 | 2010-05-11 09:10:40 | breaking | Maggie |
222222 | 2010-05-11 09:10:50 | Difficulty | Tim |
222222 | 2010-05-12 09:10:40 | Difficulty | Maggie |
222222 | 2010-05-13 09:10:40 | breaking | Albert | Maggie
Can you tell me how I can make?
I tried many ways but no return to what I'm looking for.
Thanks in advance.
Published by: user8910765 on June 5, 2010 13:51
Published by: user8910765 on June 5, 2010 14:00Hello
That's what you asked for in Oracle 10:
SELECT a.* , CASE WHEN action = 'break' THEN LAST_VALUE ( CASE WHEN action = 'fix' THEN author END IGNORE NULLS ) OVER ( PARTITION BY id ORDER BY tmstmp ) END AS lastfixby FROM actionhistory a ORDER BY id , tmstmp ;
Like all of the built-in functions, LAST_VALUE is documented in the manual of the SQL language:
http://download.Oracle.com/docs/CD/B19306_01/server.102/b14200/functions073.htm#sthref1508user8910765 wrote:
... just in case where it might be useful, one of the queries I've tried myself a left subquery joined that Oracle has no right ("a column may be outside not attached to a subquery').Much more, it would help if you posted the request.
It looks like you were using the old outer join notation (+). You can get the desired results by using an outer join with ANSI rating, but I think it would be more complicated and slower than with a LAST_VALUE. -
How to obtain the page to an XML element?
Hi all
I am fairly new to InDesign scripting (and scripts in general) and have lots of fun :-)
I have an InDesign document containing several frames (texts, graphics, etc.) and I tagged using the InDesign tags window.
After much struggle, I managed to get the name of the XML element tag first in my document using this simple code:
app.activeDocument.xmlElements[0].xmlElements[0].markupTag.name
I know that it worked because I got the right answer in the Javascript console. (By the way, can someone explain to me why I write xmlElements [0] twice?) And what is the difference between xmlElements and xmlItems? Any help is appreciated).
Then I'll probably use a loop for for each markupTag of each xmlElement. But I have a lot of trouble to obtain the page associated xmlElement :-/
After a lot of searching on Google, I came across this article which is supposed to answer my question exactly. I tried to understand this code, copy and paste in ExtendScript, but I must admit it's a bit too complex for me...
Can someone tell me how to get a graphic or a text linked to my XML tags block? Any help is greatly appreciated!
Nevermind, I found an easier way to achieve what I was trying to do. Actually, I wanted to be able to handle different images in my document, so why I wanted to use the XML markup.
For those of you who have the same problem, who knows from InDesign CS5, there is an itemByName method that allows you to select an image by its name in the layers panel. So much easier to use :-)
Thread closed!
-
How to bind the form to an XML element with a specific attrib/value?
Is it possible to link a form in Designer to an XML element using an attribute as a criterion value? This is a very basic construction of XPath and I can't believe that the form designer cannot do this. For example:
< library >
< book lang = "fr" >
Harry Potter < title > < /title >
< price > 29.99 < / price >
< / book >< book lang = "MS" >
< title > Learning XML < /title >
< price > 39.95 < / price >
< / book >< / book >
I would bind only the knot book with an attribute lang of "eng".
[The simple xpath reference would be: bookstore/book[@lang='eng']
Thanks for any help that anyone can provide. I am new to LiveCycle Designer
Jordon
You must use the below expression in data binding, property to get the title of the book whose language is English
.book $. (lang.value == "eng") .title
Thank you
Srini
-
How to get the ripple working, config.xml is not found
Here a load of resources for getting started, but I just can't get anything to work as stated in the documentation, or the youtube video shows.
I have various things installed, NodeJS, JVM, BlackBerry WebWorks 2.0.0.71, ripple in Chrome.
To begin with when you use 'create cordova' layer of the project is different, cordova 3.4.0 I get:
hooks /...
mergers /...
config. XML
www/js /...
www/img /...
www/css /...
www/index.html
But information to addresses such as https://developer.blackberry.com/bbos/html5/documentation/creating_hello_world.html don't show this provision.
I'm supprised when I open the config.xml file in Chrome that it does not detect the XML XSD and ripple offers to launch itself. If I navigate to file:///C:/Users/Username/RippleSites/myproject/ www/index.html can activate ripple but she complains the file config.xml in lack. Services of ripple Start' provides no clue as to any error and no TCP server listening on port 9910.
I guess BB10 doesn't work with a specific version of cordova, which uses a different type of layout of project that one 3.4.x uses. How can I fix the environment to use the correct versions and also automatically prevent the upgrade within this environment? Because I want to obviously NPM allows management version of the future module updates.
How C:\Users\Username\WebWorks Project\project interacts with the ripple need to use a specific home project directory as well?
See the Option #1 here for more information about enabling access to the local files for Chrome/ripple:
http://supportforums.BlackBerry.com/T5/Web-and-WebWorks-development/solution-ripple-launch-is-INTERR...That being said, the that training has been designed to be an emulator for the WebWorks 1.0 SDK, it relies on the features that have changed in WebWorks 2.0. For example, we leverage is no longer webworks.js, but cordova.js and webworksready changed to deviceready. In the end, there may be still some differences in the APIs, if efforts have been made to minimize any impact as he.
BlackBerry 10 works with Cordova 3.1.0 and above (it may have been a few versions ago, but I don't remember exactly). Stay up to date with Cordova and use the latest version through the Museum is my personal recommendation.
Note that if you use Cordova, you also need to install the NDK BlackBerry properly configure your environment variables.
Note that the link to the above documentation referred BBOS, which is the platform of the inheritance (BBOS 5, 6, 7). BlackBerry 10 documentation can be found here:
http://developer.BlackBerry.com/HTML5/documentation/V2_0/The www folder is root of your project that will contain all the files of HTML5. The other files are related to Cordoba and used for packing and manage your application is built.
-
How to get the number of a xml file in flash?
Hello
It comes to my XML file
<? XML version = "1.0"? >
< ArrayHolder >
< level1 > '1', '1', '1' < / level1 >
< level2 > 2,2,1,2,2 < / level2 >
< level3 > 1,3,3,3,1 < / level3 >
< / ArrayHolder >
I want to store level1 not in 'levelArray '.
Thank you
JaxNa
you always have a quote but once it is fixed, divide each value of the node on the commas and then loop in the table pouring each element to a number.
-
How to get the previous week from Monday to Sunday from sysdate
for example, sysdate is 15-SEP-07 We must retrieve the data from SEPT. 01.-15-06 - SEP - 2015, although 31 August 15 is Monday our application must ignore since the current month is September
SQL> with t 2 as 3 ( 4 select to_date('07-SEP-15', 'dd-mon-rr') my_sysdate 5 from dual 6 ) 7 select greatest(trunc(my_sysdate, 'iw') - 7, trunc(my_sysdate, 'month')) start_date 8 , trunc(my_sysdate, 'iw') - 1 end_date 9 from t; START_DAT END_DATE --------- --------- 01-SEP-15 06-SEP-15
-
Get the first instance of XML elements
Hi all
My XML tag looks like this:
< Xref RID = Ref "id001' type = 'Test' >
< Xref RID = ref "id002' type = 'Test' >
< Xref RID = ref "id003' type = 'Test' >
< Xref RID = ref 'id004' type = 'Test' >
Code:
var root = app.activeDocument.xmlElements [0];
(var xrefRid = root.evaluateXPathExpression('//xref[@rid]');
(var xrefType = root.evaluateXPathExpression('//xref[@ref-type]');
for (i = 0; i < xrefRid.length; i ++)
{
var refTypeValue is xrefRid [j].xmlAttributes.itemByName ("ref-type") .value;.
var ridValue is xrefType [j].xmlAttributes.itemByName ("rid") .value;.
If (refTypeValue is "Test")
{
Alert (ridValue);
}
}
In my multiple number same document 'RID' is here, but I want the first occurrence of the xref tag.
By example, if < Xref RID = Ref "id001' type = 'Test' > occur on different pages of a book, but I need the first occurrence of the elements.
Hope someone can help me...
Vandy
If your structure is constructed in the same manner as above , XPath works very well:
_root var = app.activeDocument.xmlElements.firstItem ();
var _firstXrefID001andID002 = _root.evaluateXPathExpression ("//p [position () = 1] / xref [@ RID ="id001"] |") [/ / p [position () = 2] / xre f[@rid='id002'] ");"
App.Select (_firstXrefID001andID002);
If further stations of
are possible, for example
1 Title Example text sample text sample text sample text sample text sample text Sample text sample text sample
sample text sample text sample Sample text sample text sample
sample text sample text sample Sample text sample text sample
sample text sample text sample Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text Example of example text text
Sample text sample text Sample Text sample text You can try these XPathsExpressions and take the first element of tables resulting:
_root var = app.activeDocument.xmlElements.firstItem ();
[var _firstXrefID001 = _root.evaluateXPathExpression("//p/xref[@rid='id001']"); "
App.Select(_firstXrefID001[0]);
[var _firstXrefID002 = _root.evaluateXPathExpression("//p/xref[@rid='id002']"); "
App.Select(_firstXrefID002[0]);
Roland
-
How to get the value of a literal XML node content in BPEL 2.0?
Hello!
I have a problem creating A Expression in the distribution of the XML literal one activity, I would like to help me...
Well, I have the same activity in the 1.0 version of BPEL and is now different is BPEL 2.0,.
I have a Web Service < WSEjecutaComandos > when having a function of controls remote that connects,
Entries of my Web Service: "int numEquipo, String [] comandos, int numCta, int publicar, int, String date version"
The second argument is an array of string type...
Now in my BPEL process, I do is the following assignment:
************************************************************
< assign the name = "AssignCreaPath" >
< copy >
< from >
< literal >
" < fnCRexecElement xmlns =" http://Servicios/ ">
< numEquipo > 2 < / numEquipo >
< comandos >mkdir etl/entries/mmkis /< / comandos >
< numCuenta > 1 < / numCuenta >
< publicar > 0 < / publicar >
< / fnCRexecElement >
< / literal >
< / from >
< to > $InvokeClear_fnCRexec_InputVariable.parameters < /pour >
< / copy >
< copy >
(< a >concat(ora:getContentAsString($InvokeClear_fnCRexec_InputVariable.parameters/comandos),$inputVariable.payload/client:fecha)< / from >
< to >$InvokeClear_fnCRexec_InputVariable.parameters/comandos< /pour >
< / copy >
< copy >
< a > $InvokeVersion_fnGetVersionProcesoByFecha_OutputVariable.parameters/version < / from >
< to > $InvokeClear_fnCRexec_InputVariable.parameters/version < /pour >
< / copy >
< copy >
< a > $inputVariable.payload / client: date < / from >
< to > $InvokeClear_fnCRexec_InputVariable.parameters/date < /pour >
< / copy >
< / assign >
***************************************************
Well the conflict I have is as follows,
previously defined an entitlement with the XML Fragment copied on the payload to the Web Service (WSEjecutaComandos), input variable
and the XML code is copied to each of the variables,
Then him concatenating input values (I noted in red) < comandos > with the value of 'farm' (String), and once again copy Variable < comandos > and has not had any problems
but now with the new BPEL 2.0, I do the same thing now using literal XML (this good!) but the option to concatenate (that I've noticed in red) and copied to the same variable ( I noticed blue ), I mark the following error message:
I should know, I am doing wrong, or you need to to XPath function as the value that they already have the variable < comandos > will concatenate date,
and is the final value of my entry, my Web Service.
must be defined as table of values of type < comandos [i] >
define the following activities before $InvokeClear_fnCRexec_InputVariable.parameters/comandos [1],
but it seems that this BPEL 2.0 does not respect me in the form of hooks index.
Thank you...
See you soon,.
I found the solution to get the value of an xml element and it concatenated with another variable within a beneficiary.
is:
ORA: getNodeValue (ora:getChildElement($InvokeCreaPath_fnCRexec_InputVariable.parameters,2))
first get the desire here in my tree xml element is position 2 < comandos=""> and then get the value of this node.
See you soon,.
-
How to get the name of the previous tag of an xml in java
Hai
I need to get the name of the previous tag from an xml in java.
I got the current tagname, I need to get the previous tagname attribute
NodeList parentactionList = lParentRule.getElementsByTagName)
"parentactiondetails" );
I use this way to get the the current tag name, I need to get the name of the previous tag IE... before 'parentactiondetails'
for the sample
< / parentruledetails >
< / Parentrule >
< / SingleParentRule >
< parentactiondetails ACTION_FLAG = "RulePass" PARENT_RULE_CODE = "PR626" / >
< ParentCompliance >I have xml like this I'm getting the "parentactiondetails"... now I need to get the name of the previous tag < / SingleParentRule > Java
Can someone help me,
The following code retrieves the tag replacing "parentactiondetails."
NodeList children = doc.getElementsByTagName("parentactiondetails"); for (int i = 1; i < children.getLength(); i = i + 2) { // Alternate child (
tag). Node nd = children.item(i); // Print node name System.out.println(nd.getNodeName()); //Get attributes NamedNodeMap attributes = nd.getAttributes(); for (int j = 0; j < attributes.getLength(); j++) { Node attr = attributes.item(j); //Print the attribute key and value System.out.println("\t" + attr.getNodeName() + " -- " + attr.getNodeValue()); } }
Maybe you are looking for
-
I can remove sp 1 after you download sp 2 to reclaim the disk space
can I remove SP1 after you download SP 2 to recover the disk space
-
G60-120us: triggered and crashed (short-circuit)?
I really made a simple mistake, the screen was not reciving power so I unplugged my power cord and I forgot to take my battery or powerdown before starting to work on my laptop. The card mother screen plugin (main cord) was not entirely bluged in one
-
Between the window update and Norton 360 first Edition.
Since March 29, 2011 what a life Windows updates KB2505189 and KB2524375 were auto installed on my Windows Vista laptop, my Norton 360 first Edition will not perform live updates. Is there a solution to this problem?
-
Background picture not visible in its entirety, WHY?
Hello I want to add an image to the background of my screen. Here's how I did: class MyScreen extends MainScreen { public MyScreen() { XManager manager = new XManager(background); add(manager); manager.add(gfm); manager.add(closeBtn); } class XManage
-
Blocked product key - code 0xC004C003 error
original title: I have a 0xC004C003 error code how can I fix this? IM updates install for my Windows 7 Ultimate, and then receive a 0xC004C003 error tell me my product key is blocked by the server.