Doing queries in view objects that do not include primary keys of entities

Is it possible to create a view object based on an entity that doesn't include the primary key from that entity object. For instance I want to do something like "select distinct (attrib1) from sometable" and obviously attrib1 is not the primary key for that table so I get an error that says, you must include a primary key in your view object. How would I implement something like this in bc4j?

You just need to go into expert mode and create the statement directly with the relevant SQL
e.g. in 9.0.3:
Context Menu -> New View Object
Select no entities in Step 2
Next through to Step 5 of the wizard and enter you expert mode SQL there. E.g. Select distinct deptno from emp
Assign the new VO to the AM data model and away you go.

Similar Messages

  • How to delete webintelligence objects that are not viewed

    Hi,
    I need to find a way to delete the objects that have not been viewed in the last 12 months. We are using Business Objects XI 3.1 here. I've already looked for this feature around a lot of sites and foruns, but I still have not found anything.
    We have over than 2.500 webintelligence objetcs in our environment. A lot of them are useless. So we would like to clean up the reports that are not viewed by the users. Maybe we would use this feature one time every year.
    Thanks in advance,
    Gustavo Borges

    We decided to clean up the old documents taking a look to their last modified date. It'll be easier and we won't loose important documents. That is gonna be enough for us.
    Thanks,
    Gustavo Borges

  • SetCurrentRowWithKeyValue - Does this execute View Object Query twice?

    Hi,
    I have a View Object for which on the prepare model of the page definition I am executing the setCurrentRowWithKeyValue action.
    In the log I see two queries being printed one with Bind Variable of the Key value that I have passed and right next to that I see one more query for the same view object that gets executed without any where clause.
    This causes the View Object to execute an open query which is causing performance issue.
    Any help/Insight on this problem is greatly appreciated.
    Thanks,
    Kumar K.

    Thanks for the response.
    Solution provided in the thread doesn't prevent the execution but it will not return any rows..But I am just curious to know that is there some thing different done while using setCurrentRowWithKeyValue?
    Why should it execute query twice once with Bind variable and next time without the bind variable?
    Kumar K.

  • Validation at View Object level and not Enity Object

    How would you create validation logic at the view object level and not at the entity object level? I have many VOs that reference the same EO and want some validation logic to be applied only to certain VOs.
    Thanks,
    Quoc

    My use case for this is to perform form validation inputted by the user via a JSPX page.

  • Refrencing objects that are not present on frame 1 of a movieclip

    Hi everyone!
    I'm working with a movieclip right now that has two frames in it.  I want the user to be able to go back and forth between the pages by clicking on tabs on either page.  The button that they click on is only present on the frame that it is applicable (so, the button to switch to frame 2 is only present on frame 1, and vice versa).
    I want to control when they are able to click back and forth, and be able to turn the buttons on and off whenever I need to, but since the button to switch back to frame 1 is only on frame 2, when I reference it from the main timeline, the button registers as a null object.  How do I refrence an object that is not present on the first frame of a clip?
    Here's the gist of what I have.  The main timeline has an object called "mAccess" that has 2 frames, Windows and Reports.  At the top there are two tabs, one for Windows, one for Reports.  The Windows tab is only clickable when on the Reports frame (frame 2) and the Reports tab is only clickable when on the Windows frame (frame 1)
    Main Timeline:
         mAccess.bReports.addEventListener(MouseEvent.CLICK, gotoreportstab);
         function gotoreportstab(event:MouseEvent) {
              mAccess.gotoAndStop(2);
         mAccess.bWindows.addEventListener(MouseEvent.CLICK, gotowindowstab);           <---  This gives me the error about the null object reference,
         function gotowindowstab(event:MouseEvent) {                                                                 since bWindows does not exist on frame 1 of mAccess.
              mAccess.gotoAndStop(1);
    Thanks for whatever help you can give me!

    the bottomline is you can't reference an object that doesn't exist (yet).  the easiest work-around is to make sure your object exists on the frames where you need to reference it.  the object doesn't need to be visible so this isn't much extra-work.  you can add and remove the object from the displaylist as you see fit or enable and disable its visible property. 

  • This page contains some SWF objects that may not work properly...

    Hello Guys
    I bought this menu made by f-source into my page:
    http://beta.asphalt-driveway-sealing.com/, it's working fine except I got this message each time I am opening my file with dreamweaver CS4: 'this page contains some SWF objects that may not work properly in the most recent versions of Internet Explorer. Dreamweaver cannot  convert them to the new SWF markups. Please delete each of them and insert again' and what I did but still got this message
    the developer told me that: "I previous versions of Dreamweaver you could disable the Active
    Content Converter http://f-source.com/before_insert/
    In CS4 there is no such option."
    Please let me know what can I do then.
    Many Thanks, T&T

    Hi
    CS4 uses a 'nested' type of object code to insert swf/flv files, which is more compliant than previous code. Obviously the f-source extension is not cs4 compliant if it is changing this, (the message indicates it is doing so) and is something you should pursue via there support department. However even though it is giving you this message it should still work on live pages.
    PZ
    www.pziecina.com

  • How can I display images that are not included in any collection?

    How can I display images that are not included in any collection (some filter or smart collection)? A smart collection with parameters "Collection - contains - empty field" does not work. Lightroom 5.

    Thank you! Good idea! I ordered letters of the alphabet (space separated), and it works.

  • HT5622 If I have two emails for my iMessage how can I see or receive my msj or the email that is not the primary email

    If I have two emails for my iMessage how can I see or receive my msj or the email that is not the primary email

    It's basically ment for iMessage and FaceTime. I might be wrong but this can only be done between two Apple products that allow this function. You won't receive an email if I sent you an iMessage to a secondary email you use for iMessages. You would only receive a text message. Now if someone using a PC sent an email to the secondary email you use you will receive an email not a text message. The secondary email is used basically if you do not have a data plan and you're connected to wifi you can still send iMessages using those emails you provided.

  • When uploading pictures from my iPad to my PC it wants to upload 8117 pictures but I have 8052 on my iPad will clicking erase after upload delete all my pictures including the pictures that are not included in the u

    When uploading pictures from my iPad to my PC it wants to upload 8117 pictures but I have 8052 on my iPad will clicking erase after upload delete all my pictures including the pictures that are not included in the upload

    Sorry mixed my numbers up I was in such a hurry to post the question uploading 8052 but I have 8117

  • I want to create a cover page for a document that is not included in the page count. How can I do this?

    I want to create a cover page for a document that is not included in the page count. How can I do this?

    Menu > Insert > Section Break at bottom of cover page.
    click in following page > Inspector > Layout > Section > Page Numbers > Start at: 1
    Peter

  • Configure CDC on tables not having Primary Key

    Hi,
    On one of our client majority of tables in their huge database are not having primary key. While starting journaling ODI-15021 error is being thrown. Is there any way to configure CDC on those tables. Even we are not in a situation to create logical primary key on ODI level. Client is asking for an oracle document which talks about such restriction. Kindly help me out. I've gone through documentation as well metalink. I'm not able to find any information regarding it.
    Regards,
    Shashi Ranjan

    Hi,
    Thanks a lot for your prompt reply. Let me describe my situation bit more clearer. I've configured ODI CDC on one schema which contains 1200 tables. I tried to configure primary key on each data store in source model but being an integrator, I'm not the right person to decide primary key on tables so, I reverted back to client to create primary key on tables or suggest what should be primary key. Now, client is asking for an oracle document stating that primary key is mandatory. They have such 20 schema with similar huge number of tables. I've gone through various documents and meta-links but no luck. Need urgent help on it.
    Regards,
    Shashi Ranjan

  • Two Queries, One View Object

    I have two fairly different ways to query the same table.
    One is a Spatial query, which returns rows that are within a radius of a starting point. This has the distance from the starting point as one of the expressions in the select list. You cannot have this expression in the select list unless the WHERE clause includes the spatial condition.
    The other way to query the table is with more "normal" WHERE clauses, like "WHERE name LIKE '%'||:nameParm||'%'", probably created as ViewCriteria. Distance is meaningless for this sort of query.
    Version one of the application solved this by having a single VO, and methods that reset the query as needed. But this had passivation/activation problems - when activated, the query would reset to the original query, but there might be bind variables left over from the other query. Solved it by not changing the query until just before it was executed. I'm not happy with this solution - it seems fragile to me.
    I could have two View Objects each with one of the queries. I envision a user interface where the user can choose which way to query the table, and some logic would have to decide which bind variables to obtain and which VO to execute. But I'd like the results from either to appear in the same ADF Faces table component. The rest of the select list is the same and would have all the same labels, etc. in the UI. I don't mind if the VO for which Distance is meaningless has a Distance attribute that is always null - I would simply set that column to not display if not appropriate.
    Possibilities: Subclass the two VOs from a third VO with a very basic version of the query, and use the parent VO in the ADF Faces table component? Or can I make the value attribute of the table dynamic - select the right VO at run time?

    Okay... no answer to this one, so I kept working on my own answer.
    Here's what I did:
    I created a VO with a very basic query that has all WHERE criteria that are common to all queries. That includes three bind variables. Call this one "BaseVO".
    I used TO_NUMBER(NULL) for the distance column that is only meaningful when you are doing a Spatial query.
    I created all of my View Links to this VO. I also did all of my UI defaults against this VO.
    Then I created two VO's that extend BaseVO. Each has the same attributes as the original, but one (call it NonSpatialVO) has View Criteria that encapsulate the non-spatial ways to query the table.
    The other VO, SpatialVO, has a different query, but it has the same select list, so it still maps to the same attributes. It has a where clause for searching by latitude and longitude, so these are bind variables. And the spatial function for the distance from the starting point replaces TO_NUMBER(NULL) in the query.
    So far, so good - the UI and View Links apply to NonSpatialVO and SpatialVO, even though they were only defined in BaseVO. It all works as expected when I run the Application Module.
    Next step - on to using the VOs in some pages in the ViewController project.
    It's going to have to decide dynamically which VO needs to be instantiated and executed, and then display the results in a table - the same table no matter which VO was used. I imagine that I'll use BaseVO to drag and drop the table on the page, but use EL to associated the correct VO with the "value" property.
    If anyone has done something like this before - your comments and advice are welcome.

  • View object that will allow to see data from two tables in a adf table

    Hi,
    I've been have serious issues to resolve this functional requirements with ADF.
    Basically I have two tables let say employee and department.
    A need a read only adf table to show the employees values but I don't want the users to see the department id, instead I want them to see the department name and all this in the same read only adf table.
    I created a view object based on such a query below:
    select employeelastname, employeefirstname, departmentname from employee, department where employee.departmentid = department.departmentid (+)
    Note the outer join here because some employees don't have department assigned but I still want to see them in my read only table.
    The problem is that the view object is based on a sql query and is using calculated attributes instead of entities and I am getting that error "rowkey does not have any primary key attributes" each time I select a row inmy adf read only table. So the popup I defined when the user select a row does not work properly and I need a better solution. I will also have the option for the users to delete a record selected in the read only table so really need entities behind there not just a view.
    My view object also include LOVs but I realized LOVs only work for tables but not for read only tables. Too bad the fonctionality is almost there... So even if I have lovs defined that show the data like I would like it to be seen for tables it does not help for ready only tables. Any way to have read only table working with LOVs (user will not be able to change the values or select another value in the list but at list they would see the department name instead of the department id)?
    Thanks to anyone that would be able to help me on this.
    Stephane

    Let me first say that I would use Shays approach and only under special circumstances (which are beyond this thread) use the solution outlined below:
    You can use the read only VO based on your query without basing it an entities. All you have to do is to mark one or more attributes as primary key in the VO. This should solve the "rowkey does not have any primary key attributes" error.
    Now to delete a row (I'm not sure which row department or employee you mean here) you use the selected read only row, get the PK of the row and call a service method in the application module of in a VO which is based on an entity and remove the row there. You can even use the removeRowWithKey operation from the data control to archive this.
    The second problem I don't understand. If you show the user a read only table there in no need to show a lov as you can't change the value. If your problem is that you need to show the department name instead of the department id, you simply add the department name to the attributes you select with your query.
    Timo

  • Can I make objects that do not print?  Like a guide box for labels.

    I wanted to print labels for my memorex DVD labels but couldn't find templates for pages.  The doc files open but pages prints the lines of the guides which are never exactly correct so they look horribly uneven.  Can I make a separate layer that doesn't print or objects that won't print but are selectable.

    The 'guides' are probably text boxes, into which you place the text.
    Select one of these, then use the Stroke controls in the Format bar to set the stroke to 'none.'
    Choose View > Show Layout to see the position of the box (and other layout elements, such as the left and top margins and the header box in this screen shot):
    When printed, or viewed with Show Layout turned off, the same portion of the same page will have this appearance (not including the difference in scale caused by the automatic scaling of graphics on this board):
    "View" in the instruction above means either the View button on the Toolbar or the View menu in the Menu Bar.
    Ragards,
    Barry

  • How to view songs that are not in any playlist

    I am using iTunes 6.04.
    I want to be able to view songs in my Library that are not associated with ANY playlist. How can this be done? Please don't suggest to me upgrading to iTunes 7.02. (with every iTunes update, Apple makes is more difficult to do the things Apple doesn't want you to be able to do).
    Thanks
    Ben

    Please be patient. If you don't get a reply within a few hours, obviously nobody passed by who knew the answer to your question.
    After all we're just fellow users trying to help as these are user-to-user forums.
    I have an answer.
    Run one of these scripts:
    Not In Any Playlist will create a text listing of songs that are not in any playlist.
    Not In Any Playlist To Playlist will put songs that are not in any playlist into a new playlist.
    Hope this helps.
    M
    17' iMac 800 MHz, 768 MB RAM, 200 GB HD, DL burner   Mac OS X (10.4.8)   iTunes 7.0.2

Maybe you are looking for

  • Can my mid '12 MacPro 3.2 GHz Quad-Core Intel Xeon handle Final Cut Pro X?

    Thanks in advance for your help! Model Name: Mac Pro  Model Identifier: MacPro5,1  Processor Name: Quad-Core Intel Xeon  Processor Speed: 3.2 GHz  Number of Processors: 1  Total Number of Cores: 4  L2 Cache (per Core): 256 KB  L3 Cache: 8 MB  Memory:

  • Photo Storage Issue On iPhone 6

    Under manage storage in settings, I am showing that Photos is taking up 5.1GB of space on my phone, which is prohibiting me from adding music or videos to my phone.  I only have 300 photos in my photo stream, so there is no reason it should be that l

  • Middle row keys on keyboard stop responding....

    Hello, Has anyone experienced the middle row of keys (A through L) on an iBook G4 stop responding? This seems to happen if I have been using the G4 iBook for a little while (maybe 30 minutes but not consistent) but sometimes shorter than other times.

  • AE won't soft/hard/factory reset after WDS

    Hi, I can't get my Airport Express to reset no matter what method I try: pushing the reset button down (soft), holding it down for 5 or 10 seconds (hard), or holding it down while plugging the unit in (factory). Nothing works; it just blinks slow amb

  • Where can i download the windows 7 version of apple configuator from

    where can i download the windows 7 version of apple configuator from