retrieve SQL data

I need to display data based on the column name.  The name is captured from the URL parameter and transmitted to Flash with Javascript.

Recover it with Flash:

varMedia var = ExternalInterface.call("saveglobalscore",score) ("getParameter1");

Then, I use the following function to retrieve and display the data:

function displayRatingOnSQL (): void

{

var myTextLoader:URLLoader = new URLLoader();

myTextLoader.dataFormat = pouvez;

myTextLoader.addEventListener (Event.COMPLETE, onLoaded);

function onLoaded(e:Event):void

{

var tAverage = (e.target.data.Average);

var tTotalVotes = (e.target.data.TotalVotes);

var tTotalRate1 = (e.target.data.star1);

var tTotalRate2 = (e.target.data.star2);

var tTotalRate3 = (e.target.data.star3);

var tTotalRate4 = (e.target.data.star4);

var tTotalRate5 = (e.target.data.star5);

var temp = tTotalRate5 + "\n" + tTotalRate4 + "\n" + tTotalRate3 + "\n" + tTotalRate2 + "\n" + tTotalRate1;

totalForEachStar.text = temp;

tAve.text = tAverage;

totalVotes.text = "(" + tTotalVotes + "par»;)"

}

var extraString = Math.Random ();

myTextLoader.load (new URLRequest ("http://dntin1web01/tpas/SQL/GniePageRatePageRead.asp?qs=" + extraString));

}

I the following to collect the name of the column in the ASP page, extract data:

Dim tPageMedia

tPageMedia = Request.Form ("varMedia")


Then I try to use the following to retrieve:

SQL = SQL & "WHERE ([PageName] =" & "'" & tPageMedia & "" "" ")". "


I have nothing. It works if I put a code name hard replacing the dynamics.


How can I switch the varMedia to the ASP page? The Javascript variable is var1.

I was probably too tired, but I solved the problem by adding the value of the variable to the parameter of the URL to call ASP. It's working now. Thank you!

Tags: Coding Corner

