Language query

The following compiles correctly:
import java.util.*;
public class MyVector extends Vector {
However,
import java.io.*;
public class MyPs extends PrintWriter {
gives the following error:
C:\LocalJava\Webserver\MyPs.java:3: cannot resolve symbol
symbol : constructor PrintWriter ()
location: class java.io.PrintWriter
public class MyPs extends PrintWriter {
^
1 error
I don't understand.
Paul Hide

Hi,
let's see what the compiler does.
1. It checks if you have a constructor defined. If not, a standard constructor is provided.
2. In this standard constructor super() is called.
So, MyVector compiles 'cause the class Vector has a standard constructor. MyPs does not compile 'cause PrintWriter has no standard constructor. This is what the error message says: It cannot find the constructor PrintWriter().
To make the second class compile, you have to provide your own constructor which calls one of the PrintWriter's constructors via super.
Andre

Similar Messages

  • Query not showing field discription in another language login

    Hi Experts,
    when i am running query as default language, query output is perfect.
    But when i am changeing language and DE (Danish) at SAP BW login then
    1) query is not showing field description at Selection Screen rather only displaying technical name
    2) at query output there is no report title and column heading
    Please suggest how to set language property for entire query
    i guess system not able to convert language from EN to DE.
    what and where setting need to change
    Thanks in advance

    This why at the beginning of a project you say this is English and all user shave to log in via English or if not then you build into your quote a huge amount for translation
    Have a look at the help files about the translation workbench in BW - it's big and it's a expensive and time consuming thing to do
    The two descriptions are stored in the query element text tables and for info objects in their specific tables- yep I suppose you could hack them - but you may end up causing more problems than it's worth
    If it's a simple case of some queries need translating in a small number of languages then it's as simple as splitting yoru screne into two and loggin in twice one in english the other in the other language - first in RSA1 to change the infoobject and then in query designer (following the key strokes you use in ENglish if you language skills aren;t that good int he other languages)
    The other alternative as mentioned above is using the trsnaltion workbench - but the cleitn will have get the cheque book out as it can be quite a costly exercise

  • Query - Hibernate to JPA/TopLink Conversion

    Hi,
    I have some problems with a query. My query works fine in Hibernate but I have to work with TopLink.
    I have created the query below.
    int Language = 1;
    String hql = "SELECT DISTINCT g "
    +    "FROM GUI g "
    +    "JOIN FETCH g.gUINameAllocation gna "
    +    "JOIN FETCH g.elementAllocation gea "
    +    "JOIN FETCH gea.elementTextAllocation geta "
    +    "WHERE g.gUIID = " + java.lang.Integer.toString(GUI) + " "
    +    "AND gna.languageAllocation.languageID = " + java.lang.Integer.toString(Language)
    +    "AND geta.languageAllocation.languageID = " + java.lang.Integer.toString(Language);
    Query query = session.createQuery(hql);
    java.util.List<GUI> results = (java.util.List<GUI>)query.list();
    I have tried to translate the query to JPQL but it does not allow alias names for fetch joins. I have tried to translate it to the Criteria API classes but I will not work. I have tried the Criteria API with the join class and the fetch class.
    I can not use the fetch class in crit.where(...) expression. I can only use there the join classes as far as I understood.
    int Language = 1;
    CriteriaBuilder cb = em.getCriteriaBuilder();
    CriteriaQuery<GUI> crit = cb.createQuery(GUI.class);
    crit.distinct(true);
    Root<GUI> c = crit.from(GUI.class);
    Join<GUI, GUIName> guiname = c.join("gUINameAllocation", JoinType.LEFT);
    Join<GUIName, Language> language = guiname.join("languageAllocation");
    Join<GUI, Element> guielement = c.join("elementAllocation", JoinType.LEFT);
    Join<Element, ElementText> guielementtext = guielement.join("elementTextAllocation", JoinType.LEFT);
    Join<ElementText, Language> language1 = guielementtext.join("languageAllocation");
    crit.where(cb.equal(language.get("languageID"), Language));
    crit.where(cb.equal(language1.get("languageID"), Language));
    Has somebody an idea for a solution?
    Thx in advance

