Allow users to create reports based on their own selection of fields

Is there a way to allow users to create reports based on their own selection of fields?
And if there is a way, then how?
In access we retrieve all demographic info on one screen and on another screen user can be able to choose specific fields from a list box to import data into file.

Hi,
This can be handled in various ways - but the principles are the same.
You need to apply conditional displays to all of the columns that your user can select and base the display of a column on the value of a field on the page.
You can have a series of Yes/No options - one for each field and base the display on the corresponding field being Yes. Or you can use checkboxes.
However, if you wish to use a multiselect list (which is probably easier as you can dynamically generate the list of field names), you will need to have hidden fields that will store either Y/N or 1/0 (I use ones/zeros) and have the conditional displays watch these fields instead. Populating these hidden fields is a bit more tricky than just having fields on the page that the user can control, but is doable:
1 - Create one hidden field for each field in the report that you want to show/hide. Put these fields in the same region as the select list in a region above the report
2 - Set conditional display values to "Value of Item in Expression 1 = Expression 2" and use the appropriate hidden field for Expression 1 and in Expression 2 enter in 1
3 - Create a page process that runs on submit, and create PL/SQL code something like:
DECLARE
lFields HTMLDB_APPLICATION_GLOBAL.VC_ARR2;
vField VARCHAR2(1000);
BEGIN
:P31_SHOW_EMPNO := 0;
:P31_SHOW_ENAME := 0;
:P31_SHOW_JOB := 0;
:P31_SHOW_MGR := 0;
:P31_SHOW_HIREDATE := 0;
:P31_SHOW_SAL := 0;
:P31_SHOW_COMM := 0;
:P31_SHOW_DEPTNO := 0;
lFields := HTMLDB_UTIL.STRING_TO_TABLE(:P31_FIELDS);
FOR i IN lFields.FIRST..lFields.LAST LOOP
vField := lFields(i);
IF vField = 'EMPNO' THEN
:P31_SHOW_EMPNO := 1;
ELSIF vField = 'ENAME' THEN
:P31_SHOW_ENAME := 1;
ELSIF vField = 'JOB' THEN
:P31_SHOW_JOB := 1;
ELSIF vField = 'MGR' THEN
:P31_SHOW_MGR := 1;
ELSIF vField = 'HIREDATE' THEN
:P31_SHOW_HIREDATE := 1;
ELSIF vField = 'SAL' THEN
:P31_SHOW_SAL := 1;
ELSIF vField = 'COMM' THEN
:P31_SHOW_COMM := 1;
ELSIF vField = 'DEPTNO' THEN
:P31_SHOW_DEPTNO := 1;
END IF;
END LOOP;
END;
4 - Finally, add a button that generates the report - this just needs to submit the page and branch back to the same page
I've used the standard EMP table for this example and my hidden fields are P31_SHOW_fieldname. The code resets the hidden fields to 0, checks if the user has selected the field from the list (P31_FIELDS) and changes the hidden fields value to 1 for all those selected. When the page is re-rendered, the report hides the columns where the hidden field value is 0 and displays those where it is 1. The export option will then only export those fields that are displayed.
You can see an example of this here:
http://htmldb.oracle.com/pls/otn/f?p=33642:31
Regards
Andy

