Get data from two list simultaneously using REST

Is it possible to query two list in the same time?
url: http://sites.com/url/_api/web/lists/GetByTitle(‘List1')
url: http://sites.com/url/_api/web/lists/GetByTitle(‘List1' and 'List2')
Thanks in advance

Hi ,
By default SharePoint doesn't provide this kind of rest service or server object model api to retrieve the specified multiple lists once, it could only get all lists or one specified list one time.
you may query twice to get two lists as a workaround.
http://msdn.microsoft.com/en-us/library/office/fp142380(v=office.15).aspx
http://msdn.microsoft.com/en-us/library/jj246453.aspx
Thanks
Daniel Yang
TechNet Community Support

Similar Messages

  • SaveToFile example modificati​on to get data from two channels simultaneo​usly.

    We are trying to modify the “SaveToFile” example for C++. This particular example comes with NI-scope 2.9.1 and some other versions. This example collects data from one channel and saves the output as a text file. Also, we are using NI PCI-5112 DAQ.
    However, it can be modified to get data from channel 0 and channel 1 at the same time. There is a help file called “Fetching Multiple-Record Acquisitions”, which is under the NI-High speed digitizer help topics. This confirms that you can modify the code to get data from two channels and the output will be a text file where every other value is from one channel. This help file also gives some code. However, it is not very much helpful to us, please keep in mind that we have only taken a basic course in C++.
    Our project is to analyze the data, however, we need to acquire the data before we can analyze. We have spent so much time trying to get the data.  What we need to do is get data from both channels simultaneously and output the data as a text file.
    Can anyone help us to modify the code so it can get data from both channels simultaneously? Or can anyone help as where we can get more information? Or does anyone know of any sample examples that will take data from two channels simultaneously and output the data as a text file or any other type of document.
    Any help will be really appreciated, as we have spent so much time trying to acquire the data.
    Thanks.

    Hi Finomad,
    Please see this post for an answer to your question.
    Regards,
    Natasa

  • How to get data from subsites list of SharePoint 2010 in ssrs

    Hi,
    Can someone help me on this issue.
    I want to create a report using ssrs, I have some of the data in SQL and some of the data in sharepoint list.
    First I need to go to SQL and get the data from the table which contains URL for the subsite in sharepoint.
    after that I need to go to all the subsites and go to perticulat list in the subsites and get data from that list.
    for example, their is a top level site "abc"
    it contains sub site "123", "456","567", etc.. All this sub sites contain a list by name "Sample List", Now I need to go to that sub site list(Sample List) and get list-item column say "created By" which
    is created on particular date. 
    in my report, I need to print the sub site "url/Title" which comes from SQL database and list-item column  "Created By" of that sub site list "Sample List".
    I tried using subreport inside a report by using "Microsoft SharePoint List" as a datasource, but when it comes to real time we don't know how many subsites will be created, so we can't create a datasource for each subsite site.
    I guess we need to be using XML as a datasource, but how can we go to particular subsite in query while using XML, since all subsites have list with the same name ?
    I appreciate your help.
    Thank you,
    Kishore 

    Hi Kishore,
    SQL Server Reporting Services(SSRS) supports expression-based connection strings. This will help us to achieve the goal you mentioned in this case:
    Create a new report
    Create a Data Source in the report with the connection string like this:
    http://server/_vti_bin/lists.asmx (We use static connection string instead of expression-based connection string now, as it is not supported to get fields based on expression-based connection string in design time. We will change it to be expression-based
    connection string later)
    Create the data set(as you have done using XML query language). Please use list name instead of GUID in the listName parameter.
    Design the report(e.g. Add controls to the report)
    Now, let's change the connection string to be expression-based. First, please add a parameter to the report, move this parameter to top. This parameter is used to store the sub site name.
    Open the Data Source editor, set the connection string to be: ="http://server/" & Parameters!parameterCreatedInStep5.value & "_vti_bin/lists.asmx"
    In the main report, pass the sub site name to the report we created above via the parameter created in step5
    That is all.
    Anyway, this is actually a SQL Server Reporting Service(SSRS) question. You can get better support on this question from:
    http://social.technet.microsoft.com/Forums/en/sqlreportingservices/threads
    For more information about Expression-Based connection string, please see:
    http://msdn.microsoft.com/en-us/library/ms156450.aspx#Expressions
    If there is anything unclear, please feel free to ask.
    Thanks,
    Jinchun Chen
    Jin Chen - MSFT

  • Fastest way to get data from Multiple lists across multiple site collections

    HI
    I need to get data from multiple lists which spread across 20 site collections and need to show it as list view.
    I have searched on internet about this and got some info like options would be to use search core APIs or BCS . I can't use search because I want real time data. Not sure of any other ways.
    if anybody can provide ideas it would be help.

    Might LINQ be an option for you?  Using
    LINQPad and the
    SharePoint Connector, you should be able to write a query that'll retrieve this data, from which you can tabulate it.  I'm not sure how you'd be able to automate this any further so that it's then imported in as list.
    For something more specific, I used a third party tool called the
    Lightning Tools Lightning Conductor, which is essence a powerful content roll-up tool.  In one of my solutions, I created a calculated column that gave an order / ranking on each item, so that when lists were combined, they'd still have some form of
    order.  The web part is also fairly customisable and has always proven a useful tool.
    Hope that helps.
    Steven Andrews
    SharePoint Business Analyst: LiveNation Entertainment
    Blog: baron72.wordpress.com
    Twitter: Follow @backpackerd00d
    My Wiki Articles:
    CodePlex Corner Series
    Please remember to mark your question as "answered" if this solves (or helps) your problem.

  • Get data from two databases?

    Hello all,
    Do anyone know if it's posible to get data from two databases while I'm running SBO in one of them? I need this because our client wants to be able to print reports with all the information stored in both companies. I searched this forum trying to find if this is possible but I did't find any information about this.
    Can someone help me?
    Thanks and regards,
    Mariana Mazzero

    Hi Mariana,
    What you can do is use two company objects to retrieve the data. As far as I know you're not restricted to one company connection.
    You can also just use a standard read only connection (like ADO/ODBC) to retrieve the data for the reports.
    Hope it helps,
    Adele

  • Getting Dates from Calendar List

    If I input year as 2005 and month as Feb, I need to get list of all dates available in that year and month.
    How to get it from Calendar List?

    If I input year as 2005 and month as Feb, I need to
    get list of all dates available in that year and
    month.Calculating the days in the month for the particular year is not difficult. Once that is done, the logic is simple!
    Take a look at http://www.servletsuite.com/jsp.htm. It has some tags I suppose!
    How to get it from Calendar List?Would you be clear on what you really want?

  • Getting data from two servers?

    Experts-
    We have two servers for storing tables . 1. Historical server 1.Current Prod server
    We have same tables in both server databases.
    All the info prior to a month of current date is stored in Historical server database tables
    and the rest in current prod server dtabase tables.
    I have to build reports such that, when user enters a date, OBIEE has to check if the date is in a month period(30 days) of todays date or earlier to 30 days, based on this, it has to get the data from historical server database tables / current prod server database.
    How can I implement this?
    Do I need to create two connction pools(folders in rpd) and develop same Model twice?(One for historical tables and one for prod tables?)
    or Can I use fragmentation technique? if so, Can you give me an Idea hwow to implement Fragmentation for this requirement?
    Thanks for your help in advance

    You should use fragmentation for this requirement. It's not that hard once you've understood the basic principle. Read Nico's article here for the detail:
    http://gerardnico.com/wiki/dat/obiee/fragmentation_content
    The only non-standard bit for you will be to set the fragmentation criteria on your logical table sources. This is the part that tells BI server which source to hit.
    Post back here if you get stuck.
    Paul

  • Unexpected results getting data from two fact tables through conformed dim

    Hi all,
    We are getting an unexpected behaviour in our OBIEE 10.1.3.3.3. We have this scenario:
    We have {color:#0000ff}2 fact tables{color}{color:#000000} called F1 and F2. F1 has one measure, f1m1 and F2 has another one, f2m1.
    We have {color:#0000ff}4 conformed dimensions{color}, called D1, D2, D3, Date.
    When we are requesting for individual fact tables, we are getting:
    date d1 d2 d3 f1m1
    dt1 - x - y - z - m1
    dt1 - x - y - z' - m2
    date d1 d2 d3 f2m1
    dt1 - x - y - z - m3
    dt1 - x - y - z'' - m4
    But, trying to obtain a compare scenario, we are getting
    date d1 d2 d3 f1m1 f2m1
    dt1 x y z m1 m4
    Instead of
    date d1 d2 d3 f1m1 f2m1
    dt1 x y z m1 m3
    Looking at query log, we have catched the reason. That's why BI Server is using to solve this request using ROW_COUNT() to join SAWITH0 and SAWITH1 in SAWITH2 result set. So, the order may not be the same in the results sets in every fact table. More or less, generated query is like:
    WITH
    SAWITH0 AS
    (select ....
    from F1),
    SAWITH1 AS
    (select ...
    from F2),
    SAWITH2 AS
    select from (select ...
    ROW_NUMBER() OVER PARTITION (....) c10
    from SAWITH0.d1 full outer join SAWITH1.d1 ....) D1
    {color:#ff0000}where (D1.c10 = 1){color}
    select SAWITH2. ....
    from SAWITH2
    order by c1..c10
    The problems seems to be that BI server is ordering the result sets SAWITH0 and SAWITH1 and getting row number to join this results sets, but this is not getting the correct result.
    Any ideas?
    TIA
    Javier
    {color}
    Edited by: jirazazábal on Mar 13, 2009 2:46 PM

    I have done a logical fact table with two fact table source on it.
    The Sql performed against the database was this one.
    -------------------- Sending query to database named PRODS_AIX (id: <<153418>>):
    WITH
    SAWITH0 AS (select sum(T21296.CONSUMERS_SALES_EURO) as c1,
         T21309.DIVISION_CODE as c2
    from
         DIVISION T21309,
         C_CONSUMERS_SALES T21296
    where  ( T21296.DIVISION = T21309.DIMENSION_KEY )
    group by T21309.DIVISION_CODE),
    SAWITH1 AS (select sum(T21356.ORDER_VALUE) as c1,
         T21309.DIVISION_CODE as c2
    from
         DIVISION T21309,
         DWH_SALES_ORDER_OVERVIEW T21356
    where  ( T21309.DIMENSION_KEY = T21356.DIVISION_KEY )
    group by T21309.DIVISION_CODE)
    select distinct case  when SAWITH0.c2 is not null then SAWITH0.c2 when SAWITH1.c2 is not null then SAWITH1.c2 end  as c1,
         SAWITH0.c1 as c2,
         SAWITH1.c1 as c3
    from
         SAWITH0 full outer join SAWITH1 On nvl(SAWITH0.c2 , 'q') = nvl(SAWITH1.c2 , 'q') and nvl(SAWITH0.c2 , 'z') = nvl(SAWITH1.c2 , 'z')
    order by c1As you can see one select (SAWITH0) for the first fact table C_CONSUMERS_SALES and one select for the second fact table DWH_SALES_ORDER_OVERVIEW (SAWITH1 ) and the two statement are joined with a full outer join.
    I ask me why you have the three select (SAWITH0,SAWITH1 and SAWITH2). Can you please paste the complete SQL performed ?
    Can you tell us also which SQL is performed if you select only the columns from one fact table and not for the other ?
    Regards
    Nico
    http://gerardnico.com

  • ALV OOps report- getting data from two tables and adding issue

    Hi,
    This is sales employee performance report.
    I need to select all the fields from two tables based on user input ie VKorg, sales employee .
    There is one field callled " Net sales"in both the tables.
    Based on sales employee number, i need to add that net sales which i get from two tables.
    I need to generate single report.
    Can you give some inputs reg. the select query.
    My idea is select all the data from both tables using join statement.
    Thanks

    Hi,
    I have written like this:
    select * from S002 as a join S006 as b
        into table ME->SS002_RAW[]
        where vkorg in me->select_parameters->SO_VKORG[] = vkorg in me->select_parameters->SO_VKORG[]
              and ZZSLSEMP01 in me->select_parameters->SO_so_empl[] = ZZSLSEMP02 in me->select_parameters->SO_so_empl[].
    when i do like that,
    I am getting error
    Incorrect structure of FROM clause . . . .     
    If you give some idea on this
    Edited by: Raja on Apr 22, 2009 11:19 AM

  • Line Chart - getting data from two table to behave as 1 data series

    I'm using the 'Personal Budget' template, and have two tables titled 'Annual Budget by Month: 2009' and 'Annual Budget by Month: 2010'. These tables show, as their last row, my total savings. I want to set up a line chart to display the (downward) trajectory of my savings in one continuous line.
    However, if I create a line chart, the two data sets from the two tables are displayed as two lines, one below the other. If I convert it to a column chart, and then switch to columns instead of rows as the Plotting Orientation (data series button in the upper left of the table), the columns do display correctly. Can anyone tell me how I can get the line version to work?

    spiff,
    I think the solution to your problem is to create a summary table that gathers the data from all your month tables, then plot the summary. Remember to put the category names into a Header row or column so they will automatically show up on the chart axes.
    Jerry

  • Get data from two joined tables there are not in both

    At first, that tabes are in shortcut. To get this tables I need to use lot of joins (about 3-4).
    TABLE "OBIEKTY"
    ZAKLAD          OBIEKT            
    1               100                   
    1               200                   
    1               300                   
    TABLE "OPIS"
    ZAKLAD          OBIEKT          NAZWA           TYP             
    1               100             obiekt 1        A                   
    1               200             obiekt 2        B                   
    1               400             obiekt 3        C                    I have to get:
    NEEDED RESULT
    ZAKLAD          OBIEKT          NAZWA           TYP             
    1               400             obiekt 3        C   I have two tables with many rows, so executing "not in (select...)" for each one row is not to good I think :)
    select obiekt, zaklad, nazwa, typ
        from opis where (zaklad, obiekt) not in (select zaklad, obiekt from obiekty)

    For your input and output use below code
    select * from OPIS WHERE OBIEKT             IN 
    select  OBIEKT             from OPIS
    minus
    select OBIEKT             from OBIEKTY)

  • Get data from two partitions

    I want to do a query that returns data only from last two partitions
    I have this select that returns data from one partition only.
    select *
    from tsieven PARTITION(P200707_2Q)
    I would like to have something like this for example...
    select *
    from tsieven PARTITION(P200707_2Q and P200707_1Q)

    Oracle version is 9i
    Partition method (MAX VALUE): TO_DATE(' 2006-04-16 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN')
    Usually the partition is divided by 15 days. starts in the begin of the month and ends in 15th of the same month.
    Partition column: DATA_CRIACAO
    I'm trying to to this query:
    select tsieven.loptica, tsieven.data_evento Data_Distribuicao
    from tsieven (PARTITION MAX), tgirnos n, tsiobje o
    where tsieven.no_evento = n.COD_NO
    and tsieven.loptica = o.loptica
    and to_char(tsieven.data_evento,'dd-mm-yyyy') = to_char(p_data,'dd-mm-yyyy')
    and o.cod_classe = p_classe
    and n.COD_TIPO_NO='2'
    and tsieven.COD_T_EVEN = 'EMZ'
    and n.cod_no = p_cdp
    order by tsieven.loptica
    For example I need to get data for sysdate from 27th of july it's not in this last partition, because it started a new one in 1st of august.
    Hope I'm being clear now.
    Thanks for your help.

  • Getting data from two sources

    Hi all, i am trying to solve an specific scenario which i am having trouble with. here is my data
    WITH data AS
    SELECT 123 id, '10.30.2009' dt, 10 src, 'test1' name, 145 yd, 780 pdf, 'hd1' var FROM dual UNION ALL
    SELECT 123 id, '10.31.2009' dt, 10 src, 'test2' name, 146 yd, 781 pdf, 'hd2' var FROM DUAL UNION ALL
    SELECT 123 id, '11.10.2009' dt, 10 src, 'test3' name, 147 yd, 782 pdf, 'hd3' var FROM DUAL UNION ALL
    SELECT 123 id, '11.11.2009' dt, 10 src, 'test4' name, 147 yd, 182 pdf, 'hd4' var FROM DUAL UNION ALL
    SELECT 123 id, '11.12.2009' dt, 10 src, 'test5' name, 167 yd, 212 pdf, 'hd33' var FROM DUAL UNION ALL
    SELECT 123 id, '11.13.2009' dt, 10 src, 'test6' name, 137 yd, 322 pdf, 'hd34' var FROM DUAL UNION ALL
    SELECT 123 id, '9.27.2009' dt, 10 src, 'test7' name, 148 yd, 783 pdf, 'hd4' var FROM DUAL UNION ALL
    SELECT 123 id, '10.12.2009' dt, 10 src, 'test8' name, 149 yd, 784 pdf, 'hd5' var FROM DUAL
    data2
    SELECT 123 id, '9.25.2009' dt, 11 src, 'test4' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.26.2009' dt, 11 src, 'test5' name, 135 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.27.2009' dt, 11 src, 'test7' name, 15 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.28.2009' dt, 11 src, 'test8' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.29.2009' dt, 11 src, 'test99' name, 175 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.30.2009' dt, 11 src, 'test44' name, 175 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.31.2009' dt, 11 src, 'test33' name, 148 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.1.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.2.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.3.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.4.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.5.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.6.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.7.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.8.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.9.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.10.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.11.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.12.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.13.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.14.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.15.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.16.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.17.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.18.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.19.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.20.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.21.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.22.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.23.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.24.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.25.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.26.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.27.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.28.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.29.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.30.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.31.2009' dt, 11 src, 'test' name, 146 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.01.2009' dt, 11 src, 'test' name, 147 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.2.2009' dt, 11 src, 'test' name, 148 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.3.2009' dt, 11 src, 'test' name, 149 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.4.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.5.2009' dt, 11 src, 'test' name, 148 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.6.2009' dt, 11 src, 'test' name, 149 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.7.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.8.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.9.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.10.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL
    as you can see there are some rows in data table that matches the id, dt in data2.
    there is some rows in data2 that is not there in data table and vice versa. also both tables columns
    are identical except that data has more columns that data2 doesnt have.     i want to write a query.
    i would like to join data and data2 table.
    if a row in data table matches a row in data2 then i would take the row in data table
    and display it along with the rest of the columns. if a row is not found in data but it is found
    in data2 for a particular id (in this case 123) then i want to display the row from data2 and the rest of the columns value from data2.
    please note that in the data above i gave you one specific id 123. my tables will have the same situation as above
    for different id. the output of the above query should be as follow.
    ID DT SRC NAME YD PDF VAR
    123     9.25.2009 11 testt 145
    123     9.26.2009 11 test5 135
    123     9.27.2009 10 test7 148 783 hd4
    123     9.28.2009 11 test8 145
    123     9.29.2009 11 test99 175
    123     9.30.2009 11 test44 175
    123     9.31.2009 11 test33 148
    123     10.1.2009 11 test 145
    123     10.2.2009 11 test 145
    123     10.3.2009 11 test 145
    123     10.4.2009 11 test 145
    123     10.5.2009 11 test 145
    123     10.6.2009 11 test 145
    123     10.7.2009 11 test 145
    123     10.8.2009 11 test 145
    123     10.9.2009 11 test 145
    123     10.10.2009 11 test 145
    123     10.11.2009 11 test 145
    123     10.12.2009 10 test8 149 784 hd5
    123     10.13.2009 11 test 145
    123     10.14.2009 11 test 145
    123     10.15.2009 11 test 145
    123     10.16.2009 11 test 145
    123     10.17.2009 11 test 145
    123     10.18.2009 11 test 145
    123     10.19.2009 11 test 145
    123     10.20.2009 11 test 145
    123     10.21.2009 11 test 145
    123     10.22.2009 11 test 145
    123     10.23.2009 11 test 145
    123     10.24.2009 11 test 145
    123     10.25.2009 11 test 145
    123     10.26.2009 11 test 145
    123     10.27.2009 11 test 145
    123     10.28.2009 11 test 145
    123     10.29.2009 11 test 145
    123     10.30.2009 10 test1 145 780 hd1
    123     10.31.2009 10 test2 146 781 hd2
    123     11.01.2009 11 test 147
    123     11.2.2009 11 test 148
    123     11.3.2009 11 test 149
    123     11.4.2009 11 test 141
    123     11.5.2009 11 test 148
    123     11.6.2009 11 test 149
    123     11.7.2009 11 test 141
    123     11.8.2009 11 test 141
    123     11.9.2009 11 test 141
    123     11.10.2009 10 test3 747 782 hd3
    123     11.11.2009 10 test4 147 182 hd4
    123     11.12.2009 10 test5 167 212 hd33
    123     11.13.2009 10 test6 137 322 hd34
    123     11.14.2009 11 test 141
    if you notice, i am displaying the data from data table when there is a match in data and data2 tables for a particular id, dt combination.
    if there is data in data2 that is not in data then i pull those data from data2 and display. the same thing goes for data table. if there is data in data table
    but it is not there in data2 then i display data from data table. when rows matches then i take the one from data table
    i would like to write a query that give the above output. if anybody can help, i will appreciate.
    thanks

    Hi,
    I'm sorry, misread it and didn't look wll at the outcome. This is better:
    WITH data AS
    SELECT 123 id, '10.30.2009' dt, 10 src, 'test1' name, 145 yd, 780 pdf, 'hd1' var FROM dual UNION ALL
    SELECT 123 id, '10.31.2009' dt, 10 src, 'test2' name, 146 yd, 781 pdf, 'hd2' var FROM DUAL UNION ALL
    SELECT 123 id, '11.10.2009' dt, 10 src, 'test3' name, 147 yd, 782 pdf, 'hd3' var FROM DUAL UNION ALL
    SELECT 123 id, '11.11.2009' dt, 10 src, 'test4' name, 147 yd, 182 pdf, 'hd4' var FROM DUAL UNION ALL
    SELECT 123 id, '11.12.2009' dt, 10 src, 'test5' name, 167 yd, 212 pdf, 'hd33' var FROM DUAL UNION ALL
    SELECT 123 id, '11.13.2009' dt, 10 src, 'test6' name, 137 yd, 322 pdf, 'hd34' var FROM DUAL UNION ALL
    SELECT 123 id, '9.27.2009' dt, 10 src, 'test7' name, 148 yd, 783 pdf, 'hd4' var FROM DUAL UNION ALL
    SELECT 123 id, '10.12.2009' dt, 10 src, 'test8' name, 149 yd, 784 pdf, 'hd5' var FROM DUAL
    data2 as
    SELECT 123 id, '9.25.2009' dt, 11 src, 'test4' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.26.2009' dt, 11 src, 'test5' name, 135 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.27.2009' dt, 11 src, 'test7' name, 15 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.28.2009' dt, 11 src, 'test8' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.29.2009' dt, 11 src, 'test99' name, 175 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.30.2009' dt, 11 src, 'test44' name, 175 yd FROM DUAL UNION ALL
    SELECT 123 id, '9.31.2009' dt, 11 src, 'test33' name, 148 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.1.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.2.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.3.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.4.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.5.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.6.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.7.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.8.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.9.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.10.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.11.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.12.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.13.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.14.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.15.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.16.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.17.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.18.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.19.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.20.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.21.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.22.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.23.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.24.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.25.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.26.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.27.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.28.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.29.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.30.2009' dt, 11 src, 'test' name, 145 yd FROM DUAL UNION ALL
    SELECT 123 id, '10.31.2009' dt, 11 src, 'test' name, 146 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.01.2009' dt, 11 src, 'test' name, 147 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.2.2009' dt, 11 src, 'test' name, 148 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.3.2009' dt, 11 src, 'test' name, 149 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.4.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.5.2009' dt, 11 src, 'test' name, 148 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.6.2009' dt, 11 src, 'test' name, 149 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.7.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.8.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.9.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL UNION ALL
    SELECT 123 id, '11.10.2009' dt, 11 src, 'test' name, 141 yd FROM DUAL
    select data2.id,data2.dt,nvl(data.src,data2.src) src, nvl(data.name,data2.name) name,nvl(data.yd,data2.yd) yd,data.pdf,data.var
    from data2,data
    where data2.id = data.id(+)
    and data2.dt = data.dt(+)Herald ten Dam
    Superconsult.nl

  • Phpmysql server behaviour (How to get date from dropdown list day & month)

    Hi,
    Appreciate if someone can help me on this. I already create form and in my form there is date selector to select day,month and year. But how to use insert record funtion to get the date as below.
    thanks.
    <form id="form1" name="form1" method="post" action="">
      <table width="60%" border="0" align="center" cellpadding="3" cellspacing="3">
        <tr>
          <td width="85">Date</td>
          <td width="4">:</td>
          <td width="381"><input name="name" type="hidden" id="name" value="<?php echo $user ?>" />
            <input name="department" type="hidden" id="department" value="<?php echo $department ?>" />
            <select name="day" id="day" >
              <option value='01'>01</option>
              <option value='02'>02</option>
              <option value='03'>03</option>
              <option value='04'>04</option>
              <option value='05'>05</option>
              <option value='06'>06</option>
              <option value='07'>07</option>
              <option value='08'>08</option>
              <option value='09'>09</option>
              <option value='10'>10</option>
              <option value='11'>11</option>
              <option value='12'>12</option>
              <option value='13'>13</option>
              <option value='14'>14</option>
              <option value='15'>15</option>
              <option value='16'>16</option>
              <option value='17'>17</option>
              <option value='18'>18</option>
              <option value='19'>19</option>
              <option value='20'>20</option>
              <option value='21'>21</option>
              <option value='22'>22</option>
              <option value='23'>23</option>
              <option value='24'>24</option>
              <option value='25'>25</option>
              <option value='26'>26</option>
              <option value='27'>27</option>
              <option value='28'>28</option>
              <option value='29'>29</option>
              <option value='30'>30</option>
              <option value='31'>31</option>
            </select>
            <select name="month" value=''>
    Select Month           
              <option value='01'>January</option>
              <option value='02'>February</option>
              <option value='03'>March</option>
              <option value='04'>April</option>
              <option value='05'>May</option>
              <option value='06'>June</option>
              <option value='07'>July</option>
              <option value='08'>August</option>
              <option value='09'>September</option>
              <option value='10'>October</option>
              <option value='11'>November</option>
              <option value='12'>December</option>
            </select>
            <input type="text" name="year" size="4" value="2011" />
            <label for="date"></label>
            <input type="hidden" name="date" id="date" /></td>
        </tr>
        <tr>
          <td>Start Time</td>
          <td>:</td>
          <td><select name="start_time" id="start_time" >
            <option value="8:45">8:45 AM</option>
            <option value="9:00">9:00 AM</option>
            <option value="9:30">9:30 AM</option>
            <option value="10:00">10:00 AM</option>
            <option value="10:30">10:30 AM</option>
            <option value="11:00">11:00 AM</option>
            <option value="11:30">11:30 AM</option>
            <option value="12:00">12:00 PM</option>
            <option value="12:30">12:30 PM</option>
            <option value="13:00">1:00 PM</option>
            <option value="13:30">1:30 PM</option>
            <option value="14:00">2:00 PM</option>
            <option value="14:30">2:30 PM</option>
            <option value="15:00">3:00 PM</option>
            <option value="15:30">3:30 PM</option>
            <option value="16:00">4:00 PM</option>
            <option value="16:30">4:30 PM</option>
            <option value="17:00">5:00 PM</option>
            <option value="17:45">5:45 PM</option>
          </select></td>
        </tr>
        <tr>
          <td colspan="3" align="center"><input type="submit" name="button" id="button" value="Submit" /></td>
        </tr>
      </table>
    </form>

    kelah_merah wrote:
    ... but I have problem on edit the records. How to get the dropdownlist display the current day,month and year
    I *knew* you´re going to ask this question
    The attached screenshot "screen_update_query" shows how to...
    a) utilize some of MySQL´s Date and Time Functions to extract the day, month and year from a datetime column (here named "col_datetime")
    b) extract the hh:mm via a DATE_FORMAT pattern
    All four information units would be pretty much useless without defining a Column Alias (e.g. AS day)
    The second screenshots shows how to tie the values of one of your dynamic lists (e.g. the list of days) to the respective Column Alias by using the "select value equal to" feature.
    That´s it !

  • Updating a table from two nodes simultaneously using sqlloader- Issues..

    Hi,
    I have a two node RAC. I have a table called PARTS1, has an PK+Index on PART column, Again this has a sequence. Now I am loading data on PARTS1 table using sqlloader from both nodes at the same time. What issues will come?
    Since one column of this table has a PK+Sequence+Index, there will be a contention issue with the block while updating records.. am I right? What other isues might appear here?
    Thanks in advance,
    Lily.

    user7993571 wrote:
    Consider two databases
    db10gA and db10gB which is having a db link from A to B
    There is a user A in db10gA
    and another user B in db10gB
    the user require to insert,update,delete records of user B tables
    so how is the DML privileges are granted to user A to perform these tasks at db10gB database
    whether it is the type of db link decides to do these tasks
    whether any synonym created at db10gA side might help to do the jobUser A will act on behalf of the user who has created the DBLINK; for example if you have created the DBLINK with a user having a DBA role; and grant the DBLINK access to A, A can act on behalf of the DBA who has created the DBLINK.

Maybe you are looking for

  • After update to Mac OS X Lion i cannot burn discs?

    Hello everyone, I recentrly updated my macbook to Lion but after that I just cant burn any disc on itunes. Just when the disc is writting the fourth song i hear the disc stopping and after 30 seconds i get this message>  "the attempt to burn a disc f

  • CS2 and Windows 7

    I have been using CS2 for many years on windows xp - my laptop has now died and I have purchased a new one with Windows 7 but it will not load CS2 - how can I get round this please?

  • Update are showing different languages

    Hi All, I am using SCCM 2012 SP1 in our environment and I have pushed patches and it was nice patching done. but when in am checking in programs and features is showing me that Microsoft report viewer language pack are install in different languages.

  • Events in subpanels

    Hallo, I have B.vi with an event structure. In one of this events A.vi will be opened and showing up its frontpanel. A has also EventStructure. When I click Exit-Button in A.vi the event gets fired, A.vi terminates and returns to B.vi. This is no pro

  • Issue with GregorianCalendar class

    Hi I'm having issues with the GregorianCalender class. I am trying to enable daylight savings time but it doesn't seem to be working properly for. As a test I have taken the difference of time (in milliseconds) between a date where daylight savings c