Trying to return query dynamically if parameter value is not null and null

Hi,
I wrote a custom code like this....
Public Shared Function GETSQL(ByVal month as Date, ByVal year as Date, ByVal partyCode as Integer)
Dim sql1 As String
Dim sql2 As String
Dim sql3 As String
Dim sql4 As String
If (IsNothing(partyCode)) Then
sql1 = " select " & vbCrLf
sql3 = " where " & vbCrLf
sql3 = sql3 & " Month(SaleHDR.Date)=month " & vbCrLf
sql3 = sql3 & " and year(SaleHDR.Date)=year " & vbCrLf
sql4 = " GROUP BY Month(SaleHDR.Date), " & vbCrLf
sql4 = sql4 & " YEAR(SaleHDR.Date), " & vbCrLf
sql4 = sql4 & " DAY(SaleHDR.Date), " & vbCrLf
sql4 = sql4 & " ProductGroup.ProductGroupCode " & vbCrLf
Else
sql1 = " select " & vbCrLf
sql3 = " where " & vbCrLf
sql3 = sql3 & " Month(SaleHDR.Date)=month " & vbCrLf
sql3 = sql3 & " and year(SaleHDR.Date)=year " & vbCrLf
sql3 = sql3 & " and Party.PartyCode=partyCode " & vbCrLf
sql4 = " GROUP BY Month(SaleHDR.Date), " & vbCrLf
sql4 = sql4 & " YEAR(SaleHDR.Date), " & vbCrLf
sql4 = sql4 & " DAY(SaleHDR.Date), " & vbCrLf
sql4 = sql4 & " ProductGroup.ProductGroupCode " & vbCrLf
End If
sql2 = " Month(SaleHDR.Date) as Month, " & vbCrLf
sql2 = sql2 & " YEAR(SaleHDR.Date)as Year, " & vbCrLf
sql2 = sql2 & " DAY(SaleHDR.Date) as Day, " & vbCrLf
sql2 = sql2 & " ProductGroup.ProductGroupCode, " & vbCrLf
sql2 = sql2 & " SUM(ISNULL(SaleDTL.ProductRate,0)*isnull(SaleDTL.ProductQuantity,0)) as SalesAmount " & vbCrLf
sql2 = sql2 & " from " & vbCrLf
sql2 = sql2 & "  SaleDTL " & vbCrLf
sql2 = sql2 & "  inner Join " & vbCrLf
sql2 = sql2 & " SaleHDR " & vbCrLf
sql2 = sql2 & "  ON SaleDTL.Id = SaleHDR.id " & vbCrLf
sql2 = sql2 & "  inner Join " & vbCrLf
sql2 = sql2 & "  ProductMaster " & vbCrLf
sql2 = sql2 & "  ON SaleDTL.ProductId = ProductMaster.ProductID " & vbCrLf
sql2 = sql2 & "  inner Join" & vbCrLf
sql2 = sql2 & "  ProductGroup " & vbCrLf
sql2 = sql2 & "  ON ProductMaster.ProductGroupId = ProductGroup.ProductGroupID " & vbCrLf
sql2 = sql2 & "  inner Join " & vbCrLf
sql2 = sql2 & "  Party " & vbCrLf
sql2 = sql2 & "  ON SaleHDR.PartyId = Party.PartyID " & vbCrLf
GETSQL = sql1 & sql2 & sql3 & sql4
End Function
to use in my project report. I'm just trying to combine two reports(first one without partycode condition, second with a party code condition) into one report by using above custom code.
then i use this as a query expression in a dataset: Code.GETSQL(Parameters!Month.Value,Parameters!Year.Value,Parameters!PartyCode.Value)
but when i try to preview the report i'm getting a error saying:
Cannot set the command text for dataset 'DataSet1'
Error during processing of the command text expression of dataset 'DataSet1'.
Can anyone help me here Please!!!
Very much appreciated if anyone can guide me if there is a other way around.
Thank you!!

