Having prob in retrieving data

Basically i have 2 tables ...
__TABLE 1:__
COL_NAME COL_VALUE
Name Col_3
Rno Col_2
Class Col_1
__TABLE 2:__
COL_1 COL_2 COL_3
Sharath 111 mca
Sandeep 102 btech
Amar 103 mba
BOTH THE TABLES ARE LINKED.TABLE2 COLUMN NAMES ARE VALUES IN TABLE 1
Now My prob is i want a query that gets COL_VALUE from TABLE1 based on given COL_NAME and get the data from TABLE2 of that value got from TABLE1.

# You need to play really dynamically in building your SQL's if storing metadata inside table. Also this may create problem if metadata is not handled properly
# Below is simple demonostration where you pass your first table col name and we derive the col value for second table and execute SQL to get data from second table
SQL>CREATE TABLE T1
  2  (
  3    COL_NAME  VARCHAR2(10),
  4    COL_VALUE VARCHAR2(10)
  5  );
Table created.
SQL>
SQL>INSERT INTO T1 VALUES ('NAME', 'COL_1');
1 row created.
SQL>INSERT INTO T1 VALUES ('RNO', 'COL_2');
1 row created.
SQL>INSERT INTO T1 VALUES ('CLASS', 'COL_3');
1 row created.
SQL>
SQL>CREATE TABLE T2
  2  (
  3    COL_1  VARCHAR2(10),
  4    COL_2  NUMBER,
  5    COL_3  VARCHAR2(10)
  6  );
Table created.
SQL>
SQL>INSERT INTO T2 VALUES ('Sharath', 111,'mca');
1 row created.
SQL>INSERT INTO T2 VALUES ('Sandeep', 102,'btech');
1 row created.
SQL>INSERT INTO T2 VALUES ('Amar', 103,'mba');
1 row created.
SQL>
SQL>CREATE OR REPLACE PROCEDURE GET_T2_SQL(P_COL_NAME T1.COL_NAME%TYPE, P_RC OUT SYS_REFCURSOR) IS
  2   V_SQL VARCHAR2(32767) := NULL;
  3  BEGIN
  4
  5  SELECT 'SELECT ' || COL_VALUE || ' FROM T2'
  6  INTO V_SQL
  7  FROM  T1
  8  WHERE T1.COL_NAME = P_COL_NAME;
  9
10  OPEN P_RC FOR V_SQL;
11
12  EXCEPTION
13    WHEN NO_DATA_FOUND THEN
14      RAISE_APPLICATION_ERROR(-20001, P_COL_NAME || ' not found in table -T1.COL_NAME');
15  END;
16  /
Procedure created.
SQL>variable RC REFCURSOR;
SQL>EXEC GET_T2_SQL('NAME',:RC);
PL/SQL procedure successfully completed.
SQL>PRINT RC;
COL_1
Sharath
Sandeep
Amar
SQL>EXEC GET_T2_SQL('RNO',:RC);
PL/SQL procedure successfully completed.
SQL>PRINT RC;
     COL_2
       111
       102
       103
