Re: ResultSet not returning same data

Thanks to all who offered thoughts / advice on my post yesterday. For those interested here is what I found.
The Problem -
String data stored in MSSQL7 DB, transferred to MySQL4 DB, then pulled for an application did not match. Tests proved that the data IN the DB matched.
What I found -
Strings that were using unique chars such as French and German accent chars were NOT being returned correctly. It seems that when I call
ResultSet.getString() using my SQL7 DB driver I would get a different result than when calling the same method in my MySQL4 Driver.
To fix the problem I had to use
  String myString = new String(
                      ResultSet.getBytes()
                    );It seems that the DB driver was "assuming" what I wanted when using getString().
Further tests proved that...
MySQL DB Driver
getString() == new String(getBytes()) true
SQL7 Driver
getString() == new String(getBytes()) false
Just in case anyone was interested.
Thanks for listening.
ST

In MySQL you can configure the charset used by the database. The default is "latin1", and if you have the correct data in your program, you can just use getString() and setString(). That setup handles strings with French and German accented characters, I know that because I have a program that does it.
Perhaps your MS SQL configuration isn't working right? I don't have any experience on how to set that up.

Similar Messages

  • Discoverer 10g not returning same data every time

    Hi all
    Has anyone come across this at all?
    I have a client who is reporting that sometimes, not always, when they run a query, the data comes back with wrong ID number. They can then run the query again and it will then give the correct IDs. Sometimes they say they have to run it a couple of times before it pulls the data correctly.
    My first thoughts were webcache but they tell me this is happening in Plus.
    I have to say that I have not seen this behavior before so if anyone has any insights or has seen this please let me know.
    Best wishes
    Michael

    Hi there,
    I would do the following before even start looking at the report.
    - Export both the report [correct and incorrect versions] with Parameter listing and try to replicate the problem in development environment.
    - Check the SQL query behind the report and execute it with the parameter values given.
    I know this not the solution/answer you are looking for. I would do this if I am in a similar situation.
    Hope this helps you get to the bottom of the problem.
    Best Regards,
    Manish

  • Ibots not returning any data

    Hi,
    I have some ibots that I scheduled to run on a daily basis and which were working perfectly.
    Suddenly the same ibots, they run but the content of the attachment says "The specified criteria did not return any data".
    I checked the log files and could not see any relavant error.
    If I go back in the report that I am sending through the ibot, it runs without any problem.
    I tried to send it in different formats and run as different users, but the results are still the same!
    Any idea what else I could check?
    Type: Warning
    Severity: 50
    Time: Wed May 15 14:10:19 2013
    File: project/webodbcaccess/odbcconnectionimpl.cpp Line: 199
    Properties: RptPath-/shared/MICROS/giuliano/cube_build_verification;SID-btilnnapkfo2omg91a71b9m6n2;bindID-1;connID-31;ThreadID-4640;statementID-364;RSP-o:go~r:report
    Location:
         saw.odbc.statement.fetch
         saw.subsystem.portal.pdf
         saw.delivers.rpc.getDeviceContent
         saw.rpc.server.responder
         saw.rpc.server
         saw.rpc.server.handleConnection
         saw.rpc.server.dispatch
         saw.threadPool
         saw.threads
    SQLFetchScroll returned code SQL_NO_DATA_FOUND

    Thanks it solved the issue.
    But One more thing Now I have placed the parameters in the where clause of the query
    Query-
    select field1,field2,field3,field4,field5,job_name,candidate_name,interview_date from etc.ethr_irc_int_details
    where field1 is not null
    and job_name = :1
    and candidate_name = :2
    and interview_date = :3
    in the VO I am executing
    public void iniQuery(String S1, String S2,String S3)
    System.out.println("insdie ini query of the VO");
    System.out.println("S1 "+S1);
    System.out.println("S2 "+S2);
    System.out.println("S3 "+S3);
    this.setWhereClauseParams(null);
    this.setWhereClauseParam(0,S1);
    this.setWhereClauseParam(1,S2);
    this.setWhereClauseParam(2,S2);
    executeQuery();
    and in AM
    ETHRIntDetailsVOImpl IDVO = (ETHRIntDetailsVOImpl)this.getETHRIntDetailsVO();
    // IDVO.executeQuery();
    // OAViewObject IDVO = (OAViewObject)findViewObject("ETHRIntDetailsVO");
    IDVO.iniQuery(S1,S2,S3);
    Row row = IDVO.first();
    again I am not getting any data in the row??
    Any idea if I am doing any thing wrong..
    Please help urgently.
    Thanks
    Ashish

  • Custom reports in R12 not returning any data

    I'm seeing an issue of custom reports in R12 not returning any data. So far what I've been able to dig into is that the report query itself is referring to APPS synonyms that are secured under MOAC. What I am able to do is run the query in SQL Developer after having run mo_global.set_policy_context and I receive the data I'm looking for. This is not the case when running the report through the concurrent programs request.
    Secondly, I've also configured the concurrent program request to run as single operating unit mode. This aided in fixing any issues with LOVs on the parameter form. However, still no results from the report itself. I've also searched around quite extensively and added a P_CONC_PROGRAM_ID user parameter in reports developer, as well as adding SRW.USER_EXIT('FND SRWINIT') to the before report trigger and SRW.USER_EXIT('FND SRWEXIT') to the after report trigger as well. No luck. I've also tried running mo_global.set_policy_context on the before report trigger and no such luck.
    Has anyone seen similar issues with this and could shed some light? At this point, the workaround I would see is to just change the query to use respective all tables and match up against the orgid, but I'd rather not do that.

    I am facing exactly the same issue with 2 of my custom Reports in R12.1.3. We did our level best to find out the issue. It was always a hit and trial fix.
    But the following were our observations and workarounds
    0) The reports Conc Prog were in MOAC - Single mode. Both the reports had SRW INIT, EXIT and P_CONC_REQUEST_ID
    1) The reports which caused the issues[NO data fetched for MOAC] had multiple Queries in the data model and one Query fetches data and the 2nd one doesnt. Both the queries when run from SQL developer after setting the org gave results.
    Workaround for Report1
    a) We deleted the data link connecting the 2 columns in both the queries and added a bind variable instead in the 2nd /child query to refer to the column in the parent query and linked the 2 groups.
    Workaround for Report 2
    a) In report 2 the queries were not linked to each other. Only one query used to return results and the 2nd one returned 0 rows. The workaround was to use the "where" conditions as lexical parameters after having set the value for the same in before report trigger.
    Both the work around looks illogical. Still It worked..!
    Thanks
    Biju Radhakrishnan

  • BC4J - ViewObject not returning latest data

    BC4J - ViewObject not returning latest data. Some kind of EO/VO Cache Latency Issue.
    I have an edit page that presents a drop-down list which is suppose to display * un-assigned * messages, but does not. The drop-down list is using an <jbo:InputSelect> tag that gets values from a ViewObject (UnAssignedMessageView ) which issues the query listed below. Note, the ViewObject is not based on an Entity Object.
    (Query in UnAssignedMessageView)
    select      message.message_desc_short, message.message_id
    from     fmm.message
    where      message.message_id not in (select cardmessage.message_id from fmm.card_message)
    and message.message_id != 0     
    (from the edit.jsp)
    <jbo:ApplicationModule id="am" configname="com.maxmcbyte.fmm.model.ModelModule.ModelModuleLocal" releasemode="Reserved" />
    <jbo:DataSource id="ds" appid="am" viewobject="CardMessageView1" />           <<****** The VO where the inserts/updates are recorded.
    <jbo:DataSource id="ds2" appid="am" viewobject="MessageUnAssignedView" />     <<****** The VO for the unassigned message drop-down-list.
    The problem is at step 3.
    Starting with 3 Unassigned Messages.
    Step 1: enter new record AND select a MESSAGE_ID from the drop-down list.
    Step 2: commit the transaction.
    Step 3: enter another record AND select a MESSAGE_ID from the drop-down list.     <<****** the list should now be displaying 2 unassigned messages but is displaying 3.
    Note, if I check the database after step 3 using the same query as in the UnAssignedMessageView I get the correct result. I guess I'm not understanding how BC4J ViewObject Caching is working. It is strange that even after I commit the record that the cache is not updated.
    I have read the docs and will have to re-read them again * but * it would be REAL NICE to see an illustration of "A DAY IN THE LIFETIME OF DATA IN BC4J" for dummies like me.
    Can anyone tell me what I'm missing here AND what specifically needs to be done?
    Thanks All,
    Bill G...

    Well, I figured it out * BUT * this is the sort of thing that I'll bet stumps a lot of new users * AND * should be posted to a "Gotch-Ya" list.
    I'd still like to see an illustration of "A DAY IN THE LIFE OF DATA IN BC4J"
    Bill G...
    <jbo:ApplicationModule id="am" configname="com.maxmcbyte.fmm.model.ModelModule.ModelModuleLocal" releasemode="Reserved" />
    <jbo:DataSource id="ds1" appid="am" viewobject="CardMessageView1" />
    <jbo:DataSource id="ds2" appid="am" viewobject="MessageUnAssignedView" />
    <%-- adding this did the trick --%>
    <%
    ViewObject view2 = ds2.getRowSet().getViewObject();
    view2.executeQuery();
    view2.first();
    %>

  • Binocular search for Cost Center is not returning any data

    Hi Gurus,
    When clicking on the SRM-Shooping Cart-Cost Assignment- Account Assignment Overview- Cost center Binocular search icon,  it is not returning any data.  However,  when drilling down in the Account Assignment Overview, you will see another Binocular search icon for Cost Center which is working fine.
    Any idea of how you troubleshoot it.
    Thanks in advace for your help.
    HA

    Not sure about the cost assignment drill down, but after we applied SP13 to SRM server 550 the binoculars for cost center stopped working. the following note corrected this.
    Note 1259735 - Search help of generic account does not work
    If it has never worked, then probably need to setup a RFC dialog user for the F4 search help, Multiple threads on here around the dialog user for F4 with details on configuration and use.
    JF

  • How to know if the data model qry is not returning any data

    Hi
    If my report doesn't have data (meaning if the data model qry doesn't retreive any data), I wan't to show this text: "There is no data returned."
    My question is how would I know that the qry is not returning any data. I know I can create a text field, and write a trigger on it, to set it True or False depending on the fact that data is being returned or not.
    Thanks
    Shalu

    Hi,
    In Data Model create a summary column for function=count on one of your columns.
    Then for BeforeReport trigger you can write
    function BeforeReport return boolean is
    begin
    if :CS_RPT_NODATA > 0 then
    return (TRUE);
    end if;
    SRW.MESSAGE(300,'There is no data');
    return (FALSE);
    end;
    Regards, Gicu

  • Payroll extractor 0HR_PY_1 do not return any data in RSA3 in full mode

    Hi,
    I have activated Payroll extractor 0HR_PY_1.
    I use RSA3 to check the extractor.
    It does not return any data(0 records) in full mode.
    Do i need to do activate any other object, apart from the datasource?
    Thanks in advance  for your help.
    Regards,
    Suresh.

    Hi Suresh,
    HR extractors need additional authorizations. When the extractor is run, there would be a check if the user is authorized to extract data. Check SAP notes 672514 & 397208. Also find my previous post on this.
    Re: Extractor 0HR_PY_1 does not return data to BW
    Best Regards,
    Murali.

  • Boot loader did not return any data.

    Hi,
    i have installed the Oracle VM Server and Oracle VM Manager in two different machines. I'm using the VM Manager to create the Virtual Machines(guest). I followed all the steps given in the Oracle VM Manager User guide 2.2. I'm using the RHEL5 as the OS for the guest machine. I receive an error saying 'Boot loader did not return any data.'. The vm.cfg file has got created in the path /OVS/running_pool/12_VM1. The contents of the vm.cfg file are as below
    bootloader = '/usr/bin/pygrub'
    disk = ['file:/var/ovs/mount/616CC4FA976D4352B1630FFCE835FEC5/running_pool/14_VM1/System.img,xvda,w']
    keymap = 'en-us'
    memory = '1024'
    name = '14_VM1'
    on_crash = 'restart'
    on_reboot = 'restart'
    uuid = '3a925bc9-1555-b5bb-b0f0-c5958db65468'
    vcpus = 1
    vfb = ['type=vnc,vncunused=1,vnclisten=0.0.0.0,vncpasswd=vm123']
    vif = ['mac=00:16:3E:02:8B:64, bridge=xenbr0']
    Can any one help out in this ASAP.
    Thanks in Advance.

    re..
    sorry but did you installed guest OS or not ?
    Did you install from image, from dvd ...?
    If yes try start youre vm from server terminal
    #>xm create -c vm. cfg
    *T                                                                                                                                                                                                                                                                                                                                                       

  • Very Very Urgent Issue: Restricted Key Figure does not return any data

    Hi all,
    Please help me solving this urgent issue.
    created customer exit variable on characterstics version and also
    other customer exit variable on Value type.
    I coded that in variable exit. Problem is when I include these in
    restrickted keyfigure My query does not return me any data.
    But if I remove from restrickted key firgure and put it as normal
    charaterstics I see the variable is getting populated.
    Also in RSRT the SQl generated when these are included in RKF is not
    correct.
    I debugged and know they are getting populated. As when included in RKF
    I can also see the values of customer exit variables from information
    tab.
    I also know that there is data in cube for those restrictions.
    I posted one OSS Notes regarding this urgent issue. But got no reply from SAP.
    FYI: We are using BEx 3.5 Browser SAP GUI 6.4 Patch 20 BW Patch 11
    Thanks
    SAP BW
    **Please do not post the same question twice: Very Urgent Issue: Restricted Key Figure does not return any data

    Hi,
    Everyone out there this is very urgent. If someone can help me solving this problem.
    We are using BEx 3.5 Browser SAP GUI 6.4 Patch 20 BW Patch 11.
    I posted one oss notes also regarding this issue. But got no reply from SAP.
    So, Please help me solving this issue.
    Thanks
    SAP BW

  • Query for file version less than 10.0 does not return expected data

    I'm trying to build a query for all PCs that have a version of Iexplore.exe in c:\windows\program files\ that is less than 10.0 .  When I run the query it returns no data. When I change 10.0 in the query to 9.9 it returns files with version 10.xxx in
    the results.  Its as if it is seeing 10.0 as 1.0.   Is this expected ?
    select SMS_R_System.Name, SMS_R_System.ADSiteName, SMS_G_System_SoftwareFile.FileName, SMS_G_System_SoftwareFile.FileVersion from  SMS_R_System inner join SMS_G_System_SoftwareFile on SMS_G_System_SoftwareFile.ResourceID = SMS_R_System.ResourceId where
    SMS_G_System_SoftwareFile.FileName = "iexplore.exe" and SMS_G_System_SoftwareFile.FilePath = "C:\\program files\\internet explorer\\" and SMS_G_System_SoftwareFile.FileVersion < "9.9"

    It is because the values are not integer, they are a string. And therefore 1 is smaller then 9.
    http://www.enhansoft.com/

  • Column not returning any data

    Hello,
    For some reason, the result set returned from the following query will not return one of the columns, and I am stumped. Any help would be appreciated. The column that is returning NULL, even though all the other columns return data is CHQ.CHECK_NO (Note: CHQ.CHECK_DATE is returning data just fine). CHQ.CHECK_NO is defined as Number 15,0
    SELECT INV.INVOICE_DATE, INV.VENDORNO, INV.INVOICE_NO, INV.INVOICE_AMOUNT, INV.DUE_DATE, CHQ.CHECK_NO, CHQ.CHECK_DATE, SPAY.COUNT1
    FROM APINVOICE INV, CHEQUE_DETAIL CHQDTL, CHEQUE CHQ,
    (SELECT VENDORNO, INVOICE_NO, COUNT(*) AS COUNT1
    FROM VISPAYMAS
    WHERE COMP_CODE_ACCT = 'M'
    GROUP BY VENDORNO, INVOICE_NO) SPAY
    WHERE INV.ID = CHQDTL.APINVOICE_ID (+) AND CHQDTL.CHEQUE_ID = CHQ.ID (+) AND INV.VENDORNO = SPAY.VENDORNO (+) AND
    INV.INVOICE_NO = SPAY.INVOICE_NO (+) AND (INV.VENDORNO = 'AV603') AND (INV.INVOICE_DATE <= '25-JUL-06') AND
    (INV.INVOICE_DATE >= '25-JUL-05')
    ORDER BY INV.INVOICE_DATE DESC

    After further checking, it appears that indeed all the CHECK_NO data is actually NULL for the result set I am querying. The fact that the CHECK_DATE was returning data lead me to believe that there would have to be a corresponding CHECK_NO.... guess NOT! :) Ugh, I just happened to get stuck with a really odd test result set. Thanks for the help! On trying a different VENDOR_NO in the query, it is returning CHECK_NO data. I'll have to inquire as to why there would be CHECK_DATE data and not a CHECK_NO... hmm.
    I did add the TO_DATE() function into my query, thanks for the tip.

  • Wierd Coherence bug with keySet() / entrySet() not returning all data.

    So I have a cache with 3 key/values in it.
    If I call cache (over extend) with specific keys, i get all values back.
    Object valueA = namedCache.get("A");
    Object valueB = namedCache.get("B");
    Object valueC = namedCache.get("C");
    i.e. valueA/B/C are all not null.
    If I now try to use keySet()/entrySet(), I only get 1 value back.
    eg:
    int cacheSize= namedCache.size(); //cache size is 3
    int keySetSize = namedCache.keySet(); //cache size is 3
    int actualKeySetSize = (new HashSet(namedCache.keySet())).size(); // actual size is 1
    The same happens if I iterate over keyset/entryset, i.e. there is only 1 value in the result.
    I have 2 storage nodes, JMX shows 1 node has 1 unit and other node shows cache has 2 units.
    Are there any known bugs where above can occur, we are using Oracle Coherence GE 3.5.3/465p3.
    i.e. keySet/entrySet not returning full result sets!
    Cheers,
    Neville.

    Apparently a timing issue between the "creation" of a cache, and the processing of requests against that cache. Because of the nature of the cache creation protocol, it is possible for the client creating the cache to return before all storage members have been notified of the cache name. It is therefore possible for cache requests to arrive at a storage member before that member has had a chance to instantiate its backing map.
    Fix is part of 3.6.0 GA, and is now slated to be back ported for 3.5.3p8.
    Have tested against 3.6 and all looks ok now.

  • Very Urgent Issue: Restricted Key Figure does not return any data

    Hi all,
    created customer exit variable on characterstics version and also
    other customer exit variable on Value type.
    I coded that in variable exit. Problem is when I include these in
    restrickted keyfigure My query does not return me any data.
    But if I remove from restrickted key firgure and put it as normal
    charaterstics I see the variable is getting populated.
    Thanks
    SAP BW

    Hi,
    Everyone out there this is very urgent. If someone can help me solving this problem.
    We are using BEx 3.5 Browser SAP GUI 6.4 Patch 20 BW Patch 11.
    I posted one oss notes also regarding this issue. But got no reply from SAP.
    So, Please help me solving this issue.
    Thanks
    SAP BW

  • Rtrim in where clause not returning correct data

    A select statement specifying
    where rtrim(field_name) &lt;&gt; ''
    is not returning any rows even though there is data on the table with field_name not blank.
    If this particular where clause is omitted the data is returned and rtrim(field_name) is populated correctly.
    This is occurring across different tables and in both 10.2.0.4 and 11.2.0.1 databases. I can't find any references to this being a bug.
    Has anyone else come across this ? Can anyone explain why this is happening please ?

    An empty VARCHAR2 is considered NULL by Oracle.
    sql> select 1 from dual where trim (' ') = '';
    no rows selected
    sql> select 1 from dual where trim (' ') != '';
    no rows selected
    sql> select 1 from dual where trim (' ') is null;
             1
             1

Maybe you are looking for