I think you just need to do this as a SQL query in your data source, and use the condition:
WHERE (Party.PartyCode = @pPartyCode or @pPartyCode is null)
I rewrote your vb as t-sql here:
(if you're using this as a data source, remove the first line where the parameters are declared, as SSRS will create the parameters for you)
declare @pMonth int, @pYear int, @pPartyCode nvarchar(20)
select
month(SaleHDR.[Date]) as [Month],
year(SaleHDR.[Date]) as [Year],
day(SaleHDR.[Date]) as [Day],
ProductGroup.ProductGroupCode,
SUM(ISNULL(SaleDTL.ProductRate,0)*isnull(SaleDTL.ProductQuantity,0)) as SalesAmount
from SaleDTL
inner join SaleHDR ON SaleDTL.Id = SaleHDR.id
inner join ProductMaster ON SaleDTL.ProductId = ProductMaster.ProductID
inner join ProductGroup ON ProductMaster.ProductGroupId = ProductGroup.ProductGroupID
inner join Party ON SaleHDR.PartyId = Party.PartyID
where
Month(SaleHDR.[Date])= @pMonth
and year(SaleHDR.[Date])= @pYear
and (Party.PartyCode= @pPartyCode or @pPartyCode is null)
group by month(SaleHDR.[Date]),
year (SaleHDR.[Date]),
day (SaleHDR.[Date]),
ProductGroup.ProductGroupCode

Similar Messages

  • Error in InfoView "The Parameter Value is not Valid"

    Hello,
    I have developed a Crystal Report in CR2008 and uploaded in the InfoView. Now when i run the report via scheduling or load the report with the data and try to change the parameter (editable set in CR) from the drop down list and hit apply i get an error dialogue box "The parameter value is not valid" and message says "null".
    Also another issue is that i cannot execute the report directly in InfoVIew, i have to schedule it to run the report. Report is connected to the SAP InfoSet.
    Any input would be much appreciated.
    Thanks.

    We have rebuild new servers for InfoVIew and it just works fine. Both the problem solved.

  • Urgent - parameter values are not getting posted

    Hi
    I have a url in the wf notification that directs the user to the oaf page, the parameters are being sent as url parameters. I have no problem in accessing in the processRequest method of first page. But When I try to read the same in processFormRequest method of trainCO, I am not getting values. Any idea why?
    I tried with pageContext.putParameter() method in processRequest even the parameter value is not avaialable in processFormRequest. How to pass the parameter value from processRequest to processFormRequest?

    If the parameters are url parameters then they will be available in the processFormRequest also. If they were added using pageContext.putParameter then it will not be available in the processFormRequest

  • Selecting an lov parameter value sometimes not passed correctly

    When selecting a value from an LOV parameter, sometimes the parameter value doesn't seem to get passed correctly to the data template query.
    For example, let's say I have the following LOV parameter called "risk":
    Some Risk
    New Risk
    Other Risk
    Last Risk
    When I select "Some Risk", I would get correct results and when viewing the "Data" xml, I can see the parameter with the right value:
    <RISK>Some Risk</RISK>
    But when I select "New Risk" the results are incorrect and the xml shows:
    <RISK />
    as if the value was not passed as the bind parameter value for the dataset query.
    Any idea what I'm doing wrong? Is this a BIP bug or is there a workaround?

    Hi, thanks for the reply.
    The LOV is of "SQL Query" type (not fixed data) and the values were retrieved from the database.
    Supposing this was the sql query for my "risk" parameter LOV:
    select dimvaltl.GENERIC_VAL_NAME
    from GENERIC_VAL_TL dimvaltl,
    GENERIC_TL dimtl
    where dimtl.GENERIC_NAME = 'Risk'
    and dimvaltl.GENERIC_ID = dimtl.GENERIC_ID
    order by dimvaltl.GENERIC_VAL_NAME
    And supposing this was the sql query in the data template dataset:
    select pdimv.ID
    from GENERIC_V pdimv
    where pdimv.NAME = 'Risk'
    and pdimv.VALUE in (:risk)))
    If risk is empty, obviously the query would not work. I noticed the xml generated sometimes show the selected parameter value and sometimes don't, as if BIP is not passing it to the dataset query as bind parameter value.
    Incidentally I have other lov parameters that works fine, the only difference I can think of is that for this LOV query I am doing a join instead of a simple select statement from one table.

  • I have an apple id and also have the credit card details in it. I am trying to buy credits on Viber, but it is not purchasing and telling me to contact Apple iTunes support center. What do i do now?

    I have an apple id and also have the credit card details in it. I am trying to buy credits on Viber, but it is not purchasing and telling me to contact Apple iTunes support center. What do i do now?

    Contact Apple iTunes Support Center as directed in the message.

  • Value Help Not Working and Values Not Showing in BPS0

    I have custom characteristics transported from a BW 3.5 system to a NW2004s.  I have maintained master data and activated master data.  When I try to do the value help selection from inside maintain, I don't see the characteristic values.  In BPS0 the values are not registering and the variables are failing cause they say there are no master data values.  How to resolve?
    Thanks,
    Cherie

    I also noted the anomaly only occurs with custom characteristics, transported from a 3.5 system to a NW 2004s system and have NO attributes assigned to the characteristic. Those custom ones that have attributes show up fine.

  • Dynamic default parameter value

    Hi,
    I'm running Oracle BI Discoverer Plus 10g (10.1.2.45.46c)
    Is it possible to make the default parameter value dynamic ?
    In my case I want the default parametervalue to be set to the week before actual week.
    Eg if I'm running the report during this week it would be set default to '2005W43',
    running the report during next week it would be set default to '2005W44' and so on...
    Have tried to assign the default value with "TO_CHAR(SYSDATE-7,'RRRR')||'W'||TO_CHAR(SYSDATE-7,'IW')"
    Note the enduser must have the possibility to change from the default week to some other week.
    Any ideas ?
    /Sam
    Message was edited by:
    [email protected]

    Post Author: synapsevampire
    CA Forum: General
    A common solution is to use a Union All in a query to get the ...All and the dynamic values using a Command Object.
    select '...All' from tableUNION ALLselect field from table
    -k

  • How to pass the dynamic request parameter value $fieldName:IsSelected for framework folder service FLD_PROPAGATE?

    Hello All,
    I created a WSDL for Framework folder service FLD_PROPAGATE  and FLD_PROPAGATE service has following two required request parameter:
    $fieldName:isSelected: Set to 1 to propagate the specified field.
    $fieldName: The value of the field to propagate
    So, I am facing issue in passing the parameter $fieldName:isSelected.
    I tried to pass the request parameter as mentioned below in SOAP UI request payload but still this is not working and error message is: "Unable to propagate. Please select at least one field to propagate"
    <csx:fSecurityGroup:IsSelected>1</csx:fSecurityGroup:IsSelected>
    <csx:fFolderGUID>C7F5CBB4E54A790E21E18CE378B16EEB</csx:fFolderGUID>
    <csx:fSecurityGroup>Public</csx:fSecurityGroup>
    Could you please suggest for the correct way to pass these parameter values? If anyone have sample WSDL for this service please share?
    Here is the complete service definition:
    FLD_PROPAGATE
    Service that propagates metadata down through the folder structure in Folders.
    Service Class: intradoc.folders.FoldersService
    Location: IdcHomeDir/resources/frameworkfolders_service.htm
    Required Service Parameters
    $fieldName:isSelected: Set to 1 to propagate the specified field.
    $fieldName: The value of the field to propagate

    Hello All,
    I created a WSDL for Framework folder service FLD_PROPAGATE  and FLD_PROPAGATE service has following two required request parameter:
    $fieldName:isSelected: Set to 1 to propagate the specified field.
    $fieldName: The value of the field to propagate
    So, I am facing issue in passing the parameter $fieldName:isSelected.
    I tried to pass the request parameter as mentioned below in SOAP UI request payload but still this is not working and error message is: "Unable to propagate. Please select at least one field to propagate"
    <csx:fSecurityGroup:IsSelected>1</csx:fSecurityGroup:IsSelected>
    <csx:fFolderGUID>C7F5CBB4E54A790E21E18CE378B16EEB</csx:fFolderGUID>
    <csx:fSecurityGroup>Public</csx:fSecurityGroup>
    Could you please suggest for the correct way to pass these parameter values? If anyone have sample WSDL for this service please share?
    Here is the complete service definition:
    FLD_PROPAGATE
    Service that propagates metadata down through the folder structure in Folders.
    Service Class: intradoc.folders.FoldersService
    Location: IdcHomeDir/resources/frameworkfolders_service.htm
    Required Service Parameters
    $fieldName:isSelected: Set to 1 to propagate the specified field.
    $fieldName: The value of the field to propagate

  • How do I change the query based on parameter value

    hi,
    Based on parameter value I want to change my query. If paramter value is 'O' i want the 'order by depno' in query if the value is null i don't want the order by clause.
    How do I achieve this.
    Thanks
    Ram

    U can use lexical parameter
    i.e u create one user parameter and in query
    u use this parameter with &param_name
    ex.
    select val,prize from stock where sr_no > :srno
    orderby &ord_by
    here ord_by is lexical parameter
    and set its intial value to 'sr_no'
    so u can get result order by sr_no
    this parameter is set from form so u will give condition in form and depending
    on condition u will pass this parameter from form.

  • Need Help: Dynamically displaying parameter values for a procedure.

    Problem Statement: Generic Code should display the parameter values dynamically by taking "package name" and "procedure name" as inputs and the values needs to be obtained from the parameters of the wrapper procedure.
    Example:
    a) Let us assume that there is an application package called customer.
    create or replace package spec customer
    as
    begin
    TYPE cust_in_rec_type IS RECORD
    cust_id NUMBER,
    ,cust_name VARCHAR2(25) );
    TYPE cust_role_rec_type IS RECORD
    (cust_id NUMBER,
    role_type VARCHAR2(20)
    TYPE role_tbl_type IS TABLE OF cust_role_rec_type INDEX BY BINARY_INTEGER;
    Procedure create_customer
    p_code in varchar2
    ,p_cust_rec cust_in_rec_type
    ,p_cust_roles role_tbl_type
    end;
    b) Let us assume that we need to test the create customer procedure in the package.For that various test cases needs to be executed.
    c) We have created a testing package as mentioned below.
    create or replace package body customer_test
    as
    begin
    -- signature of this wrapper is exactly same as create_customer procedure.
    procedure create_customer_wrapper
    p_code in varchar2
    ,p_cust_rec customer.cust_in_rec_type
    ,p_cust_roles customer.role_tbl_type
    as
    begin
    //<<<<<---Need to display parameter values dynamically for each test case-->>>>>
    Since the signature of this wrapper procedure is similar to actual app procedure, we can get all the parameter definition for this procedure using ALL_ARGUMENTS table as mentioned below.
    //<<
    select * from ALL_ARGUMENTS where package_name = CUSTOMER' and object_name = 'CREATE_CUSTOMER'
    but the problem is there are other procedures exists inside customer package like update_customer, add_address so need to have generalized code that is independent of each procedure inside the package.
    Is there any way to achieve this.
    Any help is appreciated.
    // >>>>
    create_customer
    p_code => p_code
    ,p_cust_rec => p_cust_rec
    ,p_cust_roles => p_cust_roles
    end;
    procedure testcase1
    as
    l_cust_rec customer.cust_in_rec_type ;
    l_cust_roles customer.role_tbl_type;
    begin
    l_cust_rec.cust_id := 1;
    l_cust_rec.cust_name := 'ABC';
    l_cust_roles(1).cust_id := 1;
    l_cust_roles(1).role_type := 'Role1';
    create_customer_wrapper
    p_code => 'code1'
    ,p_cust_rec => l_cust_rec
    ,p_cust_roles => l_cust_role
    end;
    procedure testcase2
    as
    l_cust_rec customer.cust_in_rec_type ;
    l_cust_roles customer.role_tbl_type;
    begin
    l_cust_rec.cust_id := 2;
    l_cust_rec.cust_name := 'DEF';
    l_cust_roles(1).cust_id := 2;
    l_cust_roles(1).role_type := 'Role2';
    create_customer_wrapper
    p_code => 'code2'
    ,p_cust_rec => l_cust_rec
    ,p_cust_roles => l_cust_role
    end;
    end;

    Not possible to dynamically in a procedure, deal with the parameter values passed by a caller. There is no struct or interface that a procedure can use to ask the run-time to give it the value of the 1st or 2nd or n parameter.
    There could perhaps be some undocumented/unsupported method - as debugging code (<i>DBMS_DEBUG</i>) is able to dynamically reference a variable (see Get_Value() function). But debugging requires a primary session (the debug session) and the target session (session being debugged).
    So easy answer is no - the complex answer is.. well, complex as the basic functionality for this do exists in Oracle in its DBMS_DEBUG feature, but only from a special debug session.
    The easiest way would be to generate the wrapper itself, dynamically. This allows your to generate code that displays the parameter values and add whatever other code needed into the wrapper. The following example demonstrates the basics of this approach:
    SQL> -- // our application proc called FooProc
    SQL> create or replace procedure FooProc( d date, n number, s varchar2 ) is
      2  begin
      3          -- // do some stuff
      4          null;
      5  end;
      6  /
    Procedure created.
    SQL>
    SQL> create or replace type TArgument is object(
      2          name            varchar2(30),
      3          datatype        varchar2(30)
      4  );
      5  /
    Type created.
    SQL>
    SQL> create or replace type TArgumentList is table of TArgument;
      2  /
    Type created.
    SQL>
    SQL> -- // create a proc that creates wrappers dynamically
    SQL> create or replace procedure GenerateWrapper( procName varchar2 ) is
      2          procCode        varchar2(32767);
      3          argList         TArgumentList;
      4  begin
      5          select
      6                  TArgument( argument_name, data_type )
      7                          bulk collect into
      8                  argList
      9          from    user_arguments
    10          where   object_name = upper(procName)
    11          order by position;
    12 
    13          procCode := 'create or replace procedure Test'||procName||'( ';
    14          for i in 1..argList.Count
    15          loop
    16                  procCode := procCode||argList(i).name||' '||argList(i).datatype;
    17                  if i < argList.Count then
    18                          procCode := procCode||', ';
    19                  end if;
    20          end loop;
    21 
    22          procCode := procCode||') as begin ';
    23          procCode := procCode||'DBMS_OUTPUT.put_line( '''||procName||''' ); ';
    24 
    25          for i in 1..argList.Count
    26          loop
    27                  procCode := procCode||'DBMS_OUTPUT.put_line( '''||argList(i).name||'=''||'||argList(i).name||' ); ';
    28          end loop;
    29 
    30          -- // similarly, a call to the real proc can be added into the test wrapper
    31          procCode := procCode||'end;';
    32 
    33          execute immediate procCode;
    34  end;
    35  /
    Procedure created.
    SQL>
    SQL> -- // generate a wrapper for a FooProc
    SQL> exec GenerateWrapper( 'FooProc' );
    PL/SQL procedure successfully completed.
    SQL>
    SQL> -- // call the FooProc wrapper
    SQL> exec TestFooProc( sysdate, 100, 'Hello World' )
    FooProc
    D=2011-01-07 13:11:32
    N=100
    S=Hello World
    PL/SQL procedure successfully completed.
    SQL>

  • Parameter values are not showing in in the Organization Parameter form

    We have done a setup for an Inventory Organization.
    Everything was working fine.
    Values were showing everywhere.
    We have lot of transactions done in the org also.
    But suddenly yesterday when I was trying to open the Organization Parameter form for that specific organization, the form came up as blank and in the bottom the error is Query caused no records.
    I have checked data is there in the base table mtl_parameters.
    Value is coming for other organizations. Only one specific organization is having this issue.
    Even in Examine, I have taken the last query run on that form and ran the same in back end database, I can see all values are there in the database.
    But in frontend screen the values are not showing. even organization code also not showing.
    Navigation is: Inv Super user --> Setup --> Organization --> Parameter

    Have you checked Organization Access to ensure that no one restricted that org?
    Or shipping grants and roles?
    I think there are quite a few places that you can restrict access.

  • Dynamic List of Values does not appear

    Hi All,
       I am re-creating this post as I have not received an answer on it.
    Hi All,
    I created report (using Crystal Reports 2008) in which one of my parameters displays a dynamic LOV from a field. When I run the report in Crystal, I get to select which values I want for record selection in my report.
    However, when I save this report and run it on the Crystal Server (2008) using infoview, I do not get the dynamic LOV. Rather, I have to manually type a value that I want to select.
    Why does the LOV's not work when I run it through Crystal Server? Another thing, when I access it from Crystal Server through Crystal Reports, I still lose the dynamic LOV option.
    How do I use parameters so that I can select from a dynamic list a values? It behaves normally in Crystal Reports 2008 but loses it's functionality on the Server.
    Thank you in advance.

    This just started happening to me as well, the reports I created (using standalone crystal reports 2008) contain dynamic parameters and suddenly they stopped working as intended in some reports.
    I noticed that when the datasource is a single table or a single view the cascading (nested) dynamic parameters and dropdowns are working fine, but when the datasource is two or more linked tables, the parameters prompt shows two empty text boxes instead of two dropdowns. I tried refreshing and verifying the database but nothing works. So until we find a real solution, we're basing all our reports on single views.
    This remains a serious problem because in some cases we don't have write access to the database to create views, and basically we're recreating all the reports that now suffer from this problem.
    Edited by: Talal Nehme on Jan 7, 2009 7:29 PM

  • Printing parameter values in xml report, and displaying it in header of the

    Hi All,
    Can anybody give me an idea to print the parameter values in the xml report.
    My requirement is like, I have 10 parameters in report builder, I have generated the xml file and created the .rtf template and finally registerted in oracle apps. But now, the requirement is to print the parameter values in the report output.I don't see any xml tags in the xml output.
    Any suggestion will be appreciated.
    Thanks in advance.

    I think all the XML attributes can contain lexicals. If you bring up the property palette against the report object you can just set the following:
    XML Tag Attributes: myParameter="&<P_1>"
    where P_1 is your user parameter.

  • Large Number of Multi-Select Parameter Values does not generate Report

    I have a SSRS Report that requires 4 multi-select parameters.
    The report is deployed on a SharePoint website with SSRS integration.
    I calculated, if the user selects 'Select All' for one specific customer, there could be at most 2700 possible parameter values among the 4 parameters.
    In some cases, when a user selects 'Select All' and clicks Apply, nothing happens.  No icon showing Processing Report.
    If a user selects 'Select All' and the total number parameter values are under 500 for a specific customer, there is an icon showing Processing Report.
    I followed the instructions at:
    http://social.msdn.microsoft.com/Forums/en-US/b02ccb5d-6019-4d63-bd6c-8baff24fffd8/sql-server-limit-on-the-number-of-multivalue-parameter-selections?forum=sqlreportingservices
    That did not help.
    Thanks in advance.

    Install the latest update of SQL Server :
    2008 SP2 : http://www.microsoft.com/en-us/download/details.aspx?id=12548
    2008 R2 SP2 : http://www.microsoft.com/en-us/download/details.aspx?id=30437
    2012 SP1 : http://www.microsoft.com/en-us/download/details.aspx?id=35579

  • Dynamic Region - Item value turns to NULL

    Hi,
    I have a dynamic region which has some APEX_ITEM.CHECKBOX items in it. I count the checkbox groups and write it into a hidden object as like this.
    In the last row of the code i want to insert the count into P65_CNT_QUESTIONS hidden item.
    But when i submit the page i always get NULL from the P65_CNT_QUESTIONS item.
    Before i submit the page i see the correct value in the session but when i submit, it turns to null.
    I am getting crazy Whats the problem with it. Any suggestion?
    System: MS7 - XE - Oracle Database 10g Express Edition Release 10.2.0.1.0 - Product - Apex 4.0
    declare
    cursor c_h is select distinct qh.nquestion_header_id, vquestion_header from tquestions q, tquestion_headers qh
    where q.nquestion_header_id = qh.nquestion_header_id order by 1;
    cursor c_ans is  select nparam_id,vparam  from TQUESTION_PARAMS order by 1;
    l_cnt number := 0;
    l_hid number := 0;
    l_br varchar2(10) := '<br/>';
    l_tab varchar(50) := '      ';
    l_de varchar2(1000);
    l_hea_cnt NUMBER := 1;
    l_que_cnt NUMBER := 1;
    begin
    FOR rec_c in c_h LOOP
    htp.p(l_br||'<b>'|| l_hea_cnt || '-' ||rec_c.VQUESTION_HEADER||'</b>');
      FOR rec_q in
          (SELECT q.nquestion_id, q.vquestion FROM tquestions q where q.nquestion_header_id = rec_c.nquestion_header_id order by q.nrow_order)
      LOOP
        htp.p(l_br|| l_br ||'<div align="left">'|| l_tab ||l_que_cnt || '-' ||rec_q.VQUESTION||'</div>'||l_br );
        FOR rec_ans in c_ans LOOP
           htp.p(l_tab||APEX_ITEM.RADIOGROUP(
           l_que_cnt ,rec_ans.nparam_id,null,rec_ans.vparam));
        END LOOP;
        l_que_cnt := l_que_cnt +1;
      END LOOP;
      htp.p(l_br||l_br ||'<div><b>ARA ORTALAMA</b></div>'); 
      FOR rec_ans in c_ans LOOP
           htp.p(l_tab||APEX_ITEM.RADIOGROUP(
           l_que_cnt ,rec_ans.nparam_id,null,rec_ans.vparam
       END LOOP;
       l_que_cnt := l_que_cnt +1;
       l_hea_cnt := l_hea_cnt +1;
    END LOOP;
    htp.p(l_br||l_br ||'<div><b>GENEL ORTALAMA</b></div>'); 
    FOR rec_ans in c_ans LOOP
       htp.p(l_tab||APEX_ITEM.RADIOGROUP(
           l_que_cnt ,rec_ans.nparam_id,null,rec_ans.vparam
    END LOOP;
        :P65_CNT_QUESTIONS := l_que_cnt ;
    END;

    You need to set "Page items to submit" to be "P2_SCHEME_CAT_CODE"
    This pulls the value from the browser and sets it within session state, thereby making it available to your PL/SQL
    Regards,
    Scott
    blog: [url grassroots-oracle.com]grassroots-oracle.com
    twitter: [url twitter.com/swesley_perth]@swesley_perth

Maybe you are looking for

  • Exclude Hidden File from Time Machine Backup?

    Hi all, Used the Time Machine error message widget, and got the following info: Starting standard backup Backing up to: /Volumes/HD Backup/Backups.backupdb Backup content size: 880.8 GB excluded items size: 247.4 GB for volume Macintosh HD No pre-bac

  • Windows Photo Gallery Warning - Not enough memory

    I am currently going through holiday pictures and deleting a fair few. I have folders that consist of around 1500 pictures, which includes both jpegs and NEFs. When I view these I have no problem for the first say 50 or even 100 at times. Eventually

  • Sync does not appear

    The "SYNC" option does not appear when device is plugged into computer.

  • External service management

    hello, i am working for construction industry. This is   regarding unplanned external service procured by client. They get external service from labour contactors for ex: colouring the wall, plastering the wall etc. which are purely unplanned.They ca

  • [CS5] Create Export PDF Preset w/ High text quality

    Hello, I've created an Export Preset for PDFs using the PDF/X-1a 2001 Standards. I've left all the default settings, and the PDF looks good, but now its been requested that I make the text appear more "crisp". I'm wondering what settings I could twea