Data retrieve from tables in two diff schema in same db

hi,
i have one db and name is HWRDB, in this i have two schema PRLHEEP and PRLCFFP.
in PRLHEEP my table is NAMAS, and in PRLCFFP also table's name is NAMAS.
i want
if :unit = 'H' then
-- connect to PRLHEEP
select data into some items from NAMAS
eslif :unit = 'C' then
-- connect to PRLCFFP
select data into some items from NAMAS
endif;
plz help me to connect to schema. *** db is oracle db, 10g version***

here is my code,
if :deloan.unit = 'H' then
....... select nmodpay,nbnkacc
.......into modpay, bnkacc
.......from namas where nstfno = :deloan.stfno;
.......select some colums
.......into some items
.......from pafac
....... where pstfno = :deloan.stfno and
elsif :deloan.unit = 'C' then
....... select nmodpay,nbnkacc
.......into modpay, bnkacc
....... from prlcffp.namas where nstfno = :deloan.stfno;
.......select some colums
....... into some items
....... from prlcffp.pafac
.......where pstfno = :deloan.stfno and
in forms builder, i connect to prlheep
when i compile i get errors:
identifier *'PRLCFFP.NAMAS'* must be declared
identifier *'PRLCFFP.PAFAC'* must be declared

Similar Messages

  • Data Retrieval from SSRS 2008 R2 to SQL Server 2012 standard

    Hello,
    We have a virtual machine running SSRS 2008 R2 and a physical server running SQL server 2012 standard.  We are having an issue with a report that is taking almost 10 minutes for the data to be retrieved from the sql 2012 database.  We used the
    execution logging query to debug and analyze.  We see that it renders and processes very fast, but the data retrieval time is very slow.  When the same query is run using sql studio mgr. from the SSRS server it runs just fine...it
    takes seconds for the results to come up.
    I don't believe there is a compatibilty issue because other reports run fine.  We're just having problems with one report.

    A long shot, but I've seen where the data type of a report parameter is mismatched against the data type of the table it is being compared against.  SQL profiler would show this clearly.  
    This would explain why the query returns quickly in ssms but not with the report.  

  • Joining two tables in two different schema

    Hi All,
    I have a requirement to join two tables in two different schema. How to join these two tables in view object.
    Many thanks in advance.
    Regards
    Kaushik Gopalakrishnan

    1) If these tables are in one and same database instance, then you can join them by specifying the fully-qualified table names (inlcuding the schema name), for example:
    SELECT ...
    FROM schema_A.table1 T1, schema_B.table2 T2
    WHERE T2.parent_code = T1.code
         AND ...2) If the tables are in different database instances, then you can create a database link in one of the databases and access the table from the other database via the DB link, for example:
    SELECT ...
    FROM schema_A.table1 T1, schema_B.table2@mydblink T2
    WHERE T2.parent_code = T1.code
         AND ...3) If the tables are in different database instances and there is no option for DB links, then you cannot join the tables in an ADF ViewObject.
    Dimitar

  • Tell me how to format a date retrieved from a MS SQL Server 2000 database?

    Tell me how to format a date retrieved from an MS SQL Server 2000 database for various uses in my JSP page?

    Or if you want to use JSTL instead of a scriptlet see:
    http://forum.java.sun.com/thread.jspa?threadID=676754&tstart=0

  • Data retrieve from one table control to another table control

    Hi all,
    I had an requirement like to create Two table controls.
    for first Table control i had an sel field defined as 'MARK'.
    when i check the row in the first table control think it  is header data for sales order .
    all the item details have to retrieve in the second table control.
    This is my requirement, i am not able to trigger when selecting the row in table control.
    will anybody had an experience like this.
    Regards,
    Madhavi

    Hi Madhavi,
    If  we need the case to display header and item as mentioned in 2 table controls....
    we can display in table control 2/item only (the line items of the one selected in the table control 1 or the header )...so ,at a time we need to display line items for only 1 header ....
    so ...first disable the selections/multiple selections to disable the row selector
    We have already declared a field type C to capture the value for the field selector...so we can convert this field to a radio button and then assign a function code to the radio button at screen level
    Whenever you click on the radio button ..immediately the function code is triggered..then in PAI ..we can check and find the header record with 'X' and populate the data for the table control 2
    Hope it helps
    Regards
    Byju

  • Data retrieval from 8 db tables

    Hi Folks,
    We haev a requirement where we need to query 7 tables to retrieve some data and display it in the form of a list.
    This report is to be executed in background.
    Right now we have 3 select statements, each of which has inner joins on 2-3 tables and uses "for all entries".
    Performance wise which would be a better option - to keep it this way, or have separate select statement for each table and then read statements on internal tabels for output?
    Thanks in advance,
    Munish

    Hi,
    I think it depends on the balance between ABAP time and Database time.
    If you select all the data from tables independently and then do looping etc,
    it will increase the hits as well as the ABAP time.
    So the next best option is a mix of both. I believe the current approach holds good.
    As, has been mentioned before also in this thread, you can improve the performance if the joins are being made on key fields since this reduced overhead.
    If I were using tables which had all been joined with key fields I would have gone as high as with 5 Joins but I guess this is an ideal scenario so a join of 2-3 tables is a decent approach.
    And the subsequent handling in ABAP is the only next step.
    So this approach is fine and you should incorporate correct performance guidelines which you can find in this forum if you search for them.
    Regards
    Nishant

  • Data retrieval from ZL table

    I need to retrieve data from ZL table and prepare a report comparing the Actual, Previous and Old records in the table for an employee for a particular period.
    Are there any particular function modules for this data retrieval?
    Thanks.

    Hi bala,
    I did not get what you were trying to tell me. I went to SE37 and tried for anything that starts with "zlit" .. but returned no results.
    And also I dont want time management to payroll.
    I want to retrieve data from the B2 in PCL2 cluster.
    i.e I want to retrieve data from the ZL table in the cluster for a particular payperiod and particular employee.
    Thanks very much in advance!

  • Saving data retrieved from text file to JDBC table

    Hi,
    I would like to save data, loaded from a text file to a dataset, into an existing JDBC table.
    The documentation I found on this subject is very brief, and no matter how I tried, I couldn't succeed.
    I would appreciate any help.
    Thank you in advance

    Hi there,
    Here is an example of reading a String and a date from a text file. Once you have what you need in the Strings (or whatever) it should be easy to insert them into and SQL statement. Let me know if you need an example of this as well and I'll post it in the morning. Right now I'm off to bed :o)
    Cheers
    Mark
    import java.io.*;
    import java.util.*;
    import java.text.*;
    public class WriteTest {
    public static void main(String [] arg) throws Exception {          
       Date today = new Date();          
       String name = "";          
       SimpleDateFormat formatter = new SimpleDateFormat("ddMMyyyy");          
       File myfile = new File("hello.txt");               
       // how to input     
       BufferedReader in = new BufferedReader(new FileReader(myfile));          
       String name="",
       date="";          
       boolean eof = false;          
       do {
          name = in.readLine();               
          date = in.readLine();               
          if(!(eof = (name==null || date==null)))                    
          System.out.println(name+" "+formatter.parse(date));
       while(!eof);     
    }

  • Fast data retrieval from large tables

    Hello,
    we have created a table in oracle 10g DB. at an average there are around 20-30 rows inserted onto the table. so in 1 mnth the record count for the table is around 800-900 rows.
    in one year which is becoming to 10,000 rows. so speed up data retreval from this bulk data we need suggestion. various things that come to my mind are -
    Indexing of table/# Index of table/partitioning of table/materialized view etc.
    but not sure what exactly needs to be done here. please suggest on how smooth data retreival can be chaived whatever be the size of the table.
    Thanks,
    Sam

    Here is a simple look of your data progression.
    year        Row
    1           10,000
    5           50,000
    10          1,00,000
    50          5,00,000
    100         10,00,000You need to wait another 100 years to reach a million. And million is not a big number when it comes to Oracle.
    So as others have stated what the objective behind your question?
    basically the choice of Index or Partition mainly depends on how the data is going to be accessed from a table. If I am going to access all the rows of a table every time then there is no use of both the features. I would just prefer a FTS. In that situation i would be looking how to optimize my FTS.
    So you need to set you objective clear before picking up the solution. Just because you have a hammer you cant go around banging the wall ;)

  • Sinlge select query in diff schemas for same table(Indentical Structure)

    Scenario :
    Table XYZ is created in Schema A
    After an year, the old data from the previous year would be moved to different schema. However in the other schema the same table name would be used.
    For eg
    Schema A contains table XYZ with data of 2012 yr
    Schema B contains table XYZ with data of 2011 yr
    Table XYZ in both the schemas have identical structure.
    So can we fire a single select query to read the data from both the tables in effective way.
    Eg select * from XYZ where date range between 15-Oct-2011 to 15-Mar-2012.
    However the data resides in 2 different schema altogether.
    Creating an view is an option.
    But my problem, there is ORM layer(either Hibernate or Eclipse Top Link) between the application and the database.
    So the queries would be formed by the ORM layer and are not hand generated.
    So i cannot use view.
    So is there any option that would allow me to use single query on different schema's ?

    Hi,
    970773 wrote:
    Scenario :
    Table XYZ is created in Schema A
    After an year, the old data from the previous year would be moved to different schema. However in the other schema the same table name would be used.
    For eg
    Schema A contains table XYZ with data of 2012 yr
    Schema B contains table XYZ with data of 2011 yr
    Table XYZ in both the schemas have identical structure.
    So can we fire a single select query to read the data from both the tables in effective way.That depends on what you mean by "effective".
    Eg select * from XYZ where date range between 15-Oct-2011 to 15-Mar-2012.
    However the data resides in 2 different schema altogether.You can do a UNION, so the data from the two years appears together. The number of actual tables may make the query slower, but it won;t change the results.
    Given that you have 2 tables, the fact that they are in different schemas doesn't matter. Just make sure the user running the query has SELECT privileges on both of them.
    Creating an view is an option.Is it? You seem to say it is not, below.
    But my problem, there is ORM layer(either Hibernate or Eclipse Top Link) between the application and the database.
    So the queries would be formed by the ORM layer and are not hand generated.
    So i cannot use view.So creating a view is not an option. Or is it?
    So is there any option that would allow me to use single query on different schema's ?Anything that you can do with a view, you can do with sub-queries. A view is merely a convenience; it just saves a sub-query, so you don't have to re-code it every time you use it. Assuming you have privilges to query the base tables, you can always avoid using a view by repeating the query that defines the view in your own query. It will not be any slower

  • Can I use stored procedures to improve data retrieval from the database?

    I have been requested to get multiple pieces of data from multiple tables and return the output in an array for use in a Java program.
    Eliminating multiple calls to the database. Currently, the data is retrieved from the database in multiple steps but to eliminate
    possible bottlenecks in the future, I created several complex sql statements.
    For instance,
    In the first table there are 20 columns of data. has a column named type which can have the one of these values: line, inn, or bsc
    In the second table there are 6 columns of data. has the additional data for type line
    In the third table there are 7 columns of data. has the additional data for type inn
    In the fourth table there are 2 columns of data. has data regardless of type
    etc...
    Depending on a specific column value retrieved (inn) from the first table:
    I need to collect all 20 columns in the first table and get all the columns in third table and the columns in the fourth table, etc.
    Question: How can I remove the duplicate primary key columns without specifying for each table the column names to be returned?
    I used the wildcard SELECT * because I didn't want to have to update the retrieval methods if additional columns are added to these
    secondary tables.
    example of my sql for type inn data:
    select * from first_table f, third_table s, fourth_table t
    where (f.column1='xxxx' and f.column2='xxxx') (the 'xxxx' are passed into the sql statement)
    and
    ((s.column1=f.column1 and s.column2=f.column2)
    and
    (f.column3=t.column1));
    Currently, I've duplicated the separate sqls for each valid type found in the first table (at least a dozen types). The only difference is
    the table name. Instead of the third table I use the second table, etc.
    The MAIN Question: How can I set this up to have one sql to handle each type? I want to eliminate having over a dozen duplicated sqls. Can I
    incorporate this into a stored procedure or something? If so, how? Can anyone provide sample coding?
    Your help is very much appreciated. Thank you.
    GD

    Hi, Salah.
    Use "Exec" in your query to run procedures.
    SAPbobsCOM.Recordset     oRS;
    oRS = (SAPbobsCOM.Recordset)pCmp.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset);
    oRS.DoQuery ("EXEC YourStoredProcName");
    Triggers are not supported in SDK.
    Regards,
    Aleksey

  • Data retrieval from sad face ipod

    So, two nights ago my ipod (40gig 3rd gen(? 4th? 1.5 years old; warranty expired)) randomly died while in the middle of playing music. It whirred and clicked and eventually gave me the unhappy face, and that is how it's stayed for the past 48 hours. Now, there are plenty of people in this same boat, as a little browsing of the forums has showed me, so I'm not asking for how to possibly fix it, but...
    What I do want to know: is there a service to get the data off the ipod? Reformatting the machine is all fine and good, but I'm living abroad and most of my CDs are currently on the other side of the world. My friend said that you could pay $50 for Apple to retrieve the data from your old drive, but I haven't seen anything like that on the website (perhaps it is only for Macs?)
    Anyway, has anyone heard of a data retrieval service for ipods, or some other method of getting data off an ipod that won't connect to the computer? (I tried putting it in data mode and it just laughed at me...or frowned, I suppose.)
    Thanks for any advice you can give...
      Windows XP  

    Is your iPod fully charged? (connect it to the Mac for 4 hours to charge the battery)
    Your post is not very clear on the problem, but normally Resetting the iPod will get rid of the sad face, on the iPod sceen, but may not get rid of your unhappy face.
    To Reset - Press Menu and Center Button for about 10 secs till the Apple logo comes ON.
    Here is the support document that may help you.
    http://support.apple.com/kb/TS1373?viewlocale=en_US
    Good Luck & Have a nice day!

  • Optimise data retrieval from cdhdr

    Hi,
    SELECT objectid udate utime username FROM cdhdr
    INTO TABLE tb_cdhdr
    WHERE objectid IN ra_pernrange
    AND udate IN so_datum
    AND username IN so_uname.
    This is the query I am using to retrieve any changes made to the pernr-qualification relationship. It takes ages to retrieve the data.
    Is there any way to optimize this??

    Hi,
    I just did a sample run of your code, its working fine in my system.
    I think its optimised, there is a problem somewhere else.
    However i had to change the select-options parameter ra_pernrange to ra_pernr as it did not accept more than 8 characters for select-options.
    But its working fine and populating the internal table as well.
    Refer the sample code:
    TABLES: CDHDR.
    TYPES: BEGIN OF T_CDHDR,
      OBJECTID TYPE CDOBJECTV,
      UDATE TYPE CDDATUM,
      UTIME TYPE CDUZEIT,
      USERNAME TYPE CDUSERNAME,
      END OF T_CDHDR.
    DATA: TB_CDHDR TYPE TABLE OF T_CDHDR.
    SELECT-OPTIONS: RA_PERNR FOR CDHDR-OBJECTID,
                    SO_DATUM FOR CDHDR-UDATE,
                    SO_UNAME FOR CDHDR-USERNAME.
    SELECT OBJECTID UDATE UTIME USERNAME FROM CDHDR
    INTO TABLE TB_CDHDR
    WHERE OBJECTID IN RA_PERNR
    AND UDATE IN SO_DATUM
    AND USERNAME IN SO_UNAME.
    Regards.
    Edited by: rajan roy on Apr 2, 2009 1:30 PM

  • Data aquisition from spectrophotometer in two analog channels, X-Y plot

    Dear colleagues!
    I am new to LabView and I am only starting to learn the system (I have never been a programmer, I'm a chemist to be precise).
    I have before me a task to interface an old analog scanning spectrophotometer to PC via LabView.
    It has two output analog channels: one is wavelength (two ranges, currenlty let it be 190 to 390 nm; it reads on multimeter as 0.19-0.39 V range) and another one is absorbance (0-1V range). An UV spectrum sholud be an X-Y graph wherein X is wavelength and Y is absorbance.
    I am able to read one channel OR another. I am able to read BOTH channels simultaneously, but how can I plot them AGAINST each other, not against TIME?
    I am using DAQPad-1200 (LPT interface) and LabView 6.1 (that's why I am unable to read most of the VI's posted on the forum ).
    Is such an interfacing even possible given my software and hardware limitations???
    Thank you all in advance!

    Thanks a lot, johnsold!
    I am now able to get something which looks like an UV spectrum! %)
    1. I will post an image (later); however, my primary objective is to get two columns of numbers, not necessary to see an X-Y graph onscreen.
    2. Without inserting arrays like I did LV always tells about error connecting this data line from two channels to save "2-D data to file" option telling me that input is 1D!
    3. I have a manual for the device, it has all of the schematics. I am no electrician though. I will post scanned circuit diagrams then when I manage to scan them.
    Now I see two more opportunities to control the device.
    A. There is a circuit (+12V DC) on the rear of one of the modlues, which, if shorted for at least 500 milliseconds (according to Tracor manual) can initialize automatic scan. How can this be done using Labview and DAQ device? My first guess is to use an analog output and some kind of a relay, either electromagentic or semiconductor one. Is there any other possibility?
    B. In my code I am always asked to write to a file after I initialize the sequence. Can this be done AFTER the sequence is finished?
    C. Finally, is it possible to automatically stop the While loop when the number generated by shift register becomes equal to 190?
    Here are attached a new code and a sample of data.
    Attachments:
    Tracor970A-v1.0.vi ‏53 KB
    UV-test-01.txt ‏15 KB

  • Data fetch from table without Refresh and without using tab key.

    hi Friends,
    I have a problem i want to extract data from table without Refresh into text field without using Tab key. when i'll enter any value in a text field then corressponding value should come in to corressponding textfield without using Tab Key.
    eg. when i enter emp_id 101 in a text field then the first_name and last_name ,adress should come in to corressponding text fields without refresh and without using Tab key.
    How Can I do this.
    Thanks
    Manoj

    Hi Manoj,
    I assume that this is similar to: Data fetch without Refresh rather than Re: Value of one textfield should come into another textfield Without Using TAB ?
    If so, the only change you need to make on the first one is to use "onkeyup" instead of "onchange" in the item's "HTML Form Element Attributes" setting.
    Note, however, that the user must move away from the item at some point (for example, to click a button), so the onchange will be triggered anyway.
    Andy

Maybe you are looking for

  • Can I create a cert with the Java API only?

    I'm building a client/server app that will use SSL and client certs for authenticating the client to the server. I'd like for each user to be able to create a keypair and an associated self-signed cert that they can provide to the server through some

  • Image Reel in Flash

    Hi I have about 300 images to import into Flash and then place them one after the other to create an image sequence so that when viewed, looks like a video. Is there a quick an easy way of doing this other than creating blank keyframes and inserting

  • My interactive InDesign CS 5 document won't print.

    It is a 20 page document with three videos in it. Every time I select print, ID shuts down. Anyone have an idea?

  • Cannot install Elements 12 from reatil CD get shared technology error!

    I tried to install elements 12 from the retail CD. It installs almost to end then stops with an error about shared technologies. I tried all of the diagnostics that I found here ASA found no errors. I could not locate any log file to inspect. Program

  • Speaker on LG Octane not working when not in speaker mode

    When I get a call I have to take it in speaker mode because I can't hear anything with the phone closed. When I open it and it's in speakerphone mode I can hear the call. I've tried cleaning the phone many times, doesn't help.