Query for extracting the data in tags

I have data in table like
col1 col2
1 Appli<resourceId>Page_Attorny</resourceId>
How I will get output of query as
Page_Attorny
Plz help.
Thanx in advance.

Hi,
I hope you are looking some thing like :
SQL>create table XMLTable (col1 number, col2 XMLType);
Table created.
SQL>insert into XMLTable values (1,XMLType('<resourceId>Page_Attorny</resourceId>'));
1 row created.
SQL>SELECT col1, extractValue(col2,'resourceId') FROM XMLTable;
      COL1
EXTRACTVALUE(COL2,'RESOURCEID')
         1
Page_Attorny
1 row selected.
SQL>Regards

Similar Messages

  • Query taking long time for EXTRACTING the data more than 24 hours

    Hi ,
    Query taking long time for EXTRACTING the data more than 24 hours please find the query and explain plan details below even indexes avilable on table's goe's to FULL TABLE SCAN. please suggest me.......
    SQL> explain plan for select a.account_id,round(a.account_balance,2) account_balance,
    2 nvl(ah.invoice_id,ah.adjustment_id) transaction_id,
    to_char(ah.effective_start_date,'DD-MON-YYYY') transaction_date,
    to_char(nvl(i.payment_due_date,
    to_date('30-12-9999','dd-mm-yyyy')),'DD-MON-YYYY')
    due_date, ah.current_balance-ah.previous_balance amount,
    decode(ah.invoice_id,null,'A','I') transaction_type
    3 4 5 6 7 8 from account a,account_history ah,invoice i_+
    where a.account_id=ah.account_id
    and a.account_type_id=1000002
    and round(a.account_balance,2) > 0
    and (ah.invoice_id is not null or ah.adjustment_id is not null)
    and ah.CURRENT_BALANCE > ah.previous_balance
    and ah.invoice_id=i.invoice_id(+)
    AND a.account_balance > 0
    order by a.account_id,ah.effective_start_date desc; 9 10 11 12 13 14 15 16
    Explained.
    SQL> select * from table(dbms_xplan.display);
    PLAN_TABLE_OUTPUT
    | Id | Operation | Name | Rows | Bytes |TempSpc| Cost (%CPU)|
    | 0 | SELECT STATEMENT | | 544K| 30M| | 693K (20)|
    | 1 | SORT ORDER BY | | 544K| 30M| 75M| 693K (20)|
    |* 2 | HASH JOIN | | 544K| 30M| | 689K (20)|
    |* 3 | TABLE ACCESS FULL | ACCOUNT | 20080 | 294K| | 6220 (18)|
    |* 4 | HASH JOIN OUTER | | 131M| 5532M| 5155M| 678K (20)|
    |* 5 | TABLE ACCESS FULL| ACCOUNT_HISTORY | 131M| 3646M| | 197K (25)|
    | 6 | TABLE ACCESS FULL| INVOICE | 262M| 3758M| | 306K (18)|
    Predicate Information (identified by operation id):
    2 - access("A"."ACCOUNT_ID"="AH"."ACCOUNT_ID")
    3 - filter("A"."ACCOUNT_TYPE_ID"=1000002 AND "A"."ACCOUNT_BALANCE">0 AND
    ROUND("A"."ACCOUNT_BALANCE",2)>0)
    4 - access("AH"."INVOICE_ID"="I"."INVOICE_ID"(+))
    5 - filter("AH"."CURRENT_BALANCE">"AH"."PREVIOUS_BALANCE" AND ("AH"."INVOICE_ID"
    IS NOT NULL OR "AH"."ADJUSTMENT_ID" IS NOT NULL))
    22 rows selected.
    Index Details:+_
    SQL> select INDEX_OWNER,INDEX_NAME,COLUMN_NAME,TABLE_NAME from dba_ind_columns where
    2 table_name in ('INVOICE','ACCOUNT','ACCOUNT_HISTORY') order by 4;
    INDEX_OWNER INDEX_NAME COLUMN_NAME TABLE_NAME
    OPS$SVM_SRV4 P_ACCOUNT ACCOUNT_ID ACCOUNT
    OPS$SVM_SRV4 U_ACCOUNT_NAME ACCOUNT_NAME ACCOUNT
    OPS$SVM_SRV4 U_ACCOUNT CUSTOMER_NODE_ID ACCOUNT
    OPS$SVM_SRV4 U_ACCOUNT ACCOUNT_TYPE_ID ACCOUNT
    OPS$SVM_SRV4 I_ACCOUNT_ACCOUNT_TYPE ACCOUNT_TYPE_ID ACCOUNT
    OPS$SVM_SRV4 I_ACCOUNT_INVOICE INVOICE_ID ACCOUNT
    OPS$SVM_SRV4 I_ACCOUNT_PREVIOUS_INVOICE PREVIOUS_INVOICE_ID ACCOUNT
    OPS$SVM_SRV4 U_ACCOUNT_NAME_ID ACCOUNT_NAME ACCOUNT
    OPS$SVM_SRV4 U_ACCOUNT_NAME_ID ACCOUNT_ID ACCOUNT
    OPS$SVM_SRV4 I_LAST_MODIFIED_ACCOUNT LAST_MODIFIED ACCOUNT
    OPS$SVM_SRV4 I_ACCOUNT_INVOICE_ACCOUNT INVOICE_ACCOUNT_ID ACCOUNT
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_ACCOUNT ACCOUNT_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_ACCOUNT SEQNR ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_INVOICE INVOICE_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_ADINV INVOICE_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_CIA CURRENT_BALANCE ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_CIA INVOICE_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_CIA ADJUSTMENT_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_CIA ACCOUNT_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_LMOD LAST_MODIFIED ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_ADINV ADJUSTMENT_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_PAYMENT PAYMENT_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_ADJUSTMENT ADJUSTMENT_ID ACCOUNT_HISTORY
    OPS$SVM_SRV4 I_ACCOUNT_HISTORY_APPLIED_DT APPLIED_DATE ACCOUNT_HISTORY
    OPS$SVM_SRV4 P_INVOICE INVOICE_ID INVOICE
    OPS$SVM_SRV4 U_INVOICE CUSTOMER_INVOICE_STR INVOICE
    OPS$SVM_SRV4 I_LAST_MODIFIED_INVOICE LAST_MODIFIED INVOICE
    OPS$SVM_SRV4 U_INVOICE_ACCOUNT ACCOUNT_ID INVOICE
    OPS$SVM_SRV4 U_INVOICE_ACCOUNT BILL_RUN_ID INVOICE
    OPS$SVM_SRV4 I_INVOICE_BILL_RUN BILL_RUN_ID INVOICE
    OPS$SVM_SRV4 I_INVOICE_INVOICE_TYPE INVOICE_TYPE_ID INVOICE
    OPS$SVM_SRV4 I_INVOICE_CUSTOMER_NODE CUSTOMER_NODE_ID INVOICE
    32 rows selected.
    Regards,
    Bathula
    Oracle-DBA

    I have some suggestions. But first, you realize that you have some redundant indexes, right? You have an index on account(account_name) and also account(account_name, account_id), and also account_history(invoice_id) and account_history(invoice_id, adjustment_id). No matter, I will suggest some new composite indexes.
    Also, you do not need two lines for these conditions:
    and round(a.account_balance, 2) > 0
    AND a.account_balance > 0
    You can just use: and a.account_balance >= 0.005
    So the formatted query isselect a.account_id,
           round(a.account_balance, 2) account_balance,
           nvl(ah.invoice_id, ah.adjustment_id) transaction_id,
           to_char(ah.effective_start_date, 'DD-MON-YYYY') transaction_date,
           to_char(nvl(i.payment_due_date, to_date('30-12-9999', 'dd-mm-yyyy')),
                   'DD-MON-YYYY') due_date,
           ah.current_balance - ah.previous_balance amount,
           decode(ah.invoice_id, null, 'A', 'I') transaction_type
      from account a, account_history ah, invoice i
    where a.account_id = ah.account_id
       and a.account_type_id = 1000002
       and (ah.invoice_id is not null or ah.adjustment_id is not null)
       and ah.CURRENT_BALANCE > ah.previous_balance
       and ah.invoice_id = i.invoice_id(+)
       AND a.account_balance >= .005
    order by a.account_id, ah.effective_start_date desc;You will probably want to select:
    1. From ACCOUNT first (your smaller table), for which you supply a literal on account_type_id. That should limit the accounts retrieved from ACCOUNT_HISTORY
    2. From ACCOUNT_HISTORY. We want to limit the records as much as possible on this table because of the outer join.
    3. INVOICE we want to access last because it seems to be least restricted, it is the biggest, and it has the outer join condition so it will manufacture rows to match as many rows as come back from account_history.
    Try the query above after creating the following composite indexes. The order of the columns is important:create index account_composite_i on account(account_type_id, account_balance, account_id);
    create index acct_history_comp_i on account_history(account_id, invoice_id, adjustment_id, current_balance, previous_balance, effective_start_date);
    create index invoice_composite_i on invoice(invoice_id, payment_due_date);All the columns used in the where clause will be indexed, in a logical order suited to the needs of the query. Plus each selected column is indexed as well so that we should not need to touch the tables at all to satisfy the query.
    Try the query after creating these indexes.
    A final suggestion is to try larger sort and hash area sizes and a manual workarea policy.alter session set workarea_size_policy = manual;
    alter session set sort_area_size = 2147483647;
    alter session set hash_area_size = 2147483647;

  • Query for Finding the Date History

    Hi Geeks,
    My Table looks like this
    Employee Assignment Position     Job     Grade     Start_date     End_date
    101 132 2055 Clerk C01 10-Mar-00 11-Feb-01
    101 132 2055 Clerk C02 12-Feb-01 15-Dec-01
    101 132 2056 Clerk C02 16-Dec-01 22-Jul-03
    101 132 2055 Clerk C03 23-Jul-03 31-Dec-4000 --(unassigned)
    Now I need output like
    Employee Assignment Position Start_date End_date
    101 132 2055 10-Mar-2000 15-Dec-2001
    101 132 2056 16-Dec-2001 22-Jul-2003
    101 132 2055 23-Jul-2003 31-Dec-4000 --(unassigned)
    The following important things are to be considered
    1. Rows to be grouped by position
    2. Each row much have the start date and end date of the employee position. If the employee is the same postion and different grade or job that doesnt matter. But if the employee jumps from his position (2055) to 2056 and after sometime he comes to the same position (i.e. 2055) the date history should be separate.
    I am unable to derive the logic also. I think we need to create a function for this.
    Kindly help me out.
    Thanks in Advance
    Punithavel
    Message was edited by:
    Punithavel
    Message was edited by:
    Punithavel

    Too difficult to read. I have no database access to test (usually I use a step by step approach, proceeding with the next step when the current one is OK).
    I can describe a general idea (may post something afterwards with no promise it will work)
    step 1: mark the position changes
    step 2: retain only mark 1 and mark max(mark) of each group
    step 3: make a single row from the two rows of each group
    Regards
    Etbin
    with
    marking as
    (select employee,assignment,position,start_date,end_date,
            row_number() over (partition by employee,assignment,position order by start_date) the_mark
       from the_table
    collecting as
    (select employee,assignment,position,start_date,end_date,the_mark
       from marking m
      where the_mark = 1
         or the_mark = (select max(the_mark)
                          from marking
                         where employee = m.employee
                           and assignment = m.assignment
                           and position = m.position
                         group by employee,assignment,position
                         having count(*) > 1
    combining as
    (select employee,assignment,position,
            case when the_mark = 1 then start_date end start_date,
            case when the_mark = 1
                 then case when lead(position,1) over (partition by employee,assignment,position order by start_date) = position
                           then lead(end_date,1) over (partition by employee,assignment,position order by start_date)
                           else end_date
                      end
            end end_date
       from collecting
    select employee,assignment,position,start_date,end_date
      from combining
    where start_date is not null
    order by employee,assignment,position,start_date*** not tested ***
    Message was edited by: Etbin
    user596003
    on a lazy afternoon I took a look at your friend's solution too and I like it.
    It's more concise than mine (defining starts and ends).
    Not being able to test it the only problem in his solution might be the absence of order by clauses to assign correct rownums
    WITH lag_and_lead AS
    (SELECT employee,assignment,position,start_date,end_date,
            LAG (position) OVER (PARTITION BY employee,assignment ORDER BY start_date) AS lag_position,
            LEAD (position) OVER (PARTITION BY employee,assignment ORDER BY start_date) AS lead_position
       FROM your_table
      ORDER BY employee,assignment,start_date
    starts AS
    (SELECT employee,assignment,position,start_date,ROWNUM rn
       FROM lag_and_lead
      WHERE position <> lag_position
         OR lag_position IS NULL
      order by employee,assignment,start_date
    ends AS
    (SELECT employee,assignment,position,end_date,ROWNUM rn
       FROM lag_and_lead
      WHERE position <> lead_position
         OR lead_position IS NULL
      order by employee,assignment,start_date
    SELECT starts.employee,starts.assignment,starts.position,starts.start_date,ends.end_date
      FROM starts,ends
    WHERE starts.employee = ends.employee
       AND starts.assignment = ends.assignment
       AND starts.position = ends.position
       AND starts.rn = ends.rn
    EMPLOYEE ASSIGNMENT POSITION JOB   GRADE START_DATE  END_DATE
         101        132     2055 Clerk C01   10-Mar-2000 11-Feb-2001
         101        132     2055 Clerk C02   12-Feb-2001 15-Dec-2001
         101        132     2056 Clerk C02   16-Dec-2001 22-Jul-2003
         101        132     2055 Clerk C03   23-Jul-2003 31-Dec-4000
    lag_and_lead
    EMPLOYEE ASSIGNMENT POSITION START_DATE  END_DATE    lag_position lead_position
         101        132     2055 10-Mar-2000 11-Feb-2001         null          2055
         101        132     2055 12-Feb-2001 15-Dec-2001         2055          2056
         101        132     2056 16-Dec-2001 22-Jul-2003         2055          2055
         101        132     2055 23-Jul-2003 31-Dec-4000         2056          null
    starts
    EMPLOYEE ASSIGNMENT POSITION START_DATE  rn
         101        132     2055 10-Mar-2000  1
         101        132     2056 16-Dec-2001  2
         101        132     2055 23-Jul-2003  3
    ends
    EMPLOYEE ASSIGNMENT POSITION END_DATE    rn
         101        132     2055 15-Dec-2001  1
         101        132     2056 22-Jul-2003  2
         101        132     2055 31-Dec-4000  3
    EMPLOYEE ASSIGNMENT POSITION START_DATE  END_DATE
         101        132     2055 10-Mar-2000 15-Dec-2001
         101        132     2056 16-Dec-2001 22-Jul-2003
         101        132     2055 23-Jul-2003 31-Dec-4000Regards
    Etbin
    Message was edited by: Etbin
    user596003

  • Set up for Extraction the data from SAP ECC system

    Hi!
    I would like to analyze the transaction and master data from SAP ECC system into SAP BI system.
    I have created the connection (entry for SAP ECC system) within SAP NetWeaver System.
    Unfortunately when I try to load the transaction data for Info source the process does not end successfully.
    There are no information within SM58 on source system.
    The ST22 does not contain some suitable information.
    Question:
    Which settings do I miss and how can solve my problem?
    (user authorization, etc.)
    Thank you very much!
    regards
    Holger

    Hi!
    many thanks for your reply.
    The error I get:
    Errors while sending packages from OLTP to BI
    Diagnosis
    No IDocs could be sent to BI using RFC.
    System Response
    There are IDocs in the source system ALE outbox that did not arrive in the ALE inbox of BI.
    Further analysis:
    Check the TRFC log.
    You can access this log using the wizard or the menu path "Environment -> Transact. RFC -> In source system".
    Error handling:
    If the TRFC is incorrect, check whether the source system is fully connected to BI. In particular, check the authorizations of the background user in the source
    Can you please help me to identify the error?
    Thank you!

  • Query for extracting specific data

    Hi,
    I had two tables contains more than 10,00,00 records.
    customer_mast table
    (CUSTOMER_ID
    LOGIN_NAME
    CREATE_DATE
    CREDENTIAL_TYPE)
    and customer_prod table
    (CUSTOMER_ID
    CREDENTIAL_TYPE
    IND_PROD_LOGIN_ID)
    IND_PROD_LOGIN_ID(numeric) is the customer card number and LOGIN_NAME is the userid(alphanumeric).
    Now from these two table i need to select only those records as per below condition
    1) LOGIN_NAME same as IND_PROD_LOGIN_ID
    2) Corresponding to IND_PROD_LOGIN_ID there should be only one row in customer_mast table, no duplicate row.
    problem is earlier userid was allowed as numeric as well as alphnumeric. Now after new changes i had changed the rules and allowed only alphanumeric userid only. Now i want to clean up the records which contains the numeric as login_name. But there is problem for some card(IND_PROD_LOGIN_ID) having two entries in the customer_mast table one with numeric and one with alphanumeric this is due to process while registering on my site so for those customer i dont want to delete the records.
    Please help me on this.......

    Please, avoid to cross post over different forums, especially this very forum is not for SQL.
    Here your other thread :
    Select query
    And also, when asking such question, better to say about your Oracle version, your tries so far...
    Nicolas.

  • Performance problem whlile selecting(extracting the data)

    i have one intermediate table.
    iam inserting the rows which are derived from a select statement
    The select statement having a where clause which joins a view (created by 5 tables)
    The problem is select statement which is getting the data is taking more time
    i identified the problems like this
    1) The view which is using in the select statement is not indexed---is index is necessary on view ????
    2) Because the tables which are used to create a view have already properly indexed
    3) while extracting the data it is taking the more time
    the below query will extract the data and insert the data in the intermediate table
    SELECT 1414 report_time,
    2 dt_q,
    1 hirearchy_no_q,
    p.unique_security_c,
    p.source_code_c,
    p.customer_specific_security_c user_security_c,
    p.par_value par_value, exchange_code_c,
    (CASE WHEN p.ASK_PRICE_L IS NOT NULL THEN 1
    WHEN p.BID_PRICE_L IS NOT NULL THEN 1
    WHEN p.STRIKE_PRICE_L IS NOT NULL THEN 1
    WHEN p.VALUATION_PRICE_L IS NOT NULL THEN 1 ELSE 0 END) bill_status,
    p.CLASS_C AS CLASS,
    p.SUBCLASS_C AS SUBCLASS,
    p.AGENT_ADDRESS_LINE1_T AS AGENTADDRESSLINE1,
    p.AGENT_ADDRESS_LINE2_T AS AGENTADDRESSLINE2,
    p.AGENT_CODE1_T AS AGENTCODE1,
    p.AGENT_CODE2_T AS AGENTCODE2,
    p.AGENT_NAME_LINE1_T AS AGENTNAMELINE1,
    p.AGENT_NAME_LINE2_T AS AGENTNAMELINE2,
    p.ASK_PRICE_L AS ASKPRICE,
    p.ASK_PRICE_DATE_D AS ASKPRICEDATE,
    p.ASSET_CLASS_T AS ASSETCLASS
    FROM (SELECT
    DISTINCT x.*,m.customer_specific_security_c,m.par_value
    FROM
    HOLDING_M m JOIN ED_DVTKQS_V x ON
    m.unique_security_c = x.unique_security_c AND
    m.customer_c = 'CONF100005' AND
    m.portfolio_c = 24 AND
    m.status_c = 1
    WHERE exists
         (SELECT 1 FROM ED_DVTKQS_V y
              WHERE x.unique_security_c = y.unique_security_c
                   GROUP BY y.unique_security_c
                   HAVING MAX(y.trading_volume_l) = x.trading_volume_l)) p
    any one please give me the valueble suggestions on the performance

    thanks for the updating
    in the select query we used some functions like max
    (SELECT 1 FROM ED_DVTKQS_V y
    WHERE x.unique_security_c = y.unique_security_c
    GROUP BY y.unique_security_c
    HAVING MAX(y.trading_volume_l) = x.trading_volume_l)) p
    will these type of functions will cause the performance problem ???

  • Need a query for export table data .....

    Hi,
    I need a query for exporting the data in a table to a file.
    Can anyone help me ?
    Thanking You
    Jeneesh

    SQL> spool dept.txt
    SQL> select * from dept;
        DEPTNO DNAME          LOC
            10 ACCOUNTING     NEW YORK
            20 RESEARCH       DALLAS
            30 SALES          CHICAGO
            40 OPERATIONS     BOSTON
    SQL> spool off
    SQL> ed dept.txt

  • Need to extract the data from the CRM table : SCAPPTSEG

    Hi BW Experts,
    I want to extract the Data from CRM Table "SCAPPTSEG" to BW. The dates are stored in UTC Format.So for getting the date in CET format, we have used the Function Module "IB_CONVERT_FROM_TIMESTAMP".
    I want to create a datasource for extracting the data from "SCAPPTSEG" table and i need to use the function module for getting the date in CET Format.
    Can i achieve this action through Generic Extraction.
    please provide me the steps to achieve this.
    Thanks,
    Shahina.A

    not answered

  • Which tables are being used to extract the data for the materi Extractors

    Hi
    please advise which tables are used to extract the data for the extarctors
    0MAT_SALES_ATTR,
    0MATERIAL_ATTR,
    0MAT_PLANT_ATTR
    0PLANT_ATTR
    ,Many thanks.

    Hi,
    Activate a database trace using ST01. Then perform the MM03 operation and goto the SD Texts tab. Now stop the trace and see if you can locate either a table or program which you can utilize in the log.
    http://help.sap.com/saphelp_47x200/helpdata/en/dd/55f993545a11d1a7020000e829fd11/frameset.htm
    Hope this helps..
    Rgs,
    Ravikanth.

  • SQL query for making the horizontally stored data to vertical format

    HI i have a table named table1 and columns and data as below like below
    table1
    Main sub1 sub2 sub3 sub4 sub5 sub6
    A L1 T1
    B L1 T1
    C L2 T2 K1 T1
    D L2 T2 K1 T1
    Basically the data is stored in horizontal above.i want a query to make the data in vertical like below
    A T1
    A L1
    B T1
    B L1
    C T1
    C K1
    C T2
    C L2
    D T1
    D K1
    D T2
    D L2
    Aslo even if the values come in sub5 and sub6 the query should handle and populate the values vertically and also if a new row added also.
    Thanks a lot in advance

    Hi,
    As usual, Hoek is absolutely correct.
    There are a gazillion examples out there, but someone (I) will give you a specific answer.
    Search for "pivot" or "rows to columns" and you will indeed get a gazillion hits. Unfortunately, all but a hemi-semi-demi-gazillion of them will say "There are already lots of examples out there: do a search". Perhaps [this one|http://forums.oracle.com/forums/message.jspa?messageID=3227388#3227388] can get you started.
    The essential form of a pivot is:
    SELECT       r_val
    ,       MIN (CASE WHEN c_val = 1 THEN d END)     AS col_1
    ,       MIN (CASE WHEN c_val = 2 THEN d END)     AS col_2
    ,       MIN (CASE WHEN c_val = n THEN d END)     AS col_n
    FROM       table_x
    GROUP BY  r_val;Instead of MIN (which is probably what want) any aggregate function can be used.
    This assumes you have a column r_val that indicates what row of output will contain each value. In your example, that's your first column,
    It also assumes you have a column c_val that indicates what column will contain each value. In your example, what is that? Looking at the raw data, how can you tell that 'L2' will wind up in the 2nd column of 'D L2 T2 K1 T1', and not the 3rd, 4th or 5th? You may need to assign a c_val to each row (using the aggregate ROW_NUMBER function, perhaps).

  • Use LINQ to extract the data from a file...

    Hi,
    I have created a Subprocedure CreateEventList
    which populates an EventsComboBox
    with a current day's events (if any).
    I need to store the events in a generic List communityEvents
    which is a collection of
    communityEvent
    objects. This List needs to be created and assigned to the instance variable
    communityEvents.
    This method should call helper method ExtractData
    which will use LINQ to extract the data from my file.
    The specified day is the date selected on the calendar control. This method will be called from the CreateEventList.
    This method should clear all data from List communityEvents.  
    A LINQ
    query that creates CommunityEvent
    objects should select the events scheduled for selected
    day from the file. The selected events should be added to List
    communityEvents.
    See code below.
    Thanks,
    public class CommunityEvent
    private int day;
    public int Day
    get
    return day;
    set
    day = value;
    private string time;
    public string Time
    get
    return time;
    set
    time = value;
    private decimal price;
    public decimal Price
    get
    return price;
    set
    price = value;
    private string name;
    public string Name
    get
    return name;
    set
    name = value;
    private string description;
    public string Description
    get
    return description;
    set
    description = value;
    private void eventComboBox_SelectedIndexChanged(object sender, EventArgs e)
    if (eventComboBox.SelectedIndex == 0)
    descriptionTextBox.Text = "2.30PM. Price 12.50. Take part in creating various types of Arts & Crafts at this fair.";
    if (eventComboBox.SelectedIndex == 1)
    descriptionTextBox.Text = "4.30PM. Price 00.00. Take part in cleaning the local Park.";
    if (eventComboBox.SelectedIndex == 2)
    descriptionTextBox.Text = "1.30PM. Price 10.00. Take part in selling goods.";
    if (eventComboBox.SelectedIndex == 3)
    descriptionTextBox.Text = "12.30PM. Price 10.00. Take part in a game of rounders in the local Park.";
    if (eventComboBox.SelectedIndex == 4)
    descriptionTextBox.Text = "11.30PM. Price 15.00. Take part in an Egg & Spoon Race in the local Park";
    if (eventComboBox.SelectedIndex == 5)
    descriptionTextBox.Text = "No Events today.";

    Any help here would be great.
    Look, you have to make the file a XML file type -- Somefilename.xml.
    http://www.xmlfiles.com/xml/xml_intro.asp
    You can use NotePad XML to make the XML and save the text file.
    http://support.microsoft.com/kb/296560
    Or you can just use Notepad (standard), if you know the basics of how to create XML, which is just text data that can created and saved in a text file, which, represents data.
    http://www.codeproject.com/Tips/522456/Reading-XML-using-LINQ
    You can do a (select new CommunityEvent) just like the example is doing a
    select new FileToWatch and load the XML data into the CommunityEvent properties.
    So you need to learn how to make a manual XML textfile with XML data in it, and you need to learn how to use LINQ to read the XML. Linq is not going to work against some  flat text file you created. There are plenty of examples out on Bing and Google
    on how to use Linq-2-XML.
    http://en.wikipedia.org/wiki/Language_Integrated_Query
    <copied>
    LINQ extends the language by the addition of query
    expressions, which are akin to
    SQL statements, and can be used to conveniently extract and process data from
    arrays, enumerable
    classes, XML documents,
    relational databases, and third-party data sources. Other uses, which utilize query expressions as a general framework for readably composing arbitrary computations, include the construction of event handlers<sup class="reference" id="cite_ref-reactive_2-0">[2]</sup>
    or
    monadic parsers.<sup class="reference" id="cite_ref-parscomb_3-0">[3]</sup>
    <end>
    <sup class="reference" id="cite_ref-parscomb_3-0"></sup>

  • Need to write a query for extractions

    How can I extract the following data from Oracle:
    1. Segment1 and description from mtl_system_items_b
    2. Onhand quantity that is orderable (Not under the WIP manufacturing or PO)
    3. Onhand quantity that not orderable (That is under WIP manufacturing or PO)
    4. Retail Price of these items.
    There is only one organization_id =21 needs to be considered. This extract needs to be a daily kind of an extract. If you can help me in writing the query for all the fields above with proper joins, I'll really appreciate.
    Thanks & Regards
    KM

    Hi,
    Primary_uom_code and Primary_transaction_quantity shows the items quantity on the basis of primary code
    whereas Secondary_uom_code and secondary_transction_quantity shows the items quantity on different code.
    e.g. suppose you have an item Pen opened on the primary code as Each. 1 Each = 1 Pen.
    You have a conversion set as 10 Each = 1 Pkt.
    At the time of transaction if you selects as 1 Pkt,
    The primary_transaction_quantity will show 10 Each where as the secondary_transaction_quantity will show 1Pkt.
    Now as the transaction has done as Pkt the column Transaction_quantity will display 10Pkt.
    If you have done this transaction on the primary code as 10 Each.
    The primary_transaction_quantity would show the same 10 Each but the Secondary_transaction_quantity will by
    null and the transaction_quantity will be 10 Each.
    Hope this will clarify the issue.
    2) why you want to join these tables
    How can I join the following tables: qp_list_lines and mtl_system_items_b? I want to find the price of each
    item. I tried using inventory_item_id but it does not work as inventory_item_id can be null in qp_list_lines table.i have not been able to find any thing in table qp_list_lines.

  • I've to extract the data based on the sysdate...like today dd is 11,

    BM_PERF is the table name and
    BM_PERF_YR,BM_PERF_MONTH,BM_NOP_CT_1........BM_NOP_CT_31 are the column names.
    I've to extract the data based on the sysdate...like today dd is 11
    so i've to get data from BM_NOP_CT_11 and the column names changes dynamically based on the sysdate. don't use any procedures and functions.

    You could always pivot it into a more convenient form for querying:
    WITH t1 AS
         ( SELECT 2008 AS yr, 4 AS mnth
                , 20 AS dy1
                , 10 AS dy2
                , 15 AS dy3
                , 1  AS dy4
                , 17 AS dy5
                , 99 AS dy6
                , 55 AS dy7
                , 45 AS dy8
                , 33 AS dy9
                , 22 AS dy10
                , 74 AS dy11
                , 35 AS dy12
                , 62 AS dy13
                , 24 AS dy14
                , 85 AS dy15
           FROM dual )
       , t2 AS
         ( SELECT yr
                , mnth
                , sys.DBMS_DEBUG_VC2COLL
                  (dy1,dy2,dy3,dy4,dy5,dy6,dy7,dy8,dy9,dy10,dy11,dy12,dy13,dy14,dy15)
                  AS day_data
           FROM   t1 )
    SELECT t2.yr, t2.mnth, sys_op_ceg(t2.day_data,5) day_value
    FROM   t2;
            YR       MNTH DAY_VALUE
          2008          4 17
    1 row selected.Note that SYS_OP_CEG (first discovered by Padders) is undocumented and unsupported - for production code you'd need to pick the collection row using a WHERE clause, and for that you'd need a custom object and collection type with an attribute to hold the day number.
    Message was edited by:
    William Robertson
    ...like this:
    CREATE TYPE id_value_ot AS OBJECT
    ( id INTEGER, val NUMBER );
    CREATE TYPE id_value_tt AS TABLE OF id_value_ot ;
    WITH t1 AS
         ( SELECT 2008 AS yr, 4 AS mnth
                , 20 AS dy1
                , 10 AS dy2
                , 15 AS dy3
                , 1  AS dy4
                , 17 AS dy5
                , 99 AS dy6
                , 55 AS dy7
                , 45 AS dy8
                , 33 AS dy9
                , 22 AS dy10
                , 74 AS dy11
                , 35 AS dy12
                , 62 AS dy13
                , 24 AS dy14
                , 85 AS dy15
           FROM dual )
       , t2 AS
         ( SELECT yr
                , mnth
                , id_value_tt
                  ( id_value_ot(1,dy1)
                  , id_value_ot(2,dy2)
                  , id_value_ot(3,dy3)
                  , id_value_ot(4,dy4)
                  , id_value_ot(5,dy5)
                  , id_value_ot(6,dy6)
                  , id_value_ot(7,dy7)
                  , id_value_ot(8,dy8)
                  , id_value_ot(9,dy9)
                  , id_value_ot(10,dy10)
                  , id_value_ot(11,dy11)
                  , id_value_ot(12,dy12)
                  , id_value_ot(13,dy13)
                  , id_value_ot(14,dy14)
                  , id_value_ot(15,dy15) )
                  AS day_data
           FROM   t1 )
    SELECT yr, mnth, dd.val
    FROM   t2, TABLE(t2.day_data) dd
    WHERE  dd.id = 5;
            YR       MNTH        VAL
          2008          4         17
    1 row selected.

  • Error while extracting the data in R/3 production system,

    Hi Team,
    We got the following error while extracting the data in R/3 production system,
    Error 7 When Sending an IDoc R3 3
    No Storage space available for extending the inter 44 R3 299
    No storage space available for extending the inter R3 299
    Error in Source System RSM 340
    Please guide us to fix the issue

    It´s very difficult to help you without knowing
    - what is going to be transferred
    - where you get this error
    - system configuration
    - actual memory usage
    - operating system
    - database and configuration etc. etc.etc. etc.
    I suggest you open an OSS call and let the support have a look on your system. It´s much easier if one has system access to find out the cause for that problem.
    Markus

  • I ran my iphone over but need to access my contacts/info/pics. I have a up to date backup of my whole phone in iTunes but need to know how to extract the data and load it to my new desktop since it will be a bit before I can afford a new phone.

    I accidentally ran my iPhone over and can't afford another one for a few weeks. Until then I need to find a way to extract the data from my last backup in itunes. I can either put it on my computer or I've set up a cloud account that I was hoping could open it. So far I haven't had any luck with either. if anyone can help me out. I would love to get my pictures/videos, messages and contacts off there. The rest I don't care so much about. If someone could let me know if this is possible I would apprciate it!

    Thanks. I messed up with my husbands iphone because I was told the wrong thing. Now everytime I sync his phone it makes it look just like the other phone I had. Do you know how I can fix taht for his phone? Any settings I can turn off that will prevent all of my apps/contacts, etc from auto populating his phone?

Maybe you are looking for

  • Should Apple punt with RAW and/or DNG support ?

    It seems that Apple is taking a very detailed approach to profiling cameras before adding support to Aperture. Consequently Aperture may always be later than others apps to add new camera support. Also there will always be legacy or specialty cameras

  • Autodiscover-SSLCert-Activesync Issue

    Hello. I have odd issue. So first of all we are on Exchange 2010 and have host our email and that of 2 other companies. The other companies mailboxes are setup in our domain but we change their SMTP alias to that of their domain name. We then setup t

  • Unable to connect to my Oracle Database with Microsoft's ODBC for Oracle driver

    I am unable to connect to my Oracle Database with Microsoft's ODBC for Oracle driver vers.2.573.4202.00 on a Win98 computer. First, I create a "Net Service Name" in order for the ODBC Driver to find the Oracle server. I then created a System DSN in t

  • Building a Dual Layered DVD

    We need to create a DVD that will ultimately be formatted for a Dual Layered DVD. Our department dosen't have a Dual Layered Burner, but we have to create 2 DVDs that will go to another house so THEY can build the Dual Layered DVD. The book says that

  • Newbie having problems with noisy fan and high CPU usage in Activity Monitor

    I am new to the world of Apple and have got my hands on a hand-me-down PowerBook G4 version 10.4.11. It works fairly well for everything but the Internet. One of the first symptoms i noticed was that watching stuff on youtube was slow and jumped a lo