    JPA does not allow alias names on fetch joins, I suspect partially because they could then be used in the filtering in the query - which is exactly what you are doing. This could cause potential caching issues, as the entity that is built might end up missing references that don't conform to the conditions in the where clause, as discussed here:
    http://www.coderanch.com/t/486454/ORM/databases/Join-Fetch-EclipseLink
    According to bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=293775 this has been changed and is supported in EclipseLink 2.4 to some degree.
    If you cannot use EclipseLink 2.4 or later, the way to do this in JPQL is to use a separate join for the alias to be used in the query, and one for the fetch join.
    "SELECT DISTINCT g FROM GUI g "
    + "JOIN FETCH g.gUINameAllocation "
    + "JOIN FETCH g.elementAllocation "
    + "JOIN g.gUINameAllocation gna "
    + "JOIN g.elementAllocation gea "
    + "JOIN gea.elementTextAllocation geta "
    + "WHERE g.gUIID = " + java.lang.Integer.toString(GUI) + " "
    + "AND gna.languageAllocation.languageID = " + java.lang.Integer.toString(Language)
    + "AND geta.languageAllocation.languageID = " + java.lang.Integer.toString(Language);
    Unfortunately JPA does not allow nested fetch joins, so the only way to fecth gea.elementTextAllocation is through a query hint:
    query.setHint("eclipselink.join-fetch", "g.elementAllocation.elementTextAllocation");
    EclipseLink/TopLink's join-fetch query hint is described here:
    http://wiki.eclipse.org/EclipseLink/UserGuide/JPA/Basic_JPA_Development/Query_Hints#Join_Fetch
    Best Regards,
    Chris

  • Hindi Language not available in LANGUAGE LOV of "Offering"

    I want to make a offering for a Class, for which I want the Language to be "Hindi", I have applied India Legislation patch also but Hindi Language is not available, Can someone tell me which is the Lookup for Languages in OLM.
    Edited by: 979869 on Mar 11, 2013 4:10 AM

    Thanks for your response:- I have got the solution for the issue
    - (resp): System Administrator > Install > Natural Languages
    - Query "Language Name = Hindi"
    - Once found, check the 'Enabled' flag and Save

  • Updating multiple node in a single query

    Hi
    Shall I update multiple nodes (which satisfies the given condition) in a single query? From the prototype we suspect that all nodes in all document are not updated in the container.
    Version: BDB XML 2.4 - Fedora core 4 Linux - C++ language
    Query:
    replace value of node collection()/File[@Id="57565C01327A"]//Entry[@Class="Measurement" and @Id="0"]/Attribute[@Name="apDlBhUtil"]/@Value with 8'
    Result:
    XmlException occurred with msg 'Error: Sequence does not match type node() - the sequence contains more than one item [err:XUTY0008], <query>:1:1'
    We have tried running the query in both Lazy and Eager evaluation type. Please clarify that the issue is with the query/execution type or BDB XML doesn't support this feature?
    Thanks
    Santhosh

    Santhosh,
    Try:
    for $i in collection()/File[@Id="57565C01327A"]//Entry[@Class="Measurement" and @Id="0"]/Attribute[@Name="apDlBhUtil"]/@Value return replace value of node $i with 8'The problem with your original is that the argument for "replace value of" needs to be a single item, not a sequence.
    Regards,
    George

  • Power BI for huge data

    Hi,
    We are using Power BI for Natural Language Query and reporting. We have to build it for data of around 200 million records. Which is fairly larger in size than 250MB (specified as data size limit for Power BI ).  Is there any way to work with this size
    of data in Power BI ? Just for reference when  we tried it for 54 Millions records and size of data in excel file was 1.8 GB and it did not work. Could anyone please tell us how can Power BI work with this much data.
    Thanks and regards,
    Arvind
    arvind chamoli