SQL>EXEC GET_T2_SQL('CLASS',:RC);
PL/SQL procedure successfully completed.
SQL>PRINT RC;
COL_3
mca
btech
mba
SQL>
{code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

Similar Messages

  • Can we retrieve Data of Single Dimension in multiplecolumns in Excel Add-in

    Hi All,
    I have strange requirement of having single dimension in two columns while retrieving data from essbase using Excel Add-In.
    Logically I feel it is not possible however we are looking if there is any possibilty of work arround for this requirement.
    Whenevr i am trying to retrieve data using a macro on a single column we are able to successfully do it. But in case of multiple columns we are unable to do it.Do let us know if there is any work arround or alternative method to handle this requirement.
    Regards,
    Krishna

    Not completely sure what you mean by "single dimension in two columns". Normally this request comes down to wanting to show multiple levels from a dimension, e.g...
    _______________"Sales"
    "100" "100-10" 12345
    "100" "100-20" 34567...which is definitely not possible.
    If you just mean data like this (with multiple columns from the same dimension)...
    ________"100-10"   "100-20"
    "Sales"  12345      34567...then that should work fine.
    If you could post a sample of what you'd like to see, it would be easier to answer.

  • Retrieve data from a large table from ORACLE 10g

    I am working with a Microsoft Visual Studio Project that requires to retrieve data from a large table from Oracle 10g database and export the data into the hard drive.
    The problem here is that I am not able to connect to the database directly because of license issue but I can use a third party API to retrieve data from the database. This API has sufficient previllege/license permission on to the database to perform retrieval of data. So, I am not able to use DTS/SSIS or other tool to import data from the database directly connecting to it.
    Here my approach is...first retrieve the data using the API into a .net DataTable and then dump the records from it into the hard drive in a specific format (might be in Excel file/ another SQL server database).
    When I try to retrieve the data from a large table having over 13 lacs records (3-4 GB) in a data table using the visual studio project, I get an Out of memory exception.
    But is there any better way to retrieve the records chunk by chunk and do the export without loosing the state of the data in the table?
    Any help on this problem will be highly appriciated.
    Thanks in advance...
    -Jahedur Rahman
    Edited by: Jahedur on May 16, 2010 11:42 PM

    Girish...Thanks for your reply...But I am sorry for the confusions. Let me explain that...
    1."export the data into another media into the hard drive."
    What does it mean by this line i.e. another media into hard drive???
    ANS: Sorry...I just want to write the data in a file or in a table in SQL server database.
    2."I am not able to connect to the database directly because of license issue"
    huh?? I never heard this question that a user is not able to connect the db because of license. What error / message you are getting?
    ANS: My company uses a 3rd party application that uses ORACLE 10g. And my compnay is licensed to use the 3rd party application (APP+Database is a package) and did not purchased ORACLE license to use directly. So I will not connect to the database directly.
    3.I am not sure which API is you are talking about, but i am running an application of the visual studio data grid or similar kind of controls; in which i can select (select query) as many rows as i needed; no issue.
    ANS: This API is provided by the 3rd party application vendor. I can pass a query to it and it returns a datatable.
    4."better way to retrieve the records chunk by chunk and do the export without loosing the state of the data in the table?"
    ANS: As I get a system error (out of memory) when I select all rows in a datatable at a time, I wanted to retrieve the data in multiple phases.
    E.g: 1 to 20,000 records in 1st phase
    20,001 to 40,000 records in 2nd phase
    40,001 to ...... records in 3nd phase
    and so on...
    Please let me know if this does not clarify your confusions... :)
    Thanks...
    -Jahedur Rahman
    Edited by: user13114507 on May 12, 2010 11:28 PM

  • How to retrieve data from a table that match values in a varray?

    Using - Oracle 10g Release 1.2
    How to do write a sql to retrieve data matching values in a varray?
    I have the following:
    declare
        v_ct          NATURAL := 0;
        type t_cur is  REF CURSOR;
        v_cursor t_cur;
        TYPE t_array IS VARRAY(100) OF NUMBER;
        l_codes t_array := t_array();
    begin
        select count(*)
          into v_ct
          from table1
         where ind_cd IS NULL;
        IF v_ct = 0 THEN
            l_codes(1) := 1;
        END IF;
        select count(*)
          into v_ct
          from table2
         where cd IS NULL;
        IF v_ct = 0 THEN
            l_codes(2) := 2;
        END IF;  
       OPEN v_cursor for
          select * from error_table where error_cd in (SELECT * FROM TABLE(CAST(l_codes AS t_array)) );
    end;

    This may not answer your question, but what about a pure SQL solution?
    NOTE THIS IS UNTESTED:
    SELECT *
    FROM     ERROR_TABLE
    WHERE     ERROR_CD IN
              SELECT      1
              FROM      table1
              HAVING      COUNT(*) > 0
              UNION ALL
              SELECT      2
              FROM      table2
              HAVING      COUNT(*) > 0     
         )HTH!

  • How to retrieve data from a web service

    Hi
    i am at very beginner level about web services.
    I am searching for a simple example of retrieving data from a web services, but cant find.
    How can i get xml data from a web service. i dont need to develop the web service it is already ready, i just need how could i fetch data from it.
    Can somebody point out or give an example?
    Thanks in advance

    Hi,
    just create a skeleton for the Web Service. In JDeveloper, create a new project and then use the "NEW" context menu option.
    Navigate to "Business Tier" --> Web Services and select "Web Service Proxy"
    In teh following, provide the WSDL reference to create the Java proxy. This gives you accss to the WS without having to parse the XML yourself
    Frank

  • Troubles to retrieve data from a sharepoint List 2013

    Im having some troubles when i try to retrieve data from a list in sharepoint 2013.
    SPSite osite = new SPSite(@"http://contoso.com");
    SPWeb web = osite.OpenWeb();
    SPList list = web.Lists["Calendar"];
    SPListItemCollection collection = list.Items;
    foreach (SPListItem item in collection)
    Console.WriteLine(item["Title"]);
    And im getting this error: System.InvalidOperationException: Exception of type 'System.InvalidOperationException' was thrown.
    I did a research in MSDN and i could connect to a diferent list in SharePoint 2010 using Visual Studio 2010, but now im using Visual Studio 2012 to connect to SharePoint 2013 and i dont get the same result.
    Im using the DLL Microsoft.SharePoint. 15.0.0.0 
    Thanks!

    I am not able to trace what could be causing the issue, as I would probably need to look at the entire code. But I quickly put together few lines of code and they seem to work for me on SP 2013 as well as 2010. I have modified your code on these lines, can
    you please try the following and let me know if it works:
    SPSite osite = new SPSite("http://contoso.com");
    SPWeb web = osite.OpenWeb();
    string Url = web.ServerRelativeUrl + "/lists/Calendar";
    SPList list = web.GetList(Url);
    SPListItemCollection collection = list.GetItems();
    foreach (SPListItem item in collection)
    Console.WriteLine(item["Title"]);
    The following link talks about the SPList.GetItems method, hope this helps.
    http://msdn.microsoft.com/en-us/library/ms457534(v=office.15).aspx
    Vishal

  • Retrieving data from OBIEE server using ODBC

    Hello.
    I am having difficulty retrieving data from OBIEE 11g using the ODBC connection. My intention is to read OBIEE Server data via a SQL statement issued from an Oracle database using gateways.
    I have read and followed the material here:
    http://download.oracle.com/docs/cd/E14571_01/bi.1111/e16364/odbc_data_source.htm#CACBFCJA
    I have also tried this from Excel 2007, but have not succeeded:
    http://gerardnico.com/wiki/dat/obiee/import_data_from_obiee_to_excel
    I have setup a gateway in Oracle and a database link. Iknow it is connecting because when I change the password to something invalid, I get a message about not being able to connect due to username/password.
    I have taken a query from Answers (the advanced tab) and tried running it from Sql Developer. The nsqserver.log file ends up with the following Notification:
    [nQSError: 13013] Init block, 'DUAL Num (=3)', has more variables than the query select list.
    As an experiment, I am using the SampleApp, and have generated the following query in Answers:
    SELECT s_0, s_1, s_2, s_3 FROM (
    SELECT
    0 s_0,
    "A - Sample Sales"."Products"."P3 LOB" s_1,
    DESCRIPTOR_IDOF("A - Sample Sales"."Products"."P3 LOB") s_2,
    "A - Sample Sales"."Base Facts"."1- Revenue" s_3
    FROM "A - Sample Sales"
    ) djm ORDER BY 1, 2 ASC NULLS LAST
    Is there a way to issue this query from a database client like SQL Developer? I have setup a database link called obiee via gateways to the ODBC connection, and add @obiee after the table name in the above query, but get the nqs error above.
    Thanks for any help. I can provide addl info if such would be useful.
    Ari

    That would explain my difficulty. I went to the link:
    http://download.oracle.com/docs/cd/E14571_01/relnotes.1111/e10132/biee.htm#CHDIFHEE
    that describes the deprecated client. I am confused by the statement there:
    "one of the many widely available third-party ODBC/JDBC tools to satisfy previous NQClient functionality"
    My understanding of ODBC is not very strong, so please bear with me. The statement above is talking about a client tool, but there also needs to be an ODBC driver available for BI Server. I may be a bit confused between driver and client, and what piece nq handles. I don't understand the comment about third-party ODBC when it comes to the driver piece, as that must be coded for BI Server. When I go to create a new DSN, the only driver that makes sense for me to select is:
    Oracle BI Server 11g_OH<id>
    That all works fine to setup a DSN. But I am unable to connect from Excel, etc., using this DSN.
    Put more simply, should I be able to connect to BI Server via ODBC - not using the deprecated BI ODBC client, but using other clients? Is there ODBC connectivity at all in OBIEE 11g?
    Thanks,
    Ari

  • Failed to retrieve data from the database/invalid argument provided when employing link between two web services datasources

    Post Author: vpost
    CA Forum: Data Connectivity and SQL
    I am trying to join information from two related web services within CR XI. I have successfully set up the web services as data sources have been able to get to the point where I get good data back. However, when I try to pull in certain fields, I get an error that says "Failed to retrieve data from the database/invalid argument provided". Here's the scenario:
    The web services are structured as follows:Web Service 1 (Artist) has attributes of Artist Name and Date of Birth.Web Service 2 (CD) has attributes of CD Title and Release Date. Underneath each CD are songs, each of which have a Song Title and Artist Name.
    I have defined both web services and defined a link between Artist.Artist Name and CD/Song.Artist Name. I am able to run a report with Song Title and Date of Birth that crosses web services. I am able to run another report with Song Title and CD Title that crosses the different levels in the second web service. However, if I add CD Title to the first report or Date of Birth to the second (both of which effectively force CR to employ the link between the two web services AND the CD/Song hierarchical structure in the second web service, I get the aforementioned error.
    Any assistance understanding how multiple web services can be linked in this manner would be greatly appreciated.
    Thanks in advance.

    Post Author: Mike Wright
    CA Forum: Data Connectivity and SQL
    Not sure about your exact situation, but having similar problem with another application and have tracked down to security. Added user to group Domain Admin and it works fine. It appears to be accessing a subdirectory which it does not have permission to use and then times out and returns the "invalid....". Seems that once the query just over a certain size (and I'm not sure what triggers this) it needs to make use of temparory file disk, intead of ram.
    I'm still trying to track down which temporary it's trying to uses - so if you have any ques.
    cheers

  • Failed to retrieve data from the database.DB Vendor Code 156

    Hi,
    We recently migrated our scheduled Crystal Reports from BO XI R2 platform to BO XI 3.1, and are having issues with select reports that pull from the same SQL database.  The tables and fields exist in the database - and I ran the SQL in a different tool and the syntax is correct.  When I try to run an on-demand or schedule one of these reports in 3.1 Infoview I receive the following error:
    Failed to retrieve data from the database. Details: [Database Vendor Code: 156 ]
    Running:
    CR 2008 SP2
    BO XI 3.1 SP2 (FP 2.7)
    Please advise!  Thanks!

    Hi LuAnn,
    Not really clear what he said but I believe this is correct. The BOE servers are typically running under the local System Account. So when it passed the report job from the BOE Server it is the Local System account that the database is getting. We only do single hop for security. Which means if you are logged into InfoView under your local domain account and try to run a report BOE will not, unless specified in the custom database connection options in the CMC, pass your credentials to the DB but will pass the local system account credentials which is likely why these reports are failing.
    As A TEST only Ask your Administrator to set up a user account in MS SQL Server that has rights to run all reports. Or when you create the report check on the option to use Trusted Authentication. Then when the reports are published to BOE your log on credentials should get passed to the DB server through BOE.
    You'll have to more testing to find a Use account that you can run BOE Servers under and still maintain DB security and report level security that works for you. I also suggest you post your security questions to the BOE Administrator forum to get help configuring all of this and what others are doing.
    Thank you
    Don

  • Failed to retrieve data from the database when adding jdbc datasource

    I'm having problems adding some tables to the selected tables list using the database expert.
    I get the error messages "Failed to retrieve data from the database" followed by "Unknown Database Connection Error".
    I thought it may be a permissions issue as it only affects some tables, but I can access the same tables fine using the same user through Oracle SQL Developer.
    The database is Oracle 10g Express Editions
    Crystal version is 12.0.0.683
    Running on Windows XP
    Any suggestions would be much appreciated.

    Hi Stuart
    Please refer SAP note 1218714 for this issue. The link to this article ia as follows:
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes/sdn_oss_boj_erq/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes%7B6163636573733d36393736354636443646363436353344333933393338323636393736354637333631373036453646373436353733354636453735364436323635373233443330333033303331333233313338333733313334%7D.do
    You can search for this note on the SDN site.
    Hope this helps.
    Thanks!

  • Failure to retrieve data from the database (Vendor Code 6550)

    I am having a trouble with two of the 6 reports that I have created. I am using Crystal XI and Oracle 10g. The underlying database object is a stored procedure that accepts as input a start time as a TIMESTAMP, an end time as a TIMESTAMP and a furnace number as a number. I have a cursor ref as a return parameter.
    When I run the stored procedure in Oracle I get the selected records and can view them on the screen.
    When I refresh data on the report in Crystal XI developer, the designer asks me for the start and end time and furnace number. When I input these values the report displays properly.
    When I launch the report from my VB .NET 2005 application I am asked for the username and the password for the database (this is another problem I need to solve as this information I put into the program seems to be ignored in my program) then I receive the following failure message:
    Failure to retrieve data from the database (Vendor Code 6550)
    When I launch the other reports, they only ask me for the username and password then they display the proper data.
    The main difference between my other reports and the two that are returning the above failure code is that the other reports are to either tables or views. The two that don't work are tied to stored procedures. I there any way that I can solve this problem or at least get more information?
    Any help would be greatly appreciated. Let me know if you need any other information.

    I have a similar problem, the only difference is that the crystal report error is only thrown when I try to load the sub reports at my web application. When I deploy my report to the Web application the main report loads up fine but when I try to launch the sub reports from the main report it can no longer load.
    But when I use the Crystal report developer I am able to load the main report and it's associated sub reports without any issues.
    My issue only occurs when I try to load the sub report in the web application. The following sections shows how my reports look like both in my .NET web application and also at the Crystal Report Development IDE.
    Failure: Loading my Reports from .NET Web Application
    1) When I load from the web application I am able to load the main report as per the print screen below.
    2) When I try to click on the hyper links to enter the sub reports I am now able to load them, both sub reports cannot load and will throw the same error "
    Failed to retrieve data from the database. Details: [Database Vendor Code:
    6550 ] Failed to retrieve data from the database. Details: [Database Vendor
    Code: 6550 ] Failed to retrieve data from the database. Error in File OAWR3011A
    {CEC8A94A-4490-4640-95FB-2739A679978B}.rpt: Failed to retrieve data from the
    database. Details: [Database Vendor Code: 6550 ] "
    Success: Loading my Reports from Crystal Report Development Tool
    1) This is my Main Report Loaded from the Crystal Report Development Tool, the first two hyperlinked fields are links to my sub reports, step number 2 and number 3 shows my sub reports when I load it using Crystal Report Developer
    2) Sub Report 1 Loaded Successfully, when I click on the fields in the first link
    3) Sub Report 2 loaded successfully when I click the second field hyper link

  • Error retrieving data from the web server in Excel fo BPC

    Hello Everybody,
    I'm working with BPC v7.5 , i created some reports with the EVDRE formula and they were working perfectly.
    The problem started when i created new users, that in fact have the same access profile and task profile as my user.
    i started to test these new users in excel and every time i expand the report this legend appears: " EVDRE Retrying... EVDRE encountered an error retrieving data from the Web Server. Retrying in (X) Seconds...". After waiting a while a push cancel, then appears a window with the legend: Ev4excel Addin, Errors found retriening data.
    The funny thing is that when i login back to my user everything works fine again, any idea what could be the problem? the other user have the same permissions.
    Thanks a lot in advance!!
    Nidia Olguí

    very strange. Normally the member access profile must be diifferent. So it is not important the task profile but the member access profile. Can you please double check ?
    If you are doing a simple EVDRE with users having problems is it working or you still have problems?
    Regards
    Sorin Radulescu

  • I'm having probs backing up iPhone 5 to iCloud - just sits on the backing up screen with message 'estimated time remaining....' But goes no further and doesn't back up - wifi is fine and definitely enough storage spaces. Anyone have any ideas plea

    I'm having probs backing up iPhone 5 to iCloud - just sits on the backing up screen with message 'estimated time remaining....' But goes no further and doesn't back up - wifi is fine and definitely enough storage spaces. Anyone have any ideas please?

    You might try a forced shutdown to begin with, hold down the top and home buttons together until the device shuts down, then restart it.
    First check that your device is correctly connected to the wifi/internet (settings > wifi)
    If your back up continually fails, you might try turning off back up on your mobile device (settings > iCloud > storage & backup) and then deleting the backup file from iCloud by swiping the backup file on the mobile device (settings > iCloud > storage & backup > manage…) and then turning back up on again.
    If this doesn't help, try turning off some items for back up in a pattern to try to establish if your problem is being caused by specific data on your device.
    Being able to back up to the cloud can be very useful, especially if you don't have access to a computer or have infrequent access to one, however unless you specifically need to use iCloud for back up, you will find backing up to iTunes significantly more convenient and possibly more reliable.
    More about iCloud v iTunes Back Up

  • Retrieve data from datagrid

    Hi people,
    Currently I trying to create a datagrid that allows user to see the overview data. And the datagrid allow the user to click and a popup will show a more detail information of the data
    But I'm having problem to retrieve the id of the data first. I've managed to create a click event to allow the user to click a specific data and shows popup.
    I need help regarding this. Thanks
    -ExpertDiscoverySystem.mxml-
                [Bindable]
                public var dataid:String;
                private function onItemClick( e:ListEvent ):void {
                //    currentState='SearchName';
                    //add popup here, then try to transfer a certain field to display all the required data
                titleWindow = PopUpManager.createPopUp(this, component.DataDetail, true) as TitleWindow;
                PopUpManager.bringToFront(titleWindow);
                var dataid:String = e.currentTarget.selectedTarget.id;
    <mx:Panel width="1169" height="558" layout="absolute" title="Datagrid" x="48.7" y="171.65" includeIn="SearchResult">
            <mx:Label horizontalCenter="0" y="1" text="Results"
                      fontSize="16" fontWeight="bold"/>
            <mx:DataGrid id="dgPeeps" width="1141" height="487" selectedIndex="0" showHeaders="false" x="16.6" y="24" creationComplete="dgPeeps_creationCompleteHandler(event)" itemClick="onItemClick(event);" dataProvider="{getContentForAllResult.lastResult}">
                <mx:columns>
                    <mx:DataGridColumn dataField="img" itemRenderer="component.image"/>
                    <mx:DataGridColumn headerText="name" dataField="name" />
                    <mx:DataGridColumn headerText="department" dataField="department"/>
                    <mx:DataGridColumn headerText="expert" dataField="expert"/>
                    <mx:DataGridColumn headerText="project" dataField="project"/>
                    <mx:DataGridColumn dataField="id"/>
                </mx:columns>
            </mx:DataGrid>
        </mx:Panel>
    -DataDetail.mxml- The popup component
    <?xml version="1.0" encoding="utf-8"?>
    <s:TitleWindow xmlns:fx="http://ns.adobe.com/mxml/2009"
             xmlns:s="library://ns.adobe.com/flex/spark"
             xmlns:mx="library://ns.adobe.com/flex/mx" width="700" height="600" backgroundColor="#000000" backgroundAlpha="0.70" close="titleWindow_close(event)" xmlns:services="services.*">
        <fx:Declarations>
            <s:CallResponder id="getSpecificResultResult"/>
            <services:ExpertSearchManager id="expertSearchManager" fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)" showBusyCursor="true"/>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <fx:Script>
            <![CDATA[
                import mx.controls.Alert;
                import mx.core.FlexGlobals;
                import mx.events.CloseEvent;
                import mx.events.FlexEvent;
                import mx.managers.PopUpManager;
                [Bindable]
                private function titleWindow_close(evt:CloseEvent):void {
                    PopUpManager.removePopUp(this)
                protected function dataGrid_creationCompleteHandler(event:FlexEvent):void
                    //change the below to dynamic 
                    var dataid:String;
                    dataid = FlexGlobals.topLevelApplication.id;
                    getSpecificResultResult.token = expertSearchManager.getSpecificResult(dataid);
            ]]>
        </fx:Script>
        <mx:Image x="10" y="10" width="67" height="67"/>
        <s:Label x="85" y="10" text="Label" color="#FFFFFF"/>
        <s:Label x="125" y="10" text="Label" color="#FFFFFF"/>
        <s:Label x="85" y="30" text="Age" color="#FFFFFF"/>
        <s:Label x="114" y="30" text="Label" color="#FFFFFF"/>
        <mx:HRule x="0" y="109" width="697"/>
        <mx:HRule x="0" y="256" width="698"/>
        <mx:VRule x="256" y="114" height="141"/>
        <s:Label x="10" y="119" text="Social Network" color="#FFFFFF" fontWeight="bold" fontSize="14"/>
        <s:Label x="10" y="270" text="Relationship" color="#FFFFFF" fontWeight="bold" fontSize="14"/>
        <s:Label x="270" y="119" text="Skills" color="#FFFFFF" fontWeight="bold" fontSize="14"/>
        <mx:Image x="4" y="151" source="images/twitter.gif" width="85" height="21"/>
        <mx:Image x="6" y="199" source="images/facebook.jpg" width="85" height="21"/>
        <s:Label x="99" y="160" text="Label" color="#FFFFFF"/>
        <s:Label x="99" y="208" text="Label" color="#FFFFFF"/>
        <mx:DataGrid x="283" y="376" id="dataGrid" creationComplete="dataGrid_creationCompleteHandler(event)" dataProvider="{getSpecificResultResult.lastResult}">
            <mx:columns>
                <mx:DataGridColumn headerText="id" dataField="id"/>
                <mx:DataGridColumn headerText="expert" dataField="expert"/>
                <mx:DataGridColumn headerText="project" dataField="project"/>
                <mx:DataGridColumn headerText="searchTerm" dataField="searchTerm"/>
                <mx:DataGridColumn headerText="searchCriteria" dataField="searchCriteria"/>
                <mx:DataGridColumn headerText="department" dataField="department"/>
                <mx:DataGridColumn headerText="name" dataField="name"/>
                <mx:DataGridColumn headerText="img" dataField="img"/>
            </mx:columns>
        </mx:DataGrid>
    </s:TitleWindow>

    Hi,
    I've followed your instruction, everything seems fine expect encountering this error at my Problem tag
    1119: Access of possibly undefined property _dataid through a reference with static type mx.containers:TitleWindow.
    Thanks
    Let me just paste the full code here
    -ExpertDiscoverySystem.mxml-
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="1280" minHeight="960" xmlns:component="component.*" xmlns:services="services.*" currentState="SearchStart">
        <s:layout>
            <s:BasicLayout/>
        </s:layout>
        <fx:Style source="style/datagrid.css"/>
        <!--<fx:Style source="/style/style.css"/>-->
        <fx:Script>
            <![CDATA[
                import component.Window;
                import mx.containers.TitleWindow;
                import mx.controls.Alert;
                import mx.controls.dataGridClasses.DataGridColumn;
                import mx.events.FlexEvent;
                import mx.events.ListEvent;
                import mx.managers.PopUpManager;
                import mx.utils.object_proxy;
                import spark.layouts.RowAlign;
                private var titleWindow:TitleWindow;
                /* Pop up for search again */
            /*     private function popUp():void {
                titleWindow = PopUpManager.createPopUp(this, component.Window, true) as TitleWindow;
                PopUpManager.bringToFront(titleWindow);} */
                protected function dgPeeps_creationCompleteHandler(event:FlexEvent):void
                    getContentForAllResult.token = expertSearchManager.getContentForAll();
                private function getResultName():void {
                    if (searchNameText.text == ""){
                        Alert.show("You didn't enter any search term", "Error");
                    else{
                        currentState='SearchResult';
                private function getResultDomain():void {
                    if (searchDomainText.text == ""){
                        Alert.show("You didn't enter any search term", "Error");
                    else{
                        currentState='SearchResult';
                private function onRefresh():void
                    var ref:URLRequest = new URLRequest("javascript:location.reload(true)");
                    navigateToURL(ref,"_self");
                private function onItemClick( e:ListEvent ):void {
                var dataid:String = (e.currentTarget as DataGrid).selectedItem.id;
                //add popup here, then try to transfer a certain field to display all the required data
                titleWindow._dataid = dataid;   
                titleWindow = PopUpManager.createPopUp(this, component.DataDetail, true) as TitleWindow;
                PopUpManager.bringToFront(titleWindow);
                //var dataid:String = (e.currentTarget as DataGrid).selectedItem.id;
                trace(dataid);
                //testPop();
            ]]>
        </fx:Script>
        <s:states>
            <s:State name="SearchName"/>
            <s:State name="SearchDomain"/>
            <s:State name="SearchResult"/>
            <s:State name="SearchStart"/>
        </s:states>
        <fx:Declarations>
            <s:CallResponder id="getContentForAllResult"/>
            <services:ExpertSearchManager id="expertSearchManager" fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)" showBusyCursor="true"/>
        </fx:Declarations>
        <mx:Image x="0" y="0" includeIn="SearchDomain,SearchName,SearchStart" source.SearchName="images/background.jpg" source.SearchDomain="images/background.jpg" source.SearchStart="images/background.jpg"/>
        <s:Label x="411.05" y="455.05" text="a Domain" fontSize="36" includeIn="SearchDomain"/>
        <mx:LinkButton label="Name" fontSize="36" fontFamily="Verdana" includeIn="SearchStart" click="currentState='SearchName' " color="#CE1717" enabled="true" x="422.95" y="544.5" fontWeight="bold"/>
        <mx:LinkButton fontSize="36" fontFamily="Verdana" click="currentState='SearchDomain'" includeIn="SearchStart" color="#CC1C1C" label="Domain" x="695.95" y="543.5" fontWeight="bold"/>
        <mx:Image includeIn="SearchResult" x="0" y="0" source="images/backgroundsearch.jpg"/>
        <s:Button includeIn="SearchResult" x="1179" y="61.1" label="Search other" id="SearchAgainButton" color="#DD0A0A" click="onRefresh()"/>
        <!--<s:Button includeIn="SearchName" x="747" y="504" label="Search" id="searchNameButton" click="currentState='SearchResult'"/>-->
        <s:Button includeIn="SearchName" x="747" y="504" label="Search" id="searchNameButton" click="getResultName()"/>
        <s:TextInput includeIn="SearchName" x="164" y="504" width="561" id="searchNameText"/>
        <s:Button includeIn="SearchDomain" x="747" y="504" label="Search" id="searchDomainButton" click="getResultDomain()"/>
        <s:TextInput includeIn="SearchDomain" x="164" y="504" width="561" id="searchDomainText"/>
        <s:Label includeIn="SearchResult" x="721" y="119" fontSize="25" id="SearchedTermLabel" text="{searchNameText.text}" fontWeight="bold" color="#D60D0D"/>
        <s:Label includeIn="SearchResult" x="725" y="119" fontSize="25" id="SearchedTermLabel2" text="{searchDomainText.text}" fontWeight="bold" color="#D80B0B"/>
        <s:Label includeIn="SearchResult" x="389" y="119" text="You've searched for the term:" fontSize="25" color="#FFFFFF"/>
        <s:Label includeIn="SearchName" x="411.05" y="455.05" text="a Name" fontSize="36"/>
        <mx:Panel width="1169" height="558" layout="absolute" title="Datagrid" x="48.7" y="171.65" includeIn="SearchResult">
            <mx:Label horizontalCenter="0" y="1" text="Results"
                      fontSize="16" fontWeight="bold"/>
            <mx:DataGrid id="dgPeeps" width="1141" height="487" selectedIndex="0" showHeaders="false" x="16.6" y="24" creationComplete="dgPeeps_creationCompleteHandler(event)" itemClick="onItemClick(event);" dataProvider="{getContentForAllResult.lastResult}">
                <mx:columns>
                    <mx:DataGridColumn dataField="img" itemRenderer="component.image"/>
                    <mx:DataGridColumn headerText="name" dataField="name" />
                    <mx:DataGridColumn headerText="department" dataField="department"/>
                    <mx:DataGridColumn headerText="expert" dataField="expert"/>
                    <mx:DataGridColumn headerText="project" dataField="project"/>
                    <mx:DataGridColumn dataField="id"/>
                </mx:columns>
            </mx:DataGrid>
        </mx:Panel>
    </s:Application>
    -datadetail.mxml-
    <?xml version="1.0" encoding="utf-8"?>
    <s:TitleWindow xmlns:fx="http://ns.adobe.com/mxml/2009"
             xmlns:s="library://ns.adobe.com/flex/spark"
             xmlns:mx="library://ns.adobe.com/flex/mx" width="700" height="600" backgroundColor="#000000" backgroundAlpha="0.70" close="titleWindow_close(event)" xmlns:services="services.*">
        <fx:Declarations>
            <s:CallResponder id="getSpecificResultResult"/>
            <services:ExpertSearchManager id="expertSearchManager" fault="Alert.show(event.fault.faultString + '\n' + event.fault.faultDetail)" showBusyCursor="true"/>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
        <fx:Script>
            <![CDATA[
                import mx.controls.Alert;
                import mx.core.FlexGlobals;
                import mx.events.CloseEvent;
                import mx.events.FlexEvent;
                import mx.managers.PopUpManager;
                private function titleWindow_close(evt:CloseEvent):void {
                    PopUpManager.removePopUp(this)
                public var _dataId:String;
                protected function dataGrid_creationCompleteHandler(event:FlexEvent):void
                    //change the below to dynamic 
                    var dataid:String;
                    dataid = _dataId;
                    getSpecificResultResult.token = expertSearchManager.getSpecificResult(dataid);
            ]]>
        </fx:Script>
        <mx:Image x="10" y="10" width="67" height="67"/>
        <s:Label x="85" y="10" text="Label" color="#FFFFFF"/>
        <s:Label x="125" y="10" text="Label" color="#FFFFFF"/>
        <s:Label x="85" y="30" text="Age" color="#FFFFFF"/>
        <s:Label x="114" y="30" text="Label" color="#FFFFFF"/>
        <mx:HRule x="0" y="109" width="697"/>
        <mx:HRule x="0" y="256" width="698"/>
        <mx:VRule x="256" y="114" height="141"/>
        <s:Label x="10" y="119" text="Social Network" color="#FFFFFF" fontWeight="bold" fontSize="14"/>
        <s:Label x="10" y="270" text="Relationship" color="#FFFFFF" fontWeight="bold" fontSize="14"/>
        <s:Label x="270" y="119" text="Skills" color="#FFFFFF" fontWeight="bold" fontSize="14"/>
        <mx:Image x="4" y="151" source="images/twitter.gif" width="85" height="21"/>
        <mx:Image x="6" y="199" source="images/facebook.jpg" width="85" height="21"/>
        <s:Label x="99" y="160" text="Label" color="#FFFFFF"/>
        <s:Label x="99" y="208" text="Label" color="#FFFFFF"/>
        <mx:DataGrid x="90" y="315" id="dataGrid" creationComplete="dataGrid_creationCompleteHandler(event)" dataProvider="{getSpecificResultResult.lastResult}" width="542" height="96">
            <mx:columns>
                <mx:DataGridColumn headerText="id" dataField="id"/>
                <mx:DataGridColumn headerText="expert" dataField="expert"/>
                <mx:DataGridColumn headerText="project" dataField="project"/>
                <mx:DataGridColumn headerText="searchTerm" dataField="searchTerm"/>
                <mx:DataGridColumn headerText="searchCriteria" dataField="searchCriteria"/>
                <mx:DataGridColumn headerText="department" dataField="department"/>
                <mx:DataGridColumn headerText="name" dataField="name"/>
                <mx:DataGridColumn headerText="img" dataField="img"/>
            </mx:columns>
        </mx:DataGrid>
    </s:TitleWindow>

  • Retrieving data from Microsoft Access using JDBC

    I noticed that when i tried retrieving data from Microsoft access using JDBC, I realised that it was throwing SQLException when the column names were two word with spaces between them, e.g. Date Birth. But after i removed the space from the column names, my SQL queries were retrieving data. Was it because of the space in between the column names of the table?

    Yeah, as far as I know having two word column names isn't allowed in SQL. There might be some way to escape it, but generally it's sensible to avoid it.

Maybe you are looking for

  • How to debug XSLT in BPEL

    Hello, I am getting issue in BPEL code while executing XSLT file. If I have performed the 10 mappings in XSLT file and one of them has error in assigning source to target values. Its just mentioned that following XSLT file has error and doesn't menti

  • The lock symbol does not appear when I open a secure page in firefox 4.0. Has this been removed?

    Previously, using firefox 3.6.1, when I opened a secure or encrypted page, the lock icon appeared on that page. When I upgraded to firefox 4.0, the lock icon is no longer appearing when I open a secure page. Please confirm whether this has been remov

  • Pricing Procedure to be configured for calculating excise

    Hello , I have new pricing procedure to be configured for calculating excise on base value , the procedure is as under Base Price                              -                    X  Amount Surface transport                    -                Y  Amo

  • 10.4.3 Causes ethernet port to stop functioning after a while

    Every since updating to 10.4.3, it seems that my PM G5 has to be restarted in order to connect back to my router. Apparently my situation is similar to http://discussions.apple.com/click.jspa?searchID=-1&messageID=726998 . The solution suggested ther

  • Why does my iMac shut down before it can boot up After installing 7.3 update on my iMac?

    After installing 7.3 last night, I hit restart and went to bed.  My intel iMac i7 3.4ghz was powered down this morning, and only after unplugging,waiting, rep plugging, It finally powered on, only to boot to the gray apple screen, go black and silent