How to display record in hyperlink in JSP?
Does any knows how to display the records in hyperlink? That's mean when I retrieve data from one database....two records...let's say peter and thomas....then i want the two records display in hyperlink....that's mean two records can be clicked by the user....and after the user clicked on either one of the record.....the record's value will be able to pass to the other page for use...
Can anyone pls help me of this?Thank in advanced....
This will pass the Value from the DB as Query Parameters to the Target JSP.
Peter
Thomas
Similar Messages
-
i have 100 records can anybody tell me how i display records 10 at atime in jsp & by clicking the next button another 10 records displays in the same jsp. How i can do that thing.
You have to implement a page breake yourself.
Simple scenario would be to store a page number into a session:
session.setAttribute("page", selectedPage)
every time user clicks on a next page link
When displaying the record read the page and display only those which should be on the page
Integer selectedPage = session.getAttribute("page")
if (selectedPage == null) selectedPage = 1;
//display code goes here -
How to display records into a non table base block..
Hi,
Can anybody help me how to display records into a non table base block....
Find below is my coding but it only display the last record in the first line
in the block.
PROCEDURE CREATE_CARTON_QUESTION IS
CURSOR car_c IS
select /*+ rule */ question_id, question_description
from WHOP.QADB_QUESTIONS
where question_category = 'Carton'
and question_active_flag = 'Y';
v_found VARCHAR2(10);
v_status boolean;
v_error varchar2(150);
v_count number;
car_r car_c%rowtype;
begin
begin
select count(*) into v_count
from WHOP.QADB_QUESTIONS
where question_category = 'Carton'
and question_active_flag = 'Y';
exception
when no_data_found then
v_count := 0;
end;
if v_count > 0 then
for car_r in car_c loop
---populating carton questions
:la_carton.carton_question_id := car_r.question_id;
:la_carton.carton_question_answer := 'N';
:la_carton.carton_error_details := null;
:la_carton.attribute2 := car_r.question_description;
end loop;
end if;
end;
Thanks in advance.
Regards,
JunHi SNatapov,
Thanks for you reply but still I get this error...
FRM-40737 Illegal restricted procedure GO_BLOCK in WHEN-VALIDATE-ITEM trigger.
Please note that I call that program unit in the last field of my control block inside when-validate-item trigger the questions should be display in la_carton block which is my non-base table block.
Find below is the code....
begin
go_block('la_carton');
first_record;
for car_r in car_c loop
---populating carton questions
:la_carton.carton_question_id := car_r.question_id;
:la_carton.carton_question_answer := 'N';
:la_carton.carton_error_details := null;
:la_carton.attribute2 := car_r.question_description;
next_record;
end loop;
end;
Hoping you can help me this problem...
Thanks in advance.
Regards,
Jun -
How to display a pdf file in jsp
hi,
How to display a pdf file in jsp iam having a class which will return fileinputstream of the file object. the pdf file is in server.
regards
ArulA JSP is a combo of HTML and Java, so you can't really "display" a PDF file in a JSP.
You can provider a href link to the PDF file in your JSP.
You can use some utility package to read the contents of the PDF, pull certain things out of it, and display that in your JSP as html
In a servlet you can set the content type to application/pdf and write the binary data of the PDF back to the browser. Once the browser finishes reading in the data it should open the PDF. -
How to display records of int. table in list tree?
friends,
i want to display a list tree using fm RS_TREE_CONSTRUCT and RS_LIST_DISPLAY.
this is the data that i have to display
Matnr doc no. Stock qty. Age
1 45601236 100 55
1 45601237 10 54
1 45601238 11 53
1 45601239 101 52
now, only the first record should be displayed with a + symbol... when the user clicks the + symbol, then the node has to expand and display the other 3 records pertaining to that material...how to display 4 fields of an internal table in one line and like that, 3 records...i have seen some threads relating to this, but they all display only one value in the child node..how to display multiple fields like this?
please address this functinality using FMs alone, as i am not exposed to objects :!
thanks all
Sathish. Rsatish,
Before passing the Node name ,Concatenate all the values of record in one string and pass that string as node name.Now it will work.
To develop the basic logic simple program name is :
"SAPSIMPLE_TREE_CONTROL_DEMO" In this program use above logic.
Don't forget to reward if useful.
Don't forget to reward if useful -
How to display URL of Trex on JSP
Hi, Master:
I am working on B2B Java part. on JSP:
I need display where trex server located (URL) ie: http://lpaux001:50000, can I and how?
Cheers,
EricDuplicate of thread Re: in B2B java, how can I find server url in JSP?
Easwar Ram
http://www.parxlns.com -
How to display rows of data in JSP?
Hi,
I am learning Servlet and JSP. There is an exercise which requires us to access a database from a Servlet and display the retrieved data in a JSP.
Now I am ok with the database connection. So how to display the data using some kind of loop?
RegardsThey're called ResultSets and they are returned when you execute a query from a Statement. The next() method will tell you whether or not you have another row of data to read.
-
How to display records when clicking button in alv
I am using screen painter to create two buttons
'classical' and 'alv'.
When i click the first button control should move to
corresponding classical program.Evan i got the answer
I am not able to display the "select-options button" in the
output as in classical report program.
It displays all records instead of selecting particular records from select-option button.
So how to display the select option button(i.e in the classical view program) while "clicking the classical button " .
plz send me the coding....hi,
try this.
SELECTION-SCREEN BEGIN OF SCREEN 100.
SELECT-OPTIONS : EBELN FOR V_EBELN MODIF ID G1,
VBELN FOR V_VBELN MODIF ID G2.
SELECTION-SCREEN END OF SCREEN 100 .
PAI.
module mod_name.
case sy-ucomm.
when 'BUTT!'.
call selection-screen 100.
when 'BUTT2'.
""""your ALV logic"""".
endcase.
endmodule.
if...any doubts revert back.
Regards
Sandeep Reddy -
How to display records that match user input date
hi all,
i need to display records that match user input date (i.e., for example if the difference between user input date and record date is less than 5 years then display those records) , this is for hr bw. any exit is there to check for validation for records to be displayed based on some abap coding.
vijayI just see getApplication method but "Retrieves a list of all the deployed applications."
My scenario is: I get user, end i want to discorver how application this user i enable to see. -
How to display record in column mode?
Hi,
I have difficulty in displaying record in column mode.
Example: I have CALENDAR table with column DATECOL
CALENDAR
DATECOL DATE
Data in CALENDAR table is follow : 1/1/06, 2/1/06, 3/1/06, 4/1/06, 5/1/06, 6/1/06
How to create SELECT statement so result will be follow:
DATECOL 1 2 3 4 5 6
Any advise from you ?
RegardsHi,
Try this:
DECLARE
z_result VARCHAR2(2000) := ' ';
CURSOR c1 IS
SELECT DATECOL
FROM CALENDAR;
BEGIN
FOR i IN c1 LOOP
z_result := z_result || TO_CHAR(i.DATECOL,'DD') || ' ';
END LOOP;
DBMS_OUTPUT.ENABLE;
DBMS_OUTPUT.PUT_LINE('DATECOL ' || z_result);
END;
Peter D. -
How to display List of objects in jsp?
Hi,
I have a list containing Collection of bean objects.
Now I want to display the values in the list of objects in a jsp using JSTL.
Any body help me how to retrieve the bean objects from the List and how can i display that values in the jsp.
Advanced Thanks,
MahendraHave you tried to use <:forEach></c:forEach> tag available in jstl?
-
JSP: How do display list of objects in jsp table?
sorry that my question my confuse you, let me explain more.
in my java class, have method : public List retrieveAllVacancies(); and it returns a list of available vacancies.
on my jsp page, i want to display the vicancies in the table have 3 rows:
vacancy title | location | contract type
should i use some form of for loop or iterator to get the vacancies in the list? how does the jsp page get the list of objects?
anyone can help me? thanksi found out the actual thing i look for is how to pass the vector to the jsp page.
<table>
<%
Vacancy vacancy= new Vacancy();
Vector allVacancies = new Vector();
*//allVacancies = (java.util.Vector)request.getAttribute("allVacancies");*
if(allVacancies.size() == 0)
out.print("<br><br><br> There are no vacancies available!!");
else
%>
<tr>
<td>Vacancy Title</td>
<td>Contract Type</td>
<td>Location</td>
</tr>
<%
for (int i=0;i<allVacancies.size();i++)
vacancy = (Vacancy)allVacancies.get(i);
%>
<tr>
<td><% out.print(vacancy.getVacancyTitle());%></td>
<td><% out.print(vacancy.getContractType());%></td>
<td><% out.print(vacancy.getVacancyLocation()); %></td>
</tr>
<%
%>
</table>*//allVacancies = (java.util.Vector)request.getAttribute("allVacancies");*
if i have this line, when i open the jsp page it will gives NullPoniterException.
the following was what i found for the similar problem,
You can add the Vector to the HttpSession with_
session.setAttribute(String name, Object value)_
or to the ServletRequest with_
request.setAttribute(String name, Object value)._
In the other JSP, retrieve the value with_
session.getAttribute(String name)_
or to the ServletRequest with_
request.getAttribute(String name)._
but i tried to do in this way it didn't work. for sure i didn't do it correctly. could anybody give bit more explanation about how to pass the Vector to the jsp page?
any help would be appreciated. -
How to display XML content in a JSP
Hi,
can anyone help me in displaying xml content in a JSP?I think you want to display value from XML page to the
JSP.If thats the case you can try out this
xml...
<component-profile>
<property name="parm" value="Hi"/>
</component-profile>
jsp...
<% var=profile.getProperty("parm");%>
Hope this helps
gEorgE -
How to Display Record Count on Search page?
Hi
I am new to OAF and one of the requirement is to display record count on Search page . I followed the same steps in Emp Search page as an example and created my search page.
I followed the following steps
1) I created a transietn Attribute in VO by name RecordCount
2) I had written a method in AMImpl
public void getRecordCount() {
OAViewObject vo = getXXG2SourceAcctSearchVO1();
int fetchedRowCount = vo.getFetchedRowCount();
String msg = fetchedRowCount + " are retrived by query ";
System.out.println(msg);
String xfetchedRowCount = Integer.toString(fetchedRowCount);
System.out.println("xfetchedRowCount : " + xfetchedRowCount);
OARow reportRow = (OARow)vo.createRow();
System.out.println("in set attribute");
reportRow.setAttribute("RecordCount",xfetchedRowCount); // I am using this way and trying to display record count into RecordCount view Attribute
}//getRecordCount
3) on the SearchPG, I created a new messageStyledtext by name RecordCount and assinged VO and viewAttribute accordingly
I am not able to see record count when i run the page ?
Am i missing any steps ?
I see the messages in the log file but not in Record count box ?
Any suggestions?
Thanks
RaviHi Anoop
i made the code change according to you and because of the following condition, it is createing a" new row" in the search page
Row row = vo.createRow();
vo.insertRow(row);
For every search it is creating a new blank row in search page .
I did some more research and modified my code as
public void getRecordCount() {
OAViewObject vo = getXXG2SourceAcctSearchVO1();
int fetchedRowCount = 0;
fetchedRowCount = vo.getFetchedRowCount();
String msg = fetchedRowCount + " are retrived by query ";
System.out.println(msg);
//vo.setMaxFetchSize(0);
//vo.executeQuery();
if (fetchedRowCount == 0 )
Row row = vo.createRow();
//row = (OARow)vo.first();
row.setAttribute("RecordCount", "0");
else
String xfetchedRowCount = Integer.toString(fetchedRowCount);
System.out.println("xfetchedRowCount : " + xfetchedRowCount);
Row row = vo.createRow();
//vo.insertRow(row);
row.setNewRowState(Row.STATUS_INITIALIZED);
// Set the primary key value for this single-row VO.
row = (OARow)vo.first();
row.setAttribute("RecordCount", xfetchedRowCount);
and in AM , I am calling this method in PFR as follows
public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
super.processFormRequest(pageContext, webBean);
OAApplicationModule am1 =
(OAApplicationModule)pageContext.getApplicationModule(webBean);
am1.invokeMethod("getRecordCount");
now i see the record count on the search page . but after 2-3 searches, the record count value is not populating the correct value. its weird
Any suggestions
Thanks
Ravi -
How to display records of a table
I'm using PNP LDB in my report and I'd like to display how many records I have so I wrote this code
If i_tab is not initial.
DESCRIBE TABLE i_tab LINES counter.
WRITE counter .
Endif.
but I'm getting wrong result. Can anybody help please.Hi muralikrishna kaipha,
I can't believe this.
TOP-OF PAGE page is triggered before the first line is written to a page. That means TOP-OF PAGE is triggered by first write statement in program. INITIALIZATION is normally not used to write anything.
You must avoid to write more than one page during TOP-OF PAGE event because this will trigger TOP-OF PAGE recursively endless.
Think about it.
Regards,
Clemens
Maybe you are looking for
-
Two separate apple id's to one?
I have one apple ID for my itunes account and i have a different apple ID for iCloud and email... Is there a way I can get rid of the itunes one and put everything into the apple ID i have for my iCloud? Reason being is that i am getting rid of my em
-
Hi All I Received this error. ORA-00600: internal error code, arguments: [12235], [], [], [], [], [], [], [] Anybody know symptom for the same. Thanks, Vishal
-
I have LR 5.7. Some weeks ago it stopped creating previews upon import It will not let me build them either. All I get is grey boxes in the Library middle. In Develop it will only show 3 previews in any one folder at a time I have tried re-installing
-
Avoid printing the Country name in the SAP Script
Hi All, I am printing the address of the ship to customer in SAP script using ADDRESS and ENDADDRESS. The address is formatting based on the country code that I am passing in the COUNTRY parameter. Everything looks fine. But here my requirement is I
-
PHP 5.2.17 and Oracle 8i
Hi there, I encountered a problem that I have spent hours fixing that. Here is the problem: I am trying to connect to a remote Oracle 8i server using Oracle 11g client: here is my connection string in PHP: $conn = oci_connect('db_user', 'db_pass', "d