    Hi Arvind,
    Currently Power BI does have a limitation of 250MB, therefore you'll need to think about ways to shrink the data to be stored in the workbook. One practical way is to think about normalization. For example, last week I got a huge XML file from stackoverflow
    of 26GB, with a schema like:
    date, post content, list of tags, other columns that I am not interested in
    I wrote simple code to break it down into three csv files:
    date id, date
    date id, tag id
    tag id, tag name
    Basically I got rid of the data that I am not interested e.g. post content, comments, etc. and normalized the data to replace dup strings with id. Hope that helps :-)
    Samuel

  • Japense language getting displayed in master data not in query

    Hi all,
    I am trying to load the asset master from ecc and bw which both are unicode. But then the master data gets loaded perfectly with japanese in the master with
       asset   language   description
    1. 300001   en           加硫
    2. 300002   ja           加硫
    i can see some data is loaded with en and some with ja both are loaded in master data perfectly.
    but then in the query if i want to display 30002 it is not getting displayed
    can anyone help me on this

    Hi,
    What language you are selecting while logging into the query designer?
    Select the language as JA and then check if you can get the required result.
    Regards,
    Durgesh.

  • How to filter the output of a query according to the language

    Hi guys,
    I have the following tables joined togheter:  VBAK ,VBKD ,TVZBT.
    The problem is, the output gives any record as many times as many languages exist in table TVZBT
    I tried with the following instruction but it doesn't work,no matter in which event I put it:
    check tvzbt-spras eq sy-langu.
    Thanks,Christian

    Hello Christian Baldari,
    You have to add that check in where clause like :
    select ....
    from ...
    where
    <b>tvzbt~spras eq sy-langu</b>.
    why because in ur select query you are using innerjoin operation. so you are using TILD (~) operator for alias. you have to check the spras using the alias as mentioned above.
    Reward If Hepful.
    Regards
    Sasidhar Reddy Matli.

  • Query in Portal User-Language-Independent

    Hi all
    Query and Portal: NW04S
    We have some users with different language as Query language.
    So the result is, when a query is developed in german and a user has default language english the query components are shown in technical values.
    We don't want to translate the query in english
    We don't want to change the users language to german
    So my idea was to change the query iview with the parameter "sap-language=DE", but this doesn't have an affect either in iview-Properties "Query-String BEx Web Application" nor in "Parameter forwarded to BEx Web Application"
    How can I solve this problem, so the bex-query is always shown in german.
    Any ideas?
    Thank you
    Roger

    Bex? or Web?
    Bex - no chance I thinkl - at leats not one that I know off
    I have the same problem with Chinese language in a hard coded English BI portal in a multi language Consumer Portal (!

  • Applying a query language to collections

    Hi, we handed in a project a while ago that was essentially to read in data from a .DAT file, store it in appropriate collections, then use a basic query language to filter through the stored data. I wasn't really happy with my querying though, as it was basically a huge succession of control statements. The queries were of the form "select OBJECTNAME where ATRIBUTE OPERATOR VALUE and ATRIBUTE OPERATOR VALUE", there could be as many sub clauses as desired (0... 200 whatever). For example "select elephant where height > 360 and weight <= 1000".
    We had a comment back that we should use a Query interface and a two subclasses to represent a simple query (e.g. height > 360) and then a conjunctive query (ie simplequery1 AND simplequery2 ). The Query interface would then have a match method. I'm struggling to get my head around how I do this, does anyone have a simple example or explaination that might help me out?
    Cheers.

    I've done something like this a couple times. Your need to get a better idea of what you want your query language to look like. For example, if you're given a list of elephants, the "select elephant" part is unnecessary (your query will just return a list of matching elephants). You should decide if you want it to handle things like (height > (weight / 2)), whether conditions can be nested "((a and b) or (c and d)) and (e or f)". Will you need to support the conditional operator (a ? b : c) or a unary operator (-)? How complex will your order of operations rules be?
    If you keep it simple (always two operands), you could go with something like this:
    public interface QueryOperator
      public boolean eval(Object leftParam, Object rightParam);
    public enum BasicOperators implements QueryOperator
    public class  QueryElement
      private QueryOperator operator;
      private Object leftParam;
      private Object rightParam;
    }

  • SAPGUI Iview and passing logon language as query string in URL

    Dear Portal experts, is it possible to send the sapgui logon language as query string in URL so sso login to EP is language JP and the login to SAPGUI Iview (for windows) can be different langauge eg English. There is a document that talks abt configuration setting for SAPGUI for HTML , but no documentation for SAPGUI for windows using shortcut..
    eg :  http://serverhost:port/...../xxxx.iview?sap-config-mode=true&sap-language=ja
    Please let know ...thanks.
    Regards
    Gabriel

    Hi Gabriel,
    There are some context variables available for Generic component of app integrator. You can refer to the below link.
    http://help.sap.com/saphelp_nw70/helpdata/en/36/5e3842134bad04e10000000a1550b0/content.htm
    I know transaction iView is a different component but worth giving it a try.
    Regards,
    Mahesh
    Edited by: Mahesh Krishnapillai on Jan 6, 2012 1:09 PM

  • Login language missing when opening a web query

    When I am opening a web query, e.g. using the execute button in Query Designer, I am not asked for the login language. Therefore, I am not able to chose the language. Instead, the language "DE" (German) is taken by default.
    I want to execute the query in another language (English). I can do that by adding "language=en" to the URL, but this is not a solution.
    I would like to have the option to enter the language together with the login information (user and password).
    Why is the language selection missing?
    How do I get the language selection?
    In BEx (Excel) I have the language selection field.

    try this suggestion as mentioned in oss websites and help websites
    When you log onto the SAP system, you must select a language. The following describes the process according to which the logon language is determined.
    The browser that is connected to the SAP Web Application Server as a client also has language settings. With Internet Explorer, you can set the language you require by choosing Tools ® Internet Options ® Languages.
    The logon language for the SAP Web Application Server is set according to the following process.
           1.      In transaction SICF, if the service has set the flag Mandatory Logon Data, the system uses the language that was entered there.
           2.      If this is not the case, but the HTTP request contains the language in the HTTP header (as a header or a form field), you log onto the system using this language.
           3.      The system then takes the browser settings. The system selects as the logon language the first language from the list that is maintained in the browser, and which is also installed in the SAP system.
    These are transferred using the HTTP header field accept-language.
           4.      If no language is defined by this process, the classic SAP system mechanisms are used. The logon language is based on the user settings (in transaction SU01) and if nothing is entered here, the default language of the SAP system is used automatically.

  • Pb with language logon and data display Query designer

    Hello,
    I do the translations (FR => EN) via RSA1 and SE63 of my variables of my Query for the query designer.
    It works I have no technical name that appears in the query designer.
    But when I run my query using the query designer, the query is displayed in French while I am logged in English.
    I want the query is displayed in english when I'm logged into English.
    How can I do?
    Thank you pour votre aide.
    Edited by: KhalidTaibi on Jul 6, 2010 6:31 PM

    Hello,
    Per I can understand, you are executing the query from Query Designer.
    So, if you are using Query designer 7.0, you are calling the Enterprise Portal.
    Even with English on Query Designer, you have to logon as english on the
    Portal, as well.
    Try to check your Browser configuration.
    On Internet Explorer:
    Tools
    Internet Option
    Language
    Check if English is configured as the first language.
    Also, ensure the query1s objects exists on english version.
    Best regards,
    Edward John

  • A way to convert selection from query builder in DML language

    I search a way to convert selection from query builder in DML language.
    regards

    We will make a sample from this request and post it on OTN. I have pasted all the JSP code so you should be able to use it directly. Just change the BISession details and the presentation references.
    <%@ taglib uri="http://xmlns.oracle.com/bibeans" prefix="orabi" %>
    <%@ page contentType="text/html;charset=windows-1252"%>
    <%@ page import="java.util.Vector" %>
    <%@ page import="oracle.dss.thin.beans.crosstab.ThinCrosstab" %>
    <%@ page import="oracle.dss.util.DataAccess" %>
    <%@ page import="oracle.dss.selection.Selection" %>
    <%@ page import="oracle.dss.thin.beans.graph.ThinGraph" %>
    <%@ page import="oracle.dss.dataSource.client.QueryClient"%>
    <%-- Start synchronization of the BI tags --%>
    <% synchronized(session){ %>
    <orabi:BIThinSession id="BIThinSession1" configuration="/Project1BIConfig1.xml" >
    <orabi:Presentation id="untitled2_Presentation1" location="Presentation1" />
    <orabi:Presentation id="untitled2_Presentation2" location="Presentation2" />
    </orabi:BIThinSession>
    <%
    String CROSSTAB_ID = "untitled2_Presentation2";
    String GRAPH_ID = "untitled2_Presentation1";
    String MYProducts = "Nothing";
    String prodID = "MDM!D_CS_OLAP.SHAWPRODUCTS";
    //Find the crosstab object on the page
    Object crosstabObject = pageContext.findAttribute(CROSSTAB_ID);
    ThinCrosstab thinCrosstab = (ThinCrosstab)crosstabObject;
    //Get the various query components from the Crosstab
    QueryClient myQCXtab = (QueryClient)thinCrosstab.getDataSource();
    Selection mySelXtab = myQCXtab.findSelection(prodID);
    DataAccess daXtab = myQCXtab.createQueryAccess().getDataAccess(mySelXtab);
    // This is a one-d data access, only has the column edge
    int colExtentXtab = daXtab.getEdgeExtent(oracle.dss.util.DataDirector.COLUMN_EDGE);
    for (int i=0; i<colExtentXtab; i++)
    String memberLabel = (String)daXtab.getMemberMetadata(oracle.dss.util.DataDirector.COLUMN_EDGE, 0, i, oracle.dss.util.MetadataMap.METADATA_LONGLABEL);
    String memberValue = (String)daXtab.getMemberMetadata(oracle.dss.util.DataDirector.COLUMN_EDGE, 0, i, oracle.dss.util.MetadataMap.METADATA_VALUE);
    System.out.println(memberLabel + " " + memberValue);
    // As above except for graphs.
    Object graphObject = pageContext.findAttribute(GRAPH_ID);
    ThinGraph thinGraph = (ThinGraph)graphObject;
    QueryClient myQCGraph = (QueryClient)thinGraph.getDataSource();
    Selection mySelGraph = myQCGraph.findSelection(prodID);
    DataAccess daGraph = myQCGraph.createQueryAccess().getDataAccess(mySelGraph);
    // This is a one-d data access, only has the column edge
    int colExtentGraph = daGraph.getEdgeExtent(oracle.dss.util.DataDirector.COLUMN_EDGE);
    for (int i=0; i<colExtentGraph; i++)
    String memberLabel = (String)daGraph.getMemberMetadata(oracle.dss.util.DataDirector.COLUMN_EDGE, 0, i, oracle.dss.util.MetadataMap.METADATA_LONGLABEL);
    String memberValue = (String)daGraph.getMemberMetadata(oracle.dss.util.DataDirector.COLUMN_EDGE, 0, i, oracle.dss.util.MetadataMap.METADATA_VALUE);
    System.out.println(memberLabel + " " + memberValue);
    %>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <title>
    Hello World
    </title>
    </head>
    <body>
    <FORM name="BIForm">
    <!-- Insert your Business Intelligence tags here -->
    <orabi:Render targetId="untitled2_Presentation1" parentForm="BIForm" />
    <orabi:Render targetId="untitled2_Presentation2" parentForm="BIForm" />
    <%-- The InsertHiddenFields tag adds state fields to the parent form tag --%>
    <orabi:InsertHiddenFields parentForm="BIForm" biThinSessionId="BIThinSession1" />
    </FORM>
    <h2>
    The current time is:
    </h2>
    <p>
    <%= new java.util.Date() %></p>
    <input type="text" name="MyTextField" value=MYProducts readonly>
    </body>
    </html>
    <% } %>
    <%-- End synchronization of the BI tags --%>
    Hope this helps
    Business Intelligence Beans Product Management Team
    Oracle Corporation

  • Query made in French used In Spanish language

    Hello
    I have created a query in FRENCH LANGUAGE (FR) with calculated KF (NODIM used).
    When I used this query on a SPANISH EXCEL with a BW connection in FR or ES, this calculated KF was displayed with ZERO behind.
    EXCEL (FR) / BW (FR) / KF = 23
    EXCEL (FR) / BW (ES) / KF = 23
    EXCEL (ES) / BW (FR) / KF = 23 00000000000 (I dont know how many zero)
    EXCEL (ES) / BW (ES) / KF = 23 00000000000 (I dont know how many zero)
    I dont know why, can you help me ?

    Hi Laurent,
    I do not pretend to know exactly why this is happening.  But, in general, the formatting of results is accomplished using Excel "styles".
    To understand this better, you can open a work the file named "sapbexs.xla".  You should be able to find this file in the same folder that contains your copy of the Business Explorer Analyzer add-in (sapbex.xla).  On my PC that folder is:
    C:\Program Files\SAP\FrontEnd\Bw
    The path might be different for you.  The names of these two files are very similar ... the only difference is the final "s" (for styles?). 
    My guess is that there is something inherent in the way that one of the Styles is defined, which the Excel (ES) interprets quite differently from the Excel (FR).
    - Pete

Maybe you are looking for

  • How do I format my computer

    I am preparing to sell/give away my MacBook Pro 10.6.8. How do I restore it to factory settings and clear all my data?

  • How to use Function Module of Appraisal

    Hi, I want to use the standard Function Module for Appraisal like HRHAP_DOCUMENT_GET_DETAIL. But how to use it. What is the procedure to use standard function module.

  • Validate f-22 and f-27 reference field

    Hi, Which user-exit should I use when I want to validate for duplicate reference field value and fire a warning message when the reference entered by the user is already posted?  Thanks. Regards, Vale

  • How can I save my progress of the games

    Some games like Tetris you pass levels but every time I have to un-frees and re-start all the games start over. I hate this!! Is there a way to save the progress?????

  • What version of Sports Tracker for 6650 fold?

    There are seven different download links for Sports Tracker, depending on S60 version and phone model.  The 6650 fold is not listed for any of them. I'm hoping the app runs on the 6650 fold, and the page simply has not been recently updated with newe