Similar Messages

  • Can the user download the report file to their own destination?

    Hello,
    I want to have a report run that will take a destination as provided by the user and save the report output there. Is this possible? (Its a delimited file.)
    Thanks,
    J

    You can use WEB.SHOW_DOCUMENT to do this.

  • Flash app that allows users to create mini animations

    Hi,
    I am fairly new to flash, and was wondering if the community could point me in the right direction for my current project.
    I am looking to build an app that allows end users to draw and save mini animations (simple predetermined shapes that move in 2D).  So far I have a written a app that allows the user to draw a single frame using simple shapes and lines, but I am having some small troubles at this stage, and have not attempted to allow the user to animate or save the drawing.
    If anyone knows of a tutorial or some other resource to put me on the right path I would be very grateful.  I can also share what I have if anyone would be willing to give me some pointers (I am going to assume that as a newbie, my code could use a lot of improvement).
    Regards,
    Robbie Vos

    Hi Andei1,
    Thanks for the input.  I figured that the save functionality would be a little difficult. 
    However, if I can get the basic app going (allowing users to create mini animations) I think I should be able to get save going with some (ok, alot) of effort.
    Regards,
    Robbie Vos

  • HT1198 If I share an iPhoto library between multiple users, will the Faces, Events, and Places be automatically usable by all users, or will each user have to tag all the photos (e.g. if a user tags a face, will a different user have to do it in their own

    If I share an iPhoto library between multiple users, will the Faces, Events, and Places be automatically usable by all users, or will each user have to tag all the photos (e.g. if a user tags a face, will a different user have to do it in their own iPhoto application??

    Have you read this Apple document regarding sharing a library with multiple users: iPhoto: Sharing libraries among multiple users?
    OT

  • Creating report based on user selected Date Range

    Hello.
    I am trying to display an Apex report that selects data for the report based on a user entered date range.
    It's a simple page with two date picker fields (p18_start and p18_end).
    The report region SQL looks like this:
    SELECT *
    FROM prj_items
    WHERE LM_DT BETWEEN :p18_start AND :P18_end
    One table, one field on the table to search and two Apex variables.
    I thought this would be fairly simple, but I am obviously missing something.
    I not even sure what other information is needed to help me figure this out.
    -Jody

    Hi,
    You can set defaults for the datepickers if you need to - this could be done in a computation on the page for each item and conditional on the item being null.
    When I've done something similar to this, I've created two hidden page items - eg, :P19_FIRST_DATE and :P19_LAST_DATE and populated these with the earliest/latest date that the user could reasonably select (perhaps, in your case, the MIN(LM_DT) and MAX(LM_DT) values).
    Then your SQL would be:
    select * from PRJ_ITEMS
    where LM_DT BETWEEN TO_DATE(NVL(:P19_START,:P19_FIRST_DATE), 'DD-MON-YY')
    AND TO_DATE(NVL(:P19_END,:P19_LAST_DATE), 'DD-MON-YY')If you don't want to set default dates, you could do something like:
    SELECT * FROM PRJ_ITEMS
    WHERE (:P19_START IS NULL AND :P19_END IS NULL)
    OR (:P19_START IS NOT NULL AND :P19_END IS NULL AND LM_DT >= TO_DATE(:P19_START,'DD-MON-YY'))
    OR (:P19_START IS NULL AND :P19_END IS NOT NULL AND LM_DT <= TO_DATE(:P19_END,'DD-MON-YY'))
    OR (LM_DT BETWEEN TO_DATE(:P19_START,'DD-MON-YY') AND TO_DATE(:P19_END,'DD-MON-YY'))There are various reasons why your two dates are being cleared when the page is reloaded. Firstly, you should check the branch that returns to the same page - make sure you are not clearing the cache for the page. Then, have a look to see if there is a "reset page" process (usually created for you when you create a form page). Then, check the Source settings for the items. Typically, these would be "Only when current value in session state is null" and a Source Type of "Static Assignment" with the "Source Value or Expression" left empty.
    Andy

  • Zero Client Design - allowing user to create document like a word document

    Hi All,
    I am planning to develop an internet based application. How can i allow user to start creating a document (Let say Word document). User does not have Microsoft Word installed on his/her client computer. my application offers create new document.
    User clicks "create new" link on the page. Is it possible to lunch the word in create new page to let user to create document and at the end click Save link on the page to save it on to server?
    Is it possible to call the word application from the sever?
    Thanks
    Sam

    I've never tried it and there may be alternative ways of doing it, but I would think the only way you can provide formatting tools - without recreating each tool - is to use an Applet.
    What you're trying to do is create a document object on the server, have the user select an command on the client side (such as underlining text), have the client pass the command back to the server, and echo the results of that operation, right?
    It would be incredibly awkward and impractical to do that through a conventional stateless HTTP medium such as JSPs, PHP or JavaScript. It may have been done before, I'm just not aware of any attempts to do so.
    Are you willing to consider alternative third-party solutions, open source or not? Or is this something that you explicitly have to code?

  • Allow user to create objects in specific schema

    I would like to be able to grant a user/role permission to create/drop tables/views/etc.. in a specific schema, other than their own.
    It appears like I can do either
    grant create table to role
    or
    grant create any table to role
    the former allowing them to create tables in their own schema, the latter allowing them to create tables anyplace.
    Is there really nothing in the middle?
    Why....
    In my application i have a couple of "users" that are really just schemas. They are not used for users to login.
    We have actual user account(s) that are used for connecting to the db by the application.
    We have a role that all of these users belong to.
    At certain points in our application, our use needs to modify one of these application schemas.
    I do not want the user to be able to modify any other schema in the database.
    I can't be the first person to have encountered this. I'm hoping that there is some clever solution that I have just missed thus far.
    10g would be ideal, 11g only would be ok.
    Thanks.
    Edited by: 854248 on Apr 23, 2011 8:54 AM

    854248 wrote:
    I would like to be able to grant a user/role permission to create/drop tables/views/etc.. in a specific schema, other than their own.
    It appears like I can do either
    grant create table to role
    or
    grant create any table to role
    the former allowing them to create tables in their own schema, the latter allowing them to create tables anyplace.
    Is there really nothing in the middle?
    Why....
    In my application i have a couple of "users" that are really just schemas. They are not used for users to login.
    We have actual user account(s) that are used for connecting to the db by the application.
    We have a role that all of these users belong to.
    At certain points in our application, our use needs to modify one of these application schemas.
    I do not want the user to be able to modify any other schema in the database.
    I can't be the first person to have encountered this. I'm hoping that there is some clever solution that I have just missed thus far.
    10g would be ideal, 11g only would be ok.
    Thanks.
    Edited by: 854248 on Apr 23, 2011 8:54 AMYou can give them CREATE ANY TABLE/VIEW privileges and then limit their actions by DDL triggers:
    http://psoug.org/reference/ddl_trigger.html
    http://www.java2s.com/Tutorial/Oracle/0560__Trigger/AFTERDDLONSCHEMA.htm
    Regards
    Gokhan

  • Need to create report based on criteria between a range of dates

    I am very new to Numbers '09 and a beginner with spreadsheets.  I've searched and can't find a formula that fits this.  I've tried Match/IF  Match/Index  VLookup  If/And formulas but can't get the right results.
    I need to be able to create a report based on data from Master Spreadsheet.  I need formulas that will populate Report Page B8:B17 and D8:D17 from data in Master Spreadsheet that meets criteria range of dates (Report Page B5 and B6).
    The closest I've come was an IF(AND formula, but that left blank lines on my report page.  (I understand why, just not sure how to resolve it.)
    P.S.  I am working in Numbers '09 on an iPad (yes, the samples below are not in the Numbers program, but it was easier to do screen shots on my Mac notebook
    Master Spreadsheet:
    Report Page:

    Hi KC,
    So you are trying to retrieve the dates and associated comments for a specific student in a specific class between the two dates.
    Here's an example, using OFFSET and MATCH, plus an added index column on the Master table. Formulas and discussion below.
    Column E uses IF and AND to determine which rows contain the data to be transferred, thn uses MAX to number those rows.
    Master::E2: =IF(AND(A>=Report :: $B$5,A<=Report :: $B$6,B=Report :: $B$3,C=Report :: $B$4),MAX($E$1:E1)+1,"")
    Fill down to the bottom of column E.
    I don't see a need to repeat the "Date" and "Comment" labels on each row containing a date and comment, so I've placed these as fixed text in A8 and B8 of the Report table, and filled the cells below those with the dates and comments using MATCH and OFFSET.
    A9: =IF(ROW()>MAX(Master :: $E)+8,"",OFFSET(Master :: $A$1,MATCH(ROW()-8,Master :: $E,0)-1,0))
    B9: =IF(ROW()>MAX(Master :: $E)+8,"",OFFSET(Master :: $A$1,MATCH(ROW()-8,Master :: $E,0)-1,3))
    As can be seen, these formulas are identical except for the column-offset argument in OFFSET, shown in bold in the examples.
    Fill both formulas down to the bottoms of their columns.
    Regards,
    Barry

  • Suggestion :  Have the "Top Users in Forum" report based on 30 days

    Currently, the "Top Users in Forum" listing is based on cumulative points. This means that we will never see "rising stars !".
    If the list were to report based on, say, points earned in the past 30 days, we'd at least be able to note some "rising stars !"
    Hemant K Chitale

    Hemant K Chitale wrote:
    Currently, the "Top Users in Forum" listing is based on cumulative points. This means that we will never see "rising stars !".
    If the list were to report based on, say, points earned in the past 30 days, we'd at least be able to note some "rising stars !"
    Hemant K ChitaleCan Jive handle the extra processing required to maintain both overall points for the persons status AND points in the last 30 days for the Top Users lists, per forum? Jeez, it can hardly handle serving the threads, don't give it more work to do. If we want anything we want the little dotty things back, at least they were useful, unlike the points system.

  • Allowing user to create link to a network file

    Is there a way to allow the user of a form to enter the path to a local network file (such as a Word document), so that when others click it, it will take them to the file?
    In a thread in another forum, someone posted the following method of create a button containing the following code that converts text entered into a text field into a hyperlink:
    if (xfa.host.name != "XFAPresentationAgent")
        var oURI = xfa.resolveNode("form1.page1.header.TextField2").rawValue;
        var oLink = "<body xmlns=\"http://www.w3.org/1999/xhtml\" xmlns:xfa=\"http://www.xfa.org/schema/xfa-data/1.0/\"><p style=\"letter-spacing:0in\"><a href=\"" + oURI+ "\" style=\"margin-top:0pt;margin-bottom:0pt;text-valign:bottom;font-fami ly:'Myriad Pro';font-size:8pt\">" + oURI + "</a></p></body>";
        xfa.resolveNode("form1.page1.header.TextField2").value.exData.loadXML (oLink, false, true);
    This works great for internet URLs; however, when you enter a local or network path (for example "Y:\Network\File.doc"), you get the following error message in your default browser:
    Firefox doesn't know how to open this address, because the protocol (y) isn't associated with any program.
    How would you alter this code so that it links to a local or network file, and doesn't try to open it in a web browser? Or, if this isn't possible, is there any other way to allow the user to create a clickable link to a file?
    Thanks,
    Jo

    I've never tried it and there may be alternative ways of doing it, but I would think the only way you can provide formatting tools - without recreating each tool - is to use an Applet.
    What you're trying to do is create a document object on the server, have the user select an command on the client side (such as underlining text), have the client pass the command back to the server, and echo the results of that operation, right?
    It would be incredibly awkward and impractical to do that through a conventional stateless HTTP medium such as JSPs, PHP or JavaScript. It may have been done before, I'm just not aware of any attempts to do so.
    Are you willing to consider alternative third-party solutions, open source or not? Or is this something that you explicitly have to code?

  • Best way to allow user to create JFrame

    Hi,
    I'm working on a part of an application that needs to allow a user to create some type of "Frame". I'll give an example: when you use an IDE an create a JFrame you can drag object to the frame until your happy with it. I you like to do something similar, obviously much more simple than an IDE.
    I have been looking at some libraries, specially XML - SWING, but not sure if its the best solution. I don't want to reinvent the wheel. So anything that could help, is more than welcome.
    thanks.

    I may not have explained myself well here.
    I want to only allow the operator to select sequences that are set up to be able to run independently. I don't want the callbacks and initialization sequences to show up in the list the operator can choose from.
    The way I figured out how to do it is a little tricky, and I think I may have found a bug.
    This is what I did:
    For the sequences I do not want to be selectable, I setPropFlags_Hidden to true. (Sequence Properties...Advanced...Flags, check the box).
    This immediately hides the sequence. In order to see all hidden sequences to edit them, set Configure->Station Options...Preferences->Show Hidden Properties.
    I wanted to set this up automatically for the sequence file, so I added a SequenceFileLoad callback to set ThisContext.RunState.Engine.StationOptions.ShowHiddenProperties = False, and a SequenceFileUnload callback to set it back to true.
    The bug I think I found:
    This solution works when I open the sequence file in the editor, but not when I use the simple operator interface. The simple operator interface will show the hidden sequences, but only the unhidden sequences show up in the RUN_SEQUENCE control. If I make sure the station is configured not to show hidden properties BEFORE I run the simple operator interface, then the hidden sequences are indeed hidden in the Sequences list (except, because I hid MainSequence, the first list entry shows up blank until I select one of the unhidden sequences).
    (see also
    http://forums.ni.com/t5/NI-TestStand/Ignore-a-Sequence-in-a-SequenceCall/m-p/1754984/highlight/false...)

  • Allow User to Create Metadata Fields

    There should be a way to allow user to define their own metadata fields - Bridge is the most logical place to do this.
    For example I'd like to add a field for color profile info:
    1 a boolean field which indicates whether or not a CP is embeded,
    1 text field for the name of the CP (This info should already be built into metadata - but until it is, I'd sure like a quick way to check)
    --Take a look at Portfolio for an example of how this could be done.
    thanks, xandr

    yes yes.. I want to do this also??

  • Creating report based on master data

    Hi Guys,
    I want to create a specific report based on master data in BI cube. for example... a report which takes cost center and period as variable and display expenses for that period and cost center. This report I want to create for all cost center in BI database separately. any idea how can we do this?
    There are 2000 cost centers and I need to print/send 2000 reports one for every cost center.
    If I store all cost center in excel file, can it be easier?
    broadcasting and creating 2000 schedule - not option.
    Thanks..SM

    Hi  stuti misra,
    Create ONE Query with selection Cost Center and Period are inputs.
    Create text variables for Cost Center and Period and add in Query Description.
    After query execution you can see description based on selection in workbook or webtemplate.
    Hope it Helps
    Srini
    [Dont forget to close the call by assigning poings.... - Food for Points: Make a Difference through Community Contribution!|https://www.sdn.sap.com/irj/sdn/index?rid=/webcontent/uuid/007928c5-c4ef-2a10-d9a3-8109ae621a82]

  • Allowing user to create new Apex User

    Hi,
    I have a requirement that a certain user group needs to create new users to use Apex application. With my understanding, no user can create new user without apex admin privilege. I can't give admin privilege to any user. Is there any workaround? Thanks.

    Instead of having Apex Authentication, build your custom Authentication.
    Create a USER table with user detail and password.
    Create a login page .. for new user give a link to public page to enter their detail.
    For encrypting and decrypting the password see the sample applcation. You can copy that logic for protecting the password.
    Regards,
    Shijesh

  • Allow users to create Challenge Questions in OAAM

    Hi,
    I have OAAM 11.1.1.5 BP01 implemented and integrated with OIM and OAM 11.1.1.5.2.
    I want to know if a user can be provided with the functionality to create his own challenge questions instead of selecting the OOTB ones.
    If yes, what would be the implementation steps to achieve this?
    Please respond.
    Thanks,
    -Kulesh...

    AFAIK, no. You can definitely customize the existing challenge question set to add/edit/remove any number of questions from the OOTB defaults per your client/organization's requirements... but on an individual user level, there is no functionality to custom define their own unique question/answer set.

Maybe you are looking for