Similar Questions

  • ORA-01124: cannot retrieve the data file 1 - file is in use or recovery

    I'm trying to recover the database in waiting, but it gives the error below.

    ORA-00283: cool cancelled due to errors
    ORA-01124: cannot retrieve the data file 1 - file is in use or recovery, the recovery is already said
    ORA-01110: data file 1: ' I:\ORACLE\QAS\SAPDATA1\SYSTEM_1\SYSTEM. DATA1'

    When I checked in the alert log recovery is not started. and later I hae given ' alter database recover Cancel "and the command to meet with the threshold.

    "media recovery has not started.

    It seems that the recovery was stuck between the two.
    Please advise me how to kill the recovery session that is stuck. because I don't want to bounce the database pending.

    Thanks in advance.

    Dataguard and MRP, you run a script before.

    In a standby scripted, a session to RETRIEVE the DATABASE would an UNTIL clause (SEQUENCE up to THAT most likely). At the end of the recovery at this point (SEQUENCE #), he left and stop at the database.

    In addition, the script is such that when a RECOVERY session is active, another session is not authorized to start. It can loop in pending state or go out and do it again the next scheduled interval.

    Apparently your startup script is not strong enough to prevent another session of RECOVERY to start even though the first is active (or it doesn't have a good up to THAT clause and stop, exit, closing stocks)

    What you have is a custom implementation of a database of pending. Without all the details of the script, the 'blocking' between sessions (to avoid a second RECOVER start when one is already running) etc... We can't really do much to help you.
    Your scripts must be standing with status information. It should be possible for you to discover the 'other' sqlplus session which emanates a DATABASE to RECOVER, but not yet out (p. ex... How about a simple "ps - ef |") grep sql' and ' ps - ef | combination of grep ora"?)

    Hemant K Collette

    Published by: Hemant K Collette on May 29, 2013 17:47

  • Cannot retrieve the data by binary storage by default for XML 11 g

    Oracle 11.2

    All,

    As someone mentioned in another post, I got I should use binary XMLType CLOB rather than 11g because it is more efficient. When I create the XMLType column as binary I can't retrieve the value of the column, but when I use CLOB I am able to extract data on.

    -Create table with XMLTYPE column.  Since it is 11.2 storage of the column is automatically binary
    CREATE THE TABLE HR. XMLTABLESTORE (key_id VARCHAR2 (10) PRIMARY KEY, xmlloaddate date, xml_column XMLTYPE);

    -Insert the XML into the XML column
    INSERT INTO HUMAN RESOURCES. VALUES XMLTABLESTORE (HR. XMLSEQUENCE. NEXTVAL, SYSDATE, XMLType (bfilename ('XMLDIRX', 'PROD_20110725_211550427_220b.xml'),
    nls_charset_id ('AL32UTF8'))); COMMIT;

    -When I do a select I see full XML in the xml_column column
    SELECT * FROM HR. XMLTABLESTORE

    -When I run the following query I get the following:
    SELECT extract (xml_column, ' / / MapItem/@ProductNum') ProductNum OF HR. XMLTABLESTORE

    ProductNum
    -------------
    XMLType

    -When I run the following query on the @, I get the following:
    SELECT extract (xml_column, ' / / MapItem/ProductNum ') ProductNum OF HR. XMLTABLESTORE

    ProductNum
    -------------
    Null value

    When I run the same SELECT query retrieves (xml_column, ' / / MapItem/@ProductNum') ProductNum OF HR. XMLTABLESTORE and the table is created by CLOB, I get out the expected value of the XML file.

    How can I get the query to retrieve the data through a binary file?

    I appreciate any help in advance.

    Thank you
    Shawn

    Published by: 886184 on Sep 20, 2011 15:42

    Probably a problem with your client tool.

    It works for me:

    SQL*Plus: Release 11.2.0.2.0 Beta on Mer. Sept. 21 19:39:55 2011
    
    Copyright (c) 1982, 2010, Oracle.  All rights reserved.
    
    Connected to:
    Oracle Database 11g Express Edition Release 11.2.0.2.0 - Beta
    
    SQL> CREATE TABLE xmltablestore (
      2    key_id VARCHAR2(10) PRIMARY KEY
      3  , xmlloaddate DATE
      4  , xml_column XMLTYPE
      5  );
    
    Table created.
    
    SQL> INSERT INTO xmltablestore
      2  VALUES ('1', sysdate, XMLType(bfilename('TEST_DIR', 'PROD_20110725_211550427_220b.xml'),nls_charset_id('AL32UTF8')))
      3  ;
    
    1 row created.
    
    SQL> commit;
    
    Commit complete.
    
    SQL> SELECT extract(xml_column, '//MapItem/@ProductNum') ProductNum
      2  FROM xmltablestore
      3  ;
    
    PRODUCTNUM
    --------------------------------------------------------------------------------
    63481062975
    
    SQL> SELECT extractValue(xml_column, '//MapItem/@ProductNum') ProductNum
      2  FROM xmltablestore
      3  ;
    
    PRODUCTNUM
    --------------------------------------------------------------------------------
    63481062975
    
    SQL> SELECT xmlcast(
      2          xmlquery('/Entries/Category/MapItem/@ProductNum'
      3           passing t.xml_column
      4           returning content
      5          )
      6          as number
      7         ) ProductNum
      8  FROM xmltablestore t
      9  ;
    
    PRODUCTNUM
    ----------
    6,3481E+10
    
    SQL> SELECT xmlcast(
      2          xmlquery('/Entries/Category/MapItem/@ProductNum'
      3           passing t.xml_column
      4           returning content
      5          )
      6          as varchar2(30)
      7         ) ProductNum
      8  FROM xmltablestore t
      9  ;
    
    PRODUCTNUM
    ------------------------------
    63481062975
    

    BTW, extract and extractvalue functions are deprecated in version 11.2.
    Oracle now recommends using XMLCast/XMLQuery.

  • Retrieve a data file from a backup on another server

    Hi all

    I usually take backup hot data files to a different like that server because I don't have enough space in the same server. I have

    SQL > alter tablespace XXXX begin backup;
    SCP/bu1/oradaTA/XXXXX/XXXXX host [email protected]: / db1dw/oradata/backup/dec2010/XXXX
    alter tablespace end OPS backup;

    If I want to recover the datafile can I normally do the drop offline from the data file and copy the backup data file that is located in differnet thorugh scp server and check the online data file? and the database is in archivelog mode, but I dislike abt log files. I just need to recover the data file as the last backup.
    or do we have to use all the controls recover datafile? If need to use everything recover datafile command go where it will recover the data file?

    I have not any backup or restore script, I just manually PCs from data files.

    Help please, thanks in advance...

    It is a ' user backups managed by "in the terminology of the Oracle.
    The database does not care how you copy (backup or restore) the data file from a backup location. So, you can use scp to copy the backup to the backup file.
    HOWEVER , you can recover only a datafile to the single point of the backup. Given that the rest of the database (i.e. all the other data files) have advanced further, you must RETRIEVE the DATA file and apply all ArchiveLogs since this backup of data file point to the current point (i.e. recovery would be until it again online that would apply automatically).
    Therefore, if you have had the "transactions" (e.g. deletions) against this tablespace, they will be replayed.

    Hemant K Collette

  • Numbers. retrieve different data depending on today's date

    I made a dashboard on numbers 4.0 on MacBook Pro using macOS 10.12.

    I need to display some data from the month, so I need to change every month (extraction of data from a different cell depending on the month). Should what formula/s I use?

    In the column, there is the date of the day, with a total at the end of the month.

    In the lines, I have different categories.

    The dashboard to view the totals for the month in a different tab.

    "I need something like: today check month and retrieves the data of total monthName ' (if necessary)

    Thank you for your help

    Hi sanz,.

    OS X 10.11.5, ' 09 numbers (numbers 4.3, but this willingness to work 3 numbers).

    Not sure about 4 numbers!

    Add another column (E) in table 1 (you can hide this column later).

    Formula in table 1 E2 (and fill down)

    = MONTHNAME (MONTH (A2))

    In the second table.

    Formula in A1 = MONTHNAME (MONTH (TODAY ()))

    Formula in A2 = "sum"& A1

    Formula in B2 (fill right) = SUMIF (table 1: $E, $A$ 1, table 1: B).

    Kind regards

    Ian.

  • BlackBerry Z3, I lost all my data on my SD storage card, please help me to retrieve the data.

    Dear Sir.

    I lost all my data on my SD storage card, please help me to retrieve the data. I have a Z3, just bought only a week before, I removed the card with the phone off and then give the card again and noticed that I lost all the data. Please help

    Try restarting your phone. Sometimes it shows data that brought them "disappeared". To do this, hold down your power button for about 15 seconds, until you see BlackBerry on your screen. Do not release the button until you see that without taking account of any other thing you see before that.

    Try this and post back with your results.

  • HFM SmartView Bug? HsGetValue retrieves the data for non-existent entity node.

    Hi guys,.

    We are facing a problem of SmartView 11.1.2.5.520 in combination with HFM 11.1.2.4.103. I would like to know if you can reproduce it.

    Assume it's our hierarchy of entity:

    Parent1 (EUR)

    Child1 (USD)

    Child2

    Child3

    Parent2 (GBP)

    Child4

    Children5

    We want to extract the data via "HsGetValue" for in < currency Parent > Child1, so need to entity to return node information: "Parent1.Child1." Works very well.

    Strangely enough, that's good, that the Parent2.Child1 data retrieves, although node do not exist!

    If you try it with ad hoc, an error message appears saying "Member does not exist", which is correct.

    Can someone check the BUG? If so, I'll open a SR.

    Thanks in advance!

    Carmonte

    Thank you guys! You responses helped me to understand that he is not really a bug.

    • HsGetValue retrieves a nonexistent node of to data from first available parent in the hierarchy.
    • Top of to HsGetValue retrieves no data. What is good.

    Knowing that, I can live with that.

    Thank you!

    Carmonte

  • How to join two tables to retrieve the data from the columns in table two. Tables have primary and foreign key relationships

    Hello

    I want to join the two tables to retrieve the data from the columns of the two table passing parameters to the join query. Tables have primary and foreign key relationships

    Details of the table

    Alert-1 - AlertCode (FK), AlerID (PK)

    2 AlertCode-AlertDefinition-(PK)

    Help, please


    ----------

    Hi Vincent,.

    I think that you have not worked on adf 12.1.3.  In adf 12.1.3 you don't have to explicitly create the association. When you create the EO to your table, Association xxxxFkAssoc, will be created by ADF12.1.3 for you automatically. Please try this and do not answer anything... You can also follow the links below. I solved the problem by using the following link

    Oracle ADF Guide step by step - Oracle ADF tutorial: creating a relationship of the master / detail using Oracle ADF

    ---

  • Need to retrieve the data for the current date.

    Hello

    I have a table which then retrieves information when using this command.

    Select ta_acct, shift, created_on track_alerts;

    Technicolor A 24 March 14

    Technicolor A 24 March 14

    Technicolor A 24 March 14

    Technicolor A 24 March 14

    Manitoba telecom a 24 March 14 system

    Technicolor A 24 March 14

    I used this statement to retrieve the data for the given date.

    Select ta_acct, shift, created_on track_alerts where created_on = 24 March 14 ';

    Its not data recovery.

    Need help.

    Kind regards

    Prasad K T,.

    984002170

    Prasad K T wrote:

    Yes the created data type is date.

    CREATED_ON DATE

    Partha thanks it works now.

    Select ta_acct, shift, created_on in track_alerts where to move is: Shift and TRUNC (created_on) = TO_DATE('24-MAR-2014','DD-MON-YYYY');

    Still, I made a small change to my querry.

    Select ta_acct, shift, created_on track_alerts where to move is: shft and TRUNC (created_on) = TO_DATE (select double sysdate,'MON-DD-YYYY "");

    For this statement, it does not work.

    of course not...

    first: sysdate returns a date so no need of conversion here

    and

    second SYSDATE includes time, so your application should look like this:

    Select ta_acct, shift, created_on in track_alerts where to move is: Shift and TRUNC (created_on) = trunc (sysdate)

    or

    Select ta_acct, shift, created_on in track_alerts where to move is: shft and created_on > = trunc (sysdate) and created_on<>

    HTH

  • Does not not for java.sql.Date sort field

    Hi Experts ADF,

    JDev version 11.1.1.7.0

    I use a POJO based datacontrol, who is dragged like a table on page JSFF. One of the field is a java.sql.Date data type in POJO.

    So for example in the table 4 values are there to this date field as

    2.2.2014

    3.2.2014

    31.1.2014

    to 31.12.2013

    So while sorting in ascending order, it should come as below

    to 31.12.2013

    31.1.2014

    2.2.2014

    3.2.2014

    And vice-versa.

    But if I click on sort it sorts by the first 2 digits only, and I'm under results for sorting (ascending)

    2.2.2014

    3.2.2014

    31.1.2014

    to 31.12.2013

    Please suggest on this. Thanks in advance.

    Thank you

    Animesh

    Hi This sorting has been solved by changing of java.util.Date.

    Yes his watch to the client as an outputText inside the table. Sorting option is there for af:column.

    Thank you

    Roy

  • In general, is it better to use java.sql.Date and java.sql.Timestamp instead of oracle.jbo.domain.Date?

    Hello world

    During playback of Oracle ADF Real World Developer's Guide, I noticed the dates match occurring in JDeveloper is different from what is the list in the book. JDeveloper is failing to oracle.jbo.domain.Date, but according to the book:

    DATEjava.sql.DateDATE type is mapped to java.sql.Date if the column in the table is a no time didn't need information zone.
    DATEjava.sql.TimestampDATE type is mapped to java.sql.Timestamp if the column in the table has a component "time" and that the client needs to zone information.
    TIMESTAMPjava.sql.TimestampThe TIMESTAMP type is mapped to java.sql.Timestamp if nanosecond precision is used in the database.

    In general, is it better to use java.sql.Date and java.sql.Timestamp instead of oracle.jbo.domain.Date? Using java.sql.Date and java.sql.Timestamp could save me some headaches conversion date. And, is there a place in JDeveloper to display these maps? I looked around and didn't see anything.

    Thank you.

    James

    User, what version of jdev we are talking about?

    In GR 11, 1 material versions db types date and timestamp are mapped to types of domain data that represents a wrapper for the native data types. The reason was that the framework can work with the domain types regardless of the underlying data type.

    Since Oracle 11 GR 2 maps the types DB to java types (default selection, you can change it when you create a model project, you can set the Data Type Mapping). Once the pilot has business components define you cannot change this setting it would break existing components such as eo or vo.

    So if you are working wit 11 GR 1 subject, you must use the domain types, if you work with GR 11, 2 or 12 c, you can use the domain types, but it is recommended to use the java type mapping.

    Timo

  • The maximum size of the model in SQL Data Modeler?

    Hello

    The number of objects is the maximum value that can be used in a model in SQL data maker. I reverse engineered a scheme (see previous posts - thank you to all that helped) which contains 1000 + tables (a candidate for remanufacturing if ever I saw a!) but the Data Modeler is struggling to display them and performs very slowly. I can pull the same schema in the Oracle Designer and that works well, as ERwin-t - y at - it something I can do to improve the performance of the Data Modeler?

    Or people would recommend cutting the model into smaller pieces, which will be a little difficult because it's a bit of a rat's nest.

    John

    Hi John,.

    You can try to fix the memory usage - Re: problem of memory with large model

    And you may have better performance if divide you large diagram in subviews.

    Philippe

  • ADFDI-05577: could not retrieve the data table on the server.

    Dear all,

    My use case is, when I opened my excellent work book, I have this error message is out ' ADFDI-05577: could not retrieve the data table on the server line "and when I click on the button 'OK' of the error message I can recover all the data on the server. Please help me how to solve this error?


    Concerning
    KT

    Thanks much Sireesha Pinninti, John Stegeman, Arun.

    Yes, my problem is of subquery. I found a solution from this site.
    http://www.DBA-Oracle.com/t_ora_01427_single_row_subquery_returns_more_than_one_row.htm,
    http://srinisboulevard.blogspot.com/2010/04/ora-01427-single-row-subquery-returns.html
    http://StackOverflow.com/questions/3804850/erroneous-ora-01427-single-row-subquery-returns-more-than-one-row / / the answer is the last line

    Before change (error subquery)

    CheckingEO.BO,
    (SELECT ntr_no FROM test
    WHERE cs_no = CheckingEO.CS_NO) NTR_NO
    To archive the CheckingEO

    Edit it like this

    (SELECT ntr_no FROM test
    WHERE cs_no = CheckingEO.CS_NO and Rownum = 1) NTR_NO
    To archive the CheckingEO

    Concerning
    KT

    Published by: KT on 23 May 2012 15:35

    Published by: KT on 23 May 2012 15:48

  • Problem with the two EA DEVELOPER SQL DATA MODELING 3.0.0.665 and 3.1

    I created a model of very large data using SQL Developer data 3.0.0.665 and 3.1 EA maker. Its having a lot of check constraints. Whenever I am the design of the fence and the DOF and reopening export to import the DDL file failure to import completely check constraints. It is important to check constraints, but without any range of values inside. Its very frustrating because whenever you open import ddl, you must manually add again all the details of data check range constraint.

    OS: Windows XP.
    Check in the two EA Developer SQL Data Modeler 3.0.0.665 and 3.1

    -------------------------------------------
    Here are the contents of the .dmd file.
    -------------------------------------------
    * <? XML version = "1.0" encoding = "UTF - 8"? > *.
    * < OSDM_Design class = "oracle.dbtools.crest.model.design.Design" name = 'Admin_Panel' id = "9BE18B0A-6C67-2E5B-00DE-BD8312189ECB" version = "3.41" > * "
    * < createdBy > administrator < / createdBy > *.
    * < Createduserid > 2011-10-17 08:32:18 UTC < / Createduserid > *.
    * < Admin_Panel ownerDesignName > < / ownerDesignName > *.
    * < false capitalNames > < / capitalNames > *.
    * < designId > 9BE18B0A-6C67-2E5B-00DE-BD8312189ECB < / designId > *.
    * < / OSDM_Design > *.

    -------------------------------------------------------------------------------
    An example how the check constraints to get dirty.
    -------------------------------------------------------------------------------
    Initial check constraint is as below:
    ======================
    ALTER TABLE test_table
    ADD CONSTRAINT Active_Flag_ck
    CHECK (Active_Flag IN ('A', 'I'))
    *;*

    Below how it occurs once I have imported the ddl and re-export:
    ============================================
    ALTER TABLE test_table
    ADD CONSTRAINT Active_Flag_ck
    (CHECK)
    *;*

    I'm in trouble as I already in the middle of the my development using SQL Developer Data Modeler.

    Please help me soon.

    Jean

    Hi John,.

    Every time I'm fence design and export the ddl and reopening through the import of the DDL file

    Why are you doing this? Once the DDL file is imported and then save the drawing and open simply saved design, no need to generate the DDL and import it every time that you start Modeler data.
    On the list of values - forced as this CHECK (Active_Flag IN ('A', 'I')) are imported as constraint check plain and not as a list of values.
    There are the more specific elements import of check constraint - they are defined as type database constraint that you select during the import. Accordingly if you import your DOF as Oracle 10 g DDL, then you will get forced correct check in DDL generated for Oracle 10 g and Oracle 11 g. Constraint of evil will be generated for Oracle 9i. You can move the constraint for Oracle 9i (in the check constraint dialog box) or generic if it can be treated as such constraint.

    I logged for DOF bad bug.

    Philippe

  • java.lang.ClassCastException:String cannot be cast to java.sql.Date

    I have a date component. MinValue named Id2 and the following code is to run a class cast exception indicating that the string value cannot be cast to a date sql

    java.sql.Date dateNeeded = (java.sql.Date) this.getId2 () .getValue ();

    can someone help me to overcome this problem.

    Thanks and greetings
    Janak

    Published by: new_to_ORACLE on February 18, 2011 16:56

    Published by: new_to_ORACLE on February 18, 2011 16:58

    the Date attribute is of type object oracle.jbo.domain.Date
    so, first try to cast to oracle.jbo.domain.Date. then to java.sql.Date object

    If you need to cast to another Date object, see this site:
    http://www.ecotronics.ch/webdesign/javadate.htm

    Published by: M.Jabr on February 19, 2011 11:53

Maybe you are looking for