Need to navigate between field of my database...

I need move on all the fields of my database.
Like this:
   if(buttonNextClicked) {
      resultSet.next();
      showFields();
   if(buttonPreviousClicked) {
      resultSet.previous();
      showFields();
   if(buttonFirstClicked) {
      resultSet.first();
      showFields();
   if(buttonLastClicked) {
      resultSet.last();
      showFields();
   }But I must move to the record if there's a record.
I must move on all records, but I don't want to throw the Exception no data is avaiable. It must move to next, previous, last and first if exist the record to move.
The code I've used above isn't good to give the effect I want to.
Thanks for any help.

Assuming your driver supports operations other than next(), they all return a boolean if the record exists. You're going to want to check that value before calling showFields().
Ted.

Similar Messages

  • Need help: GUI_DOWNLOAD and tab-separated in between fields.

    hello everyone,
    this is the layout of the interface that i created:
             sy-title
    total records processed: XX
    total records failed: XX
    summary of the error
    pernr<tab>name<tab>error message<tab>otherfieldshere
    i wanted the error log to be saved locally thus, i have to use GUI_DOWNLOAD.
    ok, here's the current parameters i supplied with my gui_download:
    CALL FUNCTION 'GUI_DOWNLOAD'
           EXPORTING
                filename                    = v_file_string
                filetype                      = 'ASC'
                write_field_separator   = 'X'
           TABLES
                data_tab                    = i_error_log
    (exceptions not displayed)
    the problem that i have is that, there is a difference between the error logs displayed after the execution and the error logs saved in my local directory.
    i did find a way to resolve this BUT, i still need to refine it. also, the spaces between the fields seems not tab delimited, but separated by space.
    to explain further here's the current error log that i have downloaded:
    10000001<tab>10/23/2006<tab>01<tab>P<tab>11<tab>01
    the header:
             sy-title
    total records processed: XX
    total records failed: XX
    summary of the error
    is not included in the downloaded errorlog file.
    i added some modification of my report to include it because, i want to to look exactly the same as of the errorlog generated/displyed after the execution.
    the result looks as it is what i've expected BUT,
    when i checked the spaces in between fields...
    it is all separated by spaces... not tab.
    here is the actual error log that i have obtained:
             sy-title
    total records processed: XX
    total records failed: XX
    summary of the error
    pernr<space><space><space>name<space><space><space><space><space><space>error message<space><space>otherfieldshere
    What i wanted to resolve is that, i want the error log to be tab delimited and not separated by space.
    is this possible? if it is, any suggestion will truly be appreciated.

    Hi,
    Please check your flat file i think it they have used the Three spaces instead of using a SINGLE TAB. between the fields.
    Thanks & Regards,
    Chandralekha.

  • I need to  know the name of the database table and the fields in that table

    hi,
    i need to I need to  know the name of the database table and the fields in that table for the following fields of the front end .
    1) incident details.
    2) ownership details
    3) injury type
    4) % of investigation completed withen 7 days.
    5) count of incident type
    6) cost of workers compensation claim.
    7) injury resulting from for workers compensation claim
    8) investigation free text.
    9) investigation contribution factors.
    10) investigation root cause.
    11) investigation root cause free text
    12) employee risk assesment
    13) protential infrigment notice issued
    14) actual infrigment notice issued.
    15) actual infrigment notice reference number.
    16)vehicle damaged text.
    18) when the incident occured.
    thanks and regards,
    pronoy .

    Hello,
    Check CCIHT* under se16 and search for relevant information
    Thanks
    Jayakumar

  • Link between different fields in different databases

    Hi
    I have two asp pages displaying the contents of two different
    databases. I
    also have a link in a field of the first database to open the
    second asp
    page (<a href="results.asp">
    . However, that way I see the top of the
    results.asp, while I want to go to a specific field of the
    database that is
    connected to results.asp.
    In HTML words I want to define an ancor in a field of
    database2 and call it
    from a link in a field of database1.
    Please note that this is my first try in asp, so take it easy
    Thanks
    [gt] aka geotso
    Please, remove hyphens to contact me

    <a href="results.asp#field">
    and then on results.asp, you would have -
    <p id="field">whatever</p>
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    http://www.dreamweavermx-templates.com
    - Template Triage!
    http://www.projectseven.com/go
    - DW FAQs, Tutorials & Resources
    http://www.dwfaq.com - DW FAQs,
    Tutorials & Resources
    http://www.macromedia.com/support/search/
    - Macromedia (MM) Technotes
    ==================
    "geotso" <[email protected]> wrote in message
    news:e3iicm$7b7$[email protected]..
    > Hi
    > I have two asp pages displaying the contents of two
    different databases. I
    > also have a link in a field of the first database to
    open the second asp
    > page (<a href="results.asp">
    . However, that way I see the top of the
    > results.asp, while I want to go to a specific field of
    the database that
    > is connected to results.asp.
    >
    > In HTML words I want to define an ancor in a field of
    database2 and call
    > it from a link in a field of database1.
    >
    > Please note that this is my first try in asp, so take it
    easy
    >
    > Thanks
    >
    > ------- ---- --- -- - -
    > [gt] aka geotso
    > ------- ---- --- -- - -
    > Please, remove hyphens to contact me

  • How to open and navigate between human task forms in a same page?

    Hi
    I use Oracle BPM 11.1.1.5
    I have a question about taskflows in BPM Application.
    In ADF web application, I create a sipmle task flow and insert view id and bind these to jspx pages, my pages are opend in same page when
    return an outcome.
    For exapmle I have three pages like A,B,C.
    In task flow, insert three view ids and bind to A,B,C.
    My first pages is A, and when outcome is B navigate to B, when my outcome is C then navigate to C in a same page not separate pages.
    But my problem is here.. in BPM Application when create task forms, every task has a separate task flow that there exist a single view id and a wild card flow in it.
    In BPM workspace when initiate human task form is closed, I should press refresh button to see next human task form in task list table.
    I tried to create a simple task flow and insert human task forms in it and navigate between these.. but show human task form in wrong display and don`t show some component and human task payload.
    Now, my question : How to open and navigate between human task forms in a same page like software installation?

    Having a separate Data Control for each human task is normally the case. There is a way to assign multiple human tasks to a single data control (and one task flow), but I don't think that this is going to help you with what I think you're trying to do.
    If your human task is called "EmployeeDetail", then you'd use the data control associated with this for the UI pages in the task flow diagram that is associated with this human task. For example, you might have a first page that has just the basic employee information - the fields (at least the ID field) would come from the EmployeeDetail data control. When the end user clicks "Next", you might have this UI page flow to a second UI page in the task flow diagram that has the employee's address information. You might place the address fields from the EmployeeDetail data control onto this second UI page.
    You might be asking how the work item instance can automatically flow to the next interactive activity in the process while staying inside the first interactive activity's human task's task flow diagram. This is not how it works - the task flow diagram models the end user interaction while inside a single human task that is tied to a specific interactive activity in the process. If you want a the end user to be able to move the instance through multiple interactive activities in the process in one interaction, look at "Activity Guides". Activity Guides do a nice job of this.
    Dan

  • Need to pass information from MS access database to another prog

    Hi,
    I really need some help here...
    I need to pass selected information from my database to another information.
    I am able to select and display the infotmation but i am not sure how i can transfer the information to the next program. Can any one please offer me some assistance?
    My code is as follow:
    /* Getting data from PSM32 and displaying it *can work* */
    import java.net.URL;
    import java.sql.*;
    import java.lang.String;
    /** Application to create a Ganttchart * */
    public class PSMdb
    public static void main (String argv[])
    //SQLQueryFormat a = new SQLQueryFormat();
    System.out.println("\nEstablishing Connection - Pls Wait... \n");
    /** Get Info fr database**/
    try
         //Connect to the database specified in the URL
         Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
         Connection con = DriverManager.getConnection("jdbc:odbc:PSM32");
         System.out.println("Connection Established.\n");
         //Create a SELECT statement object
         Statement statmt = con.createStatement();
         //Issue the SELECT statement
         String querySt = "SELECT Set, Name, Order " +
         "FROM PMETERS " +
         "WHERE Set = 'BRAKE.BAK' ";
         //Create and execute query
         ResultSet res = statmt.executeQuery(querySt);
           while (res.next())
                String Proj = res.getString(1); //get Proj Name
              String Task = res.getString(2); //get Task Name
              //Print statement
              System.out.println("" +Proj);
              System.out.println("" +Task);
           //Close Statement and Connection
         statmt.close();
         con.close();
         System.out.println("\nConnection Closed - Operation Successful.");
         catch(Exception E)
    //Print out the Exception Error
    System.out.println("Error:" +E );
    }And yes there is another problem. I can compile and run the program in a C:\folder but when i open the document in a project workspace, i cant compile the above code. Can any one please offer me assistance?
    Thanks a million.

    To NanookOITheNorth:
    Could you provide some more relevent information
    about what the other program is and how data should
    be transferred to it? API? Socket? File?was wanted to use the "return task" thing. Issit possible to use that?
    To annie79:
    my next program is supposed to retrive the events in the "task" field and display it in a applet. After retriving the tasks i will be getting the dates to produce the gantt chart. uses the jfree lib functions.
    the code for the applet is as follow
    /* original gantt chart program that can work*/
    import java.applet.*;
    import java.awt.*;
    import javax.swing.*;
    import java.awt.event.*;
    import java.util.Calendar;
    import java.util.Date;
    import org.jfree.chart.ChartFactory;
    import org.jfree.chart.ChartPanel;
    import org.jfree.chart.JFreeChart;
    import org.jfree.data.category.IntervalCategoryDataset;
    import org.jfree.data.gantt.Task;
    import org.jfree.data.gantt.TaskSeries;
    import org.jfree.data.gantt.TaskSeriesCollection;
    import org.jfree.data.time.SimpleTimePeriod;
    /** Application to create a Ganttchart * */
    public class Ganttchart extends JApplet{
    /** @param title , frame title **/
        public void init() {
            final IntervalCategoryDataset dataset = createDataset();
            final JFreeChart chart = createChart(dataset);
            // add the chart to a panel...
            final ChartPanel chartPanel = new ChartPanel(chart);
            // this size (500, 270) here doesn't matter cos this become the html control
            // how big u wan can change in the html code the width="800" height="600"
            chartPanel.setPreferredSize(new java.awt.Dimension(500, 270));
            setContentPane(chartPanel);
         * Creates a sample dataset for a Ganttchart.
         * @return The dataset.
        public static IntervalCategoryDataset createDataset() {
         //"Task" information should be retrived from the database to replace this current 1
            /*final TaskSeries s1 = new TaskSeries("Scheduled");
            s1.add(new Task("Write Proposal",
                   new SimpleTimePeriod(date(1, Calendar.APRIL, 2001),
                                        date(5, Calendar.APRIL, 2001))));
            s1.add(new Task("Obtain Approval",
                   new SimpleTimePeriod(date(9, Calendar.APRIL, 2001),
                                        date(9, Calendar.APRIL, 2001))));
            s1.add(new Task("Requirements Analysis",
                   new SimpleTimePeriod(date(10, Calendar.APRIL, 2001),
                                        date(5, Calendar.MAY, 2001))));
            final TaskSeries s2 = new TaskSeries("Actual");
            s2.add(new Task("Write Proposal",
                   new SimpleTimePeriod(date(1, Calendar.APRIL, 2001),
                                        date(5, Calendar.APRIL, 2001))));
            s2.add(new Task("Obtain Approval",
                   new SimpleTimePeriod(date(9, Calendar.APRIL, 2001),
                                        date(9, Calendar.APRIL, 2001))));
            s2.add(new Task("Requirements Analysis",
                   new SimpleTimePeriod(date(10, Calendar.APRIL, 2001),
                                        date(15, Calendar.MAY, 2001))));*/
            final TaskSeriesCollection collection = new TaskSeriesCollection();
            collection.add(s1);
            collection.add(s2);
            return collection;
         * Utility method for creating <code>Date</code> objects.
         * @param day  the date.
         * @param month  the month.
         * @param year  the year.
         * @return a date.
        private static Date date(final int day, final int month, final int year) {
            final Calendar calendar = Calendar.getInstance();
            calendar.set(year, month, day);
            final Date result = calendar.getTime();
            return result;
         * Creates a chart.
         * @param dataset  the dataset.
         * @return The chart.
        private JFreeChart createChart(final IntervalCategoryDataset dataset) {
            final JFreeChart chart = ChartFactory.createGanttChart(
                "Ganttchart",  // chart title
                "Task",              // domain axis label
                "Date",              // range axis label
                dataset,             // data
                true,                // include legend
                true,                // tooltips
                false                // urls
    //        chart.getCategoryPlot().getDomainAxis().setMaxCategoryLabelWidthRatio(10.0f);
            return chart;   
    }As for the "run the program in a C:\folder but when i open the
    document in a project workspace, i cant compile the
    above code. Can any one please offer me assistance?"The run time error that i get is "java.lang.NoSuchMethodError: main
    Exception in thread "main" "
    Please give me some leads on how i can cont to proceed?
    Thanks a lot

  • Crystal Report VS2005 - Table fields missing in Database Expert

    Hi,
    I am having a problem with the Crystal Report comes with Visual Studio 2005. I am trying to develop a customized report for SAP Business One. When I try to add two tables using the Database Expert, there are certain fields missing in the LINK page. This is a big problem for me because I need to link that field with another table. Oddly, it doesn't seems that there are anything wrongs with the missing fields. If I click OK and check at the Field Explorer, the missing fields are there!!!
    In other words, it is missing only at the Database Expert --> Link Tab. Anyone having the same problem? Is this a known issue or any patch that I can apply to resolve this issue?
    Thanks in advance for your help.
    Regards,
    Harianto

    Try this link to resolve your issue:
    Full Outer Join option for SQL Query and BW Query grayed out
    Thank you
    Don

  • Getting the length of a field in a database.

    I have a field in a database that has a char length of 20, is there anyway to get that length from the database.

    I probally didn't explain myself properley. The field might not have anything in it. The field would only except a length of 20, some have 10 others 5.
    I have a GUI repersenting a table in the database. When the user is inputting into this field I want to stop them from entering more than 20 Characters. I need to know how many characters the field will accept.
    I'm trying to stop my client from calling me up and saying that there something rong with the program because when he enters data, it only saves half of it.

  • To modify a field in a database table based record identification by primar

    hi
    i want to to modify a field in a database table based record identification by primary key filed and two more fields
    ie customer (primary key
    i want to modify record from intenal table the record existing with primary key field customer
    the status field needs to be mofied as " value rolled"
    the below code is happening
    loop at it_record into wa_Record
    wa_inv-customer (primary key) = wa_Record=custome
    wa_inv-date = wa_Record-date
    ...so one
    append wa_inv to it_invest
    clear wa_inv
    endloop.
    if not it_invest  is initial
    modify TABle1 ( this table is data base table which needs to be mofified) based on the primary key field
    and also date field and status field which is not primary key.
    regards
    arora

    Hi there.
    Your requirement is to update a Z Database table from your internal table, right? You have several options:
    LOOP AT it_invest INTO wa_inv.
      UPDATE dbtable
         SET date = wa_inv-date
       WHERE prim_key = wa_inv-prim_key
         AND any_field = wa_inv-any_field.
    ENDLOOP.
    or
    LOOP AT it_invest INTO wa_inv.
      UPDATE dbtable FROM wa_inv. "if wa_inv of same type of dbtable
    ENDLOOP.
    In the first example, I wrote any field because you can update dbase table, filtering for fields that don't belong to the primary key. However, remember that you will change all records that respect the key you used (so, in your case, use the primary key).
    Regards.
    Valter Oliveira.

  • How to Find the Data Type of the Field In a Database Table

    Hi Experts,
    I'm currently working on a program which needs to find out the data type of the given field in a database table. In addition to accessing DD03L directly, is there any other workaround such as function module to help me achieve this? It would be helpful if a demo example could be provided.
    Thanks a lot.

    Hi,
    Use this..
    DESCRIBE FIELD dobj  TYPE typ.
    write typ.
    type will contain the data type of the object.
    and check this thread also....
    Re: How to get datatype of fields in dynamic structures
    Cheers,
    Simha.
    Reward all the helpful answers..

  • How to bind JtextFields in Swing to Table fields in the database

    Can some one give the code of how to bind JtextFields in Swing to Table fields in the database
    Am really new to java programming and have interest in learning

    The standard JDK doesn't do this for you. If you search on Google, you may find some 3rd party packages that will do this.
    You need to create your own form add execute the appropriate SQL yourself. Read the tutorial on [url http://java.sun.com/docs/books/tutorial/]JDBC Database Access to get started.

  • How can we navigate between two windows of same component in webdynpro ABAP

    Hi
    how can we navigate between two windows( not views ) of same component in webdynpro ABAP. its an urgent requirement
    Thanks in advance.
    Regards
    Laeeq

    Hi Laeeq,
    You cannot navigate between windows of one component. You can only call a dialog box showing the contents of a second window, or you can embed the contents of a window of a different component.
    Just add all the views you need to the one and only main window of the component.
    Ciao, Regina

  • Help with scripting a period in barcode between fields.

    Good Morning,
    I need help scripting a barcode that has a period as a separator in between fields.
    I have 3 fields that I need all encoded in to one barcode and need a period as separators.
    EMPID
    FormName
    EMPSSN
    I need barcode to read as follows
    EMPID.FormName.EMPSSN
    546514.Harvest123.555284569
    I am very new to this and any help would be greatly appreciated.

    When you go to the Barcode's Value tab and select "Custom calculation script", you get an empty template of how the barcode's value is calculated, which you can then fill-in with the names of the form fields. You can also edit the separator used between the values. I'm not sure the result is a valid barcode, strictly speaking, but it works. Here's the code I used:
    /* Customize: */
    function bMemberOf(strName, aStrNames)
        for (var nMembIdx in aStrNames)
            if (strName == aStrNames[nMembIdx])
                return true;
        return false;
    function strTabDelimited(oParam)
        var bNeedTab = false;
        var strNames = "";
        var strValues = "";
        for (var i = 0; i < oParam.oDoc.numFields; ++i)
            var strFieldName = oParam.oDoc.getNthFieldName(i);
            if ((null == oParam.aFields || bMemberOf(strFieldName, oParam.aFields))
                && (null == oParam.strXclField || strFieldName != oParam.strXclField)
                && (oParam.oDoc.getField(strFieldName).type != "button"))
                if (bNeedTab)
                    if (oParam.bFieldNames)
                        strNames += "."; // I changed these two lines so the separator is a period instead of the default tab
                    strValues += ".";
                if (oParam.bFieldNames)
                    strNames += strFieldName;
                strValues += oParam.oDoc.getField(strFieldName).value;
                bNeedTab = true;
        if (oParam.bFieldNames)
            return strNames + "\n" + strValues;
        else
            return strValues;
    try
        if ( app.viewerVersion >= ADBE.PMD_Need_Version )
            event.value = strTabDelimited({oDoc: this, aFields: ["EMPID", "FormName", "EMPSSN"], bFieldNames: true});
        else event.value = " ";
    catch (e)
        event.value = " ";

  • View Link and and navigate between pages problem...

    Hi, everyone! Hope someone can help with my problem. In DB I have one table with informationa about Employees and Jobs. From this one table I made one EO from which I made 2 VO - EmployeeVO and JobsVO. I link these two VO with ViewLink - EmpJobVL (1 to 1 realtionship).
    Then I created 2 .jspx pages. In one page I droped EmployeeVO but in second page I droped JobsVO. In page template I put button with which I can navigate between these two pages.
    The problem is... when I run my employee page and navigate to correct record with "next" button and then try to navigate to jobs page then in jobs page I can't see correct record. I always see there first record. Why it is so and what can I do?
    Hope that someone helps me,
    Best regards, Debuger!

    Hi Debuger,
         No probs, U can keep ur Jspx as such u just need to clean up ur PageDefs..... Dont struggle more urself its such a easy job...
         Delete all ur page def entries and then have a copy of ur jspx coding in a notepad and delete that too....
    make ur jspx and page def a fresh one re-drag ur VOs and paste ur jspx codings again
    Ur VOs will get binded automatically......... :)
    Regards,
    Suganth.G

  • Compare and validate values between fields on different objetcs

    The main problem we are having right now is that we need to define a business's rule that compares two amounts between two different objects (in our case, account and custom object 3) and do a subtraction in order to check if the money amount value of the client is over zero to cover accidents with his insurance policy can cover the 100% of the accident or less but we need to assure that the money amount value can´t exceed the available amount (Monto Disponible).
    An example is:
    Object Account
    Available Amount: 450,00$
    Object Custom Object
    Accident's Amount: 600,00$
    Payment Amount: 600,00$
    In this example we can’t give authorization to the medical institution since the total billed amount exceeds the available amount.(The Payment Ammount > Available Ammount so there is no auth.)
    Can you tell us if this possible?. Can we make arithmetic operations between fields of different objects?.

    Dragosd,
    You can take Bob's suggestion and create a Webapplet that then displays your report information as a related item. I have a document I can send you if you need information on how to do this.
    regards
    Alex

Maybe you are looking for

  • HT4628 My ipad and iphone connect and recognize wifi signal, but my mac pro running 10.6.8 does not  recognize or list the wiifi signal as option, any ideas?

    Hi, In Austria, iphone and ipad "see" and connect to wifi signal no problem but mac pro in same room will not even allow me to choose the same wifi signal.  It seems almost blocked.  Havectried everything it seems by restarting, deleting preferred ac

  • CAPITAL GOODS credit.

    Dear all, A capital goods is sent to subcontractor for some Job work , it does not come within 180 days , resulting the duty is debited as per rule in transaction code J1IH . subsiquently the goods are received back. Now  while making the JV to re cr

  • JDBC Lookup !

    Hi Guys, //write your code here String Query = " "; Channel channel = null; DataBaseAccessor accessor = null; DataBaseResult resultSet = null; // Build the Query String Query = "Select BASE_ID from  SAP_BASE where BASE_ID = '" + "BASE_ID[0]"; try{ //

  • Keynote Performance on Mac Mini (General Question)

    I'm hoping the awesome community of Apple users can provide some much needed insight for a guy who's been out of the Apple scene since 2005. I am looking to purchase a Mac Mini 2.3GHz quad-core i7 for the sole purpose of running Keynote on Sunday's a

  • MovieClipLoader height and width

    Hi all, ok, situation is this...user clicks and drags a rectangle on the stage which gets created into a Loader which they can then load an image/swf into using filereference upload. Depending on the size and position of the rectangle the user has dr