Help required in the code
CREATE OR REPLACE procedure pt_load_withouttran1(tabname in varchar2 , tabname2 in varchar2, condition in varchar2) is
--tabname varchar2(100) := 'atlanta_operator';
-- tabname2 varchar2(100) := 'pt_atlanta_operator';
sql_text varchar2(2000) := 'declare ' ||
'type rc_type is ref cursor ;' ||
'rc rc_type;' ||
'v_count number;' ||
'p_sql varchar2(500);'||
'p_sql := '''||' select * from ' || tabname ||' '|| condition || ''';' ||
'dbms_output.put_line(p_sql);' ||
'type temp_type is table of '|| tabname || '%rowtype index by binary_integer;' ||
'temp_tab temp_type;' ||
'begin ' ||
' select to_number(value) into v_count from t2_system_parameter where name=''batch_size'';' ||
' open rc for p_sql;' ||
'loop ' ||
' fetch rc bulk collect into temp_tab limit v_count;' ||
' forall j in 1..temp_tab.count '||
' insert into ' || tabname2 || ' values temp_tab(j);' ||
' end loop;' ||
'commit; end;' ;
begin
execute immediate sql_text;
end;
begin
pt_load_withouttran1('atlanta_operator','pt_atlanta_operator','where atlanta_operator_id is not null');
end;
I am getting a run time error in calling this procedure . Please help.
Hello there.
You end up with a PL/SQL block that does something like :
declare
type rc_type is ref cursor ;
rc rc_type;
v_count number;
p_sql varchar2(500);
p_sql := ' select * from ..... ';
dbms_output.put_line(p_sql);
As you can see, I think it's simply that the last 2 lines above end up in your DECLARE
section, not (as it should be) after the BEGIN.
Regards
Similar Messages
-
I need help I scratched the code off my itunes card
I need help I scratched the code off my itunes card
Click here and ask the iTunes Store staff for assistance. Supply them with as much of the code as you can.
(102006) -
I have tried another exercise, but again I will need help, here's the code
hi,
I have another problem. here's the question pluss the code.
public interface Patient{
public void doVisit(float hour);
public boolean hospitalize();
1. I will need to write a class name OrdinaryPatient which extends Patient.
the class will include value int that his name age and another value that will be boolean
of disease.
I have to do two constructors. one that don't get values and give them default and the other one
that does get values.
another method name docVisit which get a visit to the doctor time visit and will print a message.
the method hospitalize will hospitalize the patient (and if he will have disease he will get true).
and for age I have to write methods of get and set.
2. I will need to write a class of Hipochondriac that extends from OrdinaryPatient.
I have to do two constructors. one that don't get values and make default and the other one that do get values.
I will need to ade int by the name of numberOfHospitalize.
I will need to move the method hospitalize that it will be possible to hospitalize the hypochondriac
on with the value numberOfHospitalize that his small from 5 and if he will hospitalize he will return
the value true.
3. write class PatientClass which will be the method main.
do 10 objects from OrdinaryPatient, 5 that don't get values and 5 will get randomaly age and
chronic disease with true.
do 10 objects from Hipochonidraic, 9 that don't get values and one get all of them.
save all objects in value from Patinet.
print for each of them their age.
print for the OrdinaryPatient alone the method of Hospitalize.
ok, here's what I did.
1. OrdinaryPatient
pbulic class OrdinaryPatient implements Patient{
private int age;
private boolean disease;
public OrdinaryPatient(){
this.disease=false;
this.age=0;
public OrdinaryPatient(int age,boolean ddisase){
this.disease=disease;
this.age=age;
public int getAge(){
return age;
public void setDisease(boolean disease){
this.disease=disease;
public void setAge(int age){
this.age=age;
public void docVisit(){
System.out.println("Patient's visit is one hour");
public boolean hospitalize(){
return false;
2. public class Hipochondriac extends OrdinaryPatient{
private = numberOfHospitalize;
public Hipochondriac();
super();
numberOfHospitalize=0;
public Hipochondriac(int age, boolean diseased, int numberOfHospitalize){
super(age.diseased);
setnumberOfHospitalize(numberofHospitalize);
from here I don't know how to continue.
3. public class PatientClass{
public static void main(String args[]){
patient patinets= new patient[20];
for (int i=0; i<5; i++){
patients= new OrdinaryPatient();
from i'm stuck!!!
if you can help me to improve it I will appriciate it...
Einathere my result.
1. public interface Patient{
public void docVisit(float hour_;
public boolean hospitalize();
public class OrdinaryPatient extends Patient
private int age;
private boolean disease;
//constructors
public OrdinaryPatient(){
age=20;
disease=true;
public OrdinaryPatient(int age, boolean disease) {
setAge(age);
this.disease=disease;
//methods
public int getAge() {
return age;
public void setAge(boolean disease) {
if(age>0 && age<120)
this.age=age;
//overriding methods.
public void docVisit(float hour) {
System.out.println("your visit turn is at "+hour");
public boolean hospitalize(){
System.out.println("go to hospital");
if(disease)
return true;
else
return false;
2. public class Hipochondriac extends OrdinaryPatient{
private int numberOfHospitalize;
//constructors
public Hipochondriac(){
public Hipochondriac(int age, boolean disease, int numberOfHospipitalize){
setAge(age);
this.disease=disease;
this.numberOfHospitalize=numberOfHospitalize
//methods
public int getNumberOfHospitalize(){
return numberOfHospitalize;
public void setNumberOfHospitalize(int numberOfHostpitalize){
if(numberOfHospitalize>0)
this.numberOfHospitalize=numberOfHospitalize;
public boolean hospitalize(){
if(numberOfHospitalize<5)
System.out.println("go to hospital");
numberOfHospitalize++;
return true;
else
return false;
3. public class PatientClass
//constructors
private PatientClass(String[] args){
//private methods helps to build the object.
intialArr(args);
printAge();
gotHospital();
//methods.
private void intialArr(String[] args){
int i;//array index
for(i=0;i<arr.lents/2;i+=2)
arr=new OrdinaryPatient();
arr[i+1]=new OridnaryPatient((int)(Math.random()*121),true);
for(;i<=arr.length-2;i++)
arr[i]=new Hipochondriac();
arr[i]=new Hipochondriac(Interget.parseINt(args[0]),
private void printAge(){
for(int i=0;i<arr.length;i++)
System.out.println(((OrdinaryPatient)arr[i]).getAge());
private void gotoHospital(){
for(int i=0;i<arr.length;i++)
//checking for ordinarypatient objects only
if(!(arr[i] instanceof Hipochondriac))
//dont need casting
arr[i].hospitalize()[
//main method
public static void main(String[] args)
//setting the commandLine array from the main to PatientClass object
PatientClass pc=new PatientClass(args);
let me know if it's seems logic to you.
thank you, Einat -
Program Name which helps to hide the code of abap program
Hello Experts,
Could anybody help me in finding the name of the program on running which we can hide the CODE OF Abap programHere´s a snippet demonstrating how to hide the ABAP code of a given program
REPORT z_hide_abap
NO STANDARD PAGE HEADING.
DATA: gt_code(72) TYPE c OCCURS 0,
gv_code LIKE LINE OF gt_code,
gt_code2(72) TYPE c OCCURS 0.
PARAMETERS: program LIKE sy-repid.
START-OF-SELECTION.
READ REPORT program INTO gt_code.
IF sy-subrc NE 0.
MESSAGE e398(00) WITH 'Report' program 'not found.'.
* ATTENTION:
* READ REPORT on a hidden source code return SY-SUBRC=8 !!!
ENDIF. "IF sy-subrc NE 0
READ TABLE gt_code INDEX 1 INTO gv_code.
* append *special* 1st line to hide cource code
APPEND '*@#@@[SAP]' TO gt_code2.
LOOP AT gt_code INTO gv_code.
APPEND gv_code TO gt_code2.
ENDLOOP.
INSERT REPORT program FROM gt_code2.
Reward points if helpful. -
Would like help with treeset ,the codes that using for sorting, please ?
hi every body. i faced a problem while writing this program, everything worked properly except this one. The program is related to Jframe and it asks the user to add three labels , three text field , one text area and three Jbuttons which are add sort and exit. i could deal with add and exit but sort, i couldn't do it properly because i don't know the codes that should be added in actionperfomed?
These codes are :
package gui;
import javax.swing.SwingUtilities;
import java.awt.BorderLayout;
import javax.swing.JPanel;
import javax.swing.JFrame;
import javax.swing.JLabel;
import java.awt.Rectangle;
import java.util.ArrayList;
import javax.swing.JButton;
import javax.swing.JTextField;
import javax.swing.JTextArea;
import sun.misc.Sort;
import domain.Student;
public class StudentFrame extends JFrame {
* This method initializes btnAdd
* @return javax.swing.JButton
private JButton getBtnAdd() {
if (btnAdd == null) {
btnAdd = new JButton();
btnAdd.setBounds(new Rectangle(13, 135, 59, 27));
btnAdd.setText("Add");
btnAdd.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e) {
btnAddClicked(); // TODO Auto-generated Event stub actionPerformed()
return btnAdd;
protected void btnAddClicked() {
// TODO Auto-generated method stub
String name = txtName.getText();
String id = txtID.getText();
String age = txtAge.getText();
Student s = new Student(name , id , age);
txtArea.setText(String.valueOf(s ));
* This method initializes btnSort
* @return javax.swing.JButton
private JButton getBtnSort() {
if (btnSort == null) {
btnSort = new JButton();
btnSort.setBounds(new Rectangle(95, 136, 62, 25));
btnSort.setText("Sort");
btnSort.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e) {
btnSortClicked(); // TODO Auto-generated Event stub actionPerformed()
return btnSort;
protected void btnSortClicked() {
// TODO Auto-generated method stub
* This method initializes btnExit
* @return javax.swing.JButton
private JButton getBtnExit() {
if (btnExit == null) {
btnExit = new JButton();
btnExit.setBounds(new Rectangle(173, 134, 61, 23));
btnExit.setText("Exit");
btnExit.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e) {
System.exit(0); // TODO Auto-generated Event stub actionPerformed()
return btnExit;
* This method initializes txtName
* @return javax.swing.JTextField
private JTextField getTxtName() {
if (txtName == null) {
txtName = new JTextField();
txtName.setBounds(new Rectangle(79, 11, 60, 23));
return txtName;
* This method initializes txtID
* @return javax.swing.JTextField
private JTextField getTxtID() {
if (txtID == null) {
txtID = new JTextField();
txtID.setBounds(new Rectangle(73, 55, 65, 26));
return txtID;
* This method initializes txtAge
* @return javax.swing.JTextField
private JTextField getTxtAge() {
if (txtAge == null) {
txtAge = new JTextField();
txtAge.setBounds(new Rectangle(74, 96, 61, 24));
return txtAge;
* This method initializes txtArea
* @return javax.swing.JTextArea
private JTextArea getTxtArea() {
if (txtArea == null) {
txtArea = new JTextArea();
txtArea.setBounds(new Rectangle(138, 5, 154, 128));
return txtArea;
* @param args
public static void main(String[] args) {
// TODO Auto-generated method stub
SwingUtilities.invokeLater(new Runnable() {
public void run() {
StudentFrame thisClass = new StudentFrame();
thisClass.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
thisClass.setVisible(true);
* This is the default constructor
public StudentFrame() {
super();
initialize();
* This method initializes this
* @return void
private void initialize() {
this.setSize(300, 200);
this.setContentPane(getJContentPane());
this.setTitle("JFrame");
return jContentPane;
}Edited by: hypocrisy on Apr 26, 2009 6:51 PMThere are three actionPerformed in that program.One for add Jbutton , Sort , and Exit
the codes that i have added for add button after action performed are
String name = txtName.getText();
String id = txtID.getText();
String age = txtAge.getText();
Student s = new Student ( name , id , age);
System.out.println(s);
the codes for Exit button to make it works properly was :
System.out.println(0);
But when i came to Sort Button and i tried to enter many codes but it didn't sort properly so would you like to help me with the right codes :) -
Help for Modifying the Code for display a 7 column table
Hi,
Is someone can help me to modify that code I have a 7 colomn table and as many row as their is results?
Right now, All my result are in a 1 colomn table and and 1 row,
thanks,
Roseline
DECLARE
vtemp varchar2(4000) DEFAULT ' ';
BEGIN
htp.p('<HTML>');
htp.p('<HEAD>');
htp.p('<TITLE>DISQUES C</TITLE>');
htp.p('</HEAD>');
htp.p('<BODY>');
FOR idx IN
SELECT DVD_ID, NomFichier,
row_number() over(partition BY DVD_ID ORDER BY NomFichier ASC) AS rna,
row_number() over(partition BY DVD_ID ORDER BY NomFichier DESC) AS rnd
FROM elements
WHERE PROJET_ID = 1
ORDER BY DVD_ID ASC, rna ASC
loop
IF idx.rna = 1
then
htp.p('<TABLE>');
htp.p('<TR>');
htp.p('<TD>' || idx.DVD_ID ||' </TD> ');
htp.p('</TR>');
htp.p('<TR>');
end IF;
vtemp := vtemp || '<TD>' || idx.NomFichier || ' </TD>';
IF mod(idx.rna, 7) = 0 OR idx.rnd = 1
then
htp.p(vtemp);
vtemp := ' ';
end IF;
IF idx.rnd = 1
then
htp.p('</TR>');
htp.p('</TABLE>');
end IF;
end loop;
htp.p('</BODY>');
htp.p('</HTML>');
end;Sorry:
I have a table contening PROJECT ID, DVD ID and FILES NAME (NomFIchier) that are on the DVD.
In my page result, I want the list of the DVD from a project with the following formatting ( 7 columns table), using PL/SQL.
1 DVD can contain from 5000 files
ex:
Ex:
select DVDNAME, NomFichier fromTABLE where project = 2
*85*
2635080 2636608 2637084 2637091 2637092 2637093 2637147
2637152 2637153 2637154 2637155 2637156 2637157 2637164
*86*
2639497 2639498 2639502 2639504 2639505 2639506 2639507
2639508 2639509 2639511 2639512 2639519 2639521 2639522
******* ******* ******* ******** ********* ******** ******** With this code following code,
DECLARE
vtemp varchar2(4000) DEFAULT ' ';
BEGIN
htp.p('<HTML>');
htp.p('<HEAD>');
htp.p('<TITLE>DISQUES C</TITLE>');
htp.p('</HEAD>');
htp.p('<BODY>');
FOR idx IN
SELECT DVD_ID, NomFichier,
row_number() over(partition BY DVD_ID ORDER BY NomFichier ASC) AS rna,
row_number() over(partition BY DVD_ID ORDER BY NomFichier DESC) AS rnd
FROM elements
WHERE PROJET_ID = 1
ORDER BY DVD_ID ASC, rna ASC
loop
IF idx.rna = 1
then
htp.p('<TABLE>');
htp.p('<TR>');
htp.p('<TD>' || idx.DVD_ID ||' </TD> ');
htp.p('</TR>');
htp.p('<TR>');
end IF;
vtemp := vtemp || '<TD>' || idx.NomFichier || ' </TD>';
IF mod(idx.rna, 7) = 0 OR idx.rnd = 1
then
htp.p(vtemp);
vtemp := ' ';
end IF;
IF idx.rnd = 1
then
htp.p('</TR>');
htp.p('</TABLE>');
end IF;
end loop;
htp.p('</BODY>');
htp.p('</HTML>');
end;I have the following result
85
2635080 2636608 2637084 2637091 2637092 2637093 2637147 2637152 2637153 2637154 2637155 2637156 2637157 2637164 2637169 2637170 2637172 2637173 2637202 2637203 2637213 2637214 2637215 2637216 2637217 2637218 2637219 2637220 2637234 2637235 2637236 2637237 2637239 2637240 2637241 2637242 2637244 2637246 2637247 2637249 2637250 2637251 2637252 2637253 2637257 2637263 2637266 2637269 2637270 2637274 2637276 2637279 2637284 2637290 2637291 2637292 2637293 2637294 2637295 2637296 2637301 2637303 2637304 2637305 2637306 2637311 2637320 2637322 2637324 2637331 2637333 2637336 2637352 2637353 2637354 2637358 2637359 2637360 2637361 2637362 2637363 2637364 2637371 2637378 2637383 2637384 2637385 2637386 2637387 2637388 2637391 2637392 2637395 2637400 2637405 2637412 2637418 2637419 2637423 2637443 2637446 2637453 2637461 2637470 2637483 2637484 2637485 2637494 2637502 2637506 2637507 2637519 2637532 2637536 2637537 2637539 2637540 2637541 2637544 2637553 2637554 2637555 2637557 2637575 2637578 2637579 2637580 2637581 2637582 2637583 2637587 2637588 2637589 2637590 2637591 2637592 2637593 2637594 2637595 2637597 2637604 2637605 2637606 2637611 2637619 2637628 2637629 2637630 2637631 2637632 2637633 2637637 2637645 2637647 2637648 2637650 2637651 2637657 2637658 2637659 2637661 2637662 2637668 2637674 2637676 2637677 2637679 2637680 2637681 2637684 2637685 2637686 2637688 2637689 2637691 2637692 2637694 2637696 2637700 2637701 2637702 2637703 2637704 2637705 2637706 2637707 2637722 2637725 2637741 2637749 2637751 2637752 2637753 2637762 2637764 2637771 2637777 2637779 2637781 2637783 2637785 2637789 2637793 2637809 2637810 2637811 2637812 2637823 2637827 2637836 2637837 2637838 2637845 2637850 2637854 2637855 2637857 2637858 2637859 2637860 2637861 2637866 2637867 2637870 2637874 2637875 2637876 2637877 2637878 2637879 2637880 2637881 2637884 2637885 2637886 2637887 2637891 2637892 2637893 2637894 2637895 2637897 2637898 2637899 2637900 2637901 2637902 2637904 2637906 2637907 2637908 2637909 2637913 2637914 2637916 2637917 2637918 2637919 2637920 2637921 2637923 2637926 2637928 2637929 2637930 2637933 2637935 2637936 2637937 2637939 2637940 2637941 2637942 2637943 2637949 2637950 2637951 2637952 2637954 2637955 2637958 2637965 2637967 2637969 2637970 2637971 2637973 2637978 2637985 2637986 2637987 2637990 2637991 2637992 2637993 2638001 2638002 2638005 2638007 2638009 2638016 2638018 2638020 2638023 2638027 2638029 2638033 2638034 2638035 2638036 2638039 2638043 2638044 2638045 2638046 2638048 2638049 2638052 2638053 2638055 2638057 2638058 2638063 2638064 2638065 2638067 2638068 2638069 2638072 2638076 2638080 2638081 2638082 2638083 2638084 2638087 2638089 2638096 2638097 2638098 2638099 2638100 2638101 2638102 2638103 2638105 2638106 2638108 2638110 2638113 2638117 2638118 2638120 2638121 2638122 2638124 2638126 2638128 2638134 2638135 2638136 2638137 2638139 2638140 2638141 2638143 2638146 2638147 2638148 2638149 2638150 2638151 2638152 2638153 2638154 2638155 2638157 2638159 2638167 2638168 2638172 2638173 2638174 2638175 2638181 2638184 2638185 2638187 2638192 2638193 2638198 2638199 2638200 2638202 2638203 2638205 2638207 2638208 2638209 2638210 2638211 2638212 2638214 2638218 2638219 2638220 2638221 2638223 2638230 2638232 2638236 2638243 2638245 2638246 2638247 2638248 2638258 2638264 2638265 2638268 2638279 2638280 2638281 2638283 2638284 2638287 2638305 2638309 2638310 2638311 2638312 2638316 2638317 2638318 2638319 2638321 2638324 2638330 2638331 2638332 2638333 2638334 2638335 2638336 2638337 2638338 2638339 2638340 2638341 2638342 2638344 2638347 2638349 2638352 2638353 2638364 2638372 2638374 2638376 2638379 2638390 2638391 2638392 2638393 2638394 2638395 2638402 2638405 2638407 2638414 2638421 2638422 2638429 2638430 2638432 2638434 2638438 2638442 2638444 2638457 2638467 2638469 2638474 2638478 2638479 2638480 2638484 2638486 2638488 2638489 2638491 2638506 2638507 2638508 2638510 2638511 2638512 2638513 2638514 2638515 2638516 2638517 2638518 2638519 2638520 2638521 2638522 2638523 2638525 2638527 2638529 2638530 2638531 2638532 2638536 2638537 2638563 2638564 2638567 2638568 2638569 2638618 2638628 2638629 2638634 2638644 2638647 2638649 2638653 2638658 2638666 2638671 2638675 2638677 2638679 2638680 2638685 2638687 2638689 2638691 2638692 2638693 2638694 2638695 2638696 2638697 2638699 2638701 2638702 2638703 2638704 2638705 2638706 2638707 2638709 2638710 2638711 2638712 2638713 2638714 2638720 2638721 2638725 2638726 2638728 2638731 2638732 2638736 2638737 2638739 2638740 2638741 2638744 2638745 2638747 2638748 2638753 2638754 2638755 2638756 2638757 2638760 2638763 2638764 2638768 2638777 2638781 2638782 2638783 2638791 2638793 2638795 2638796 2638798 2638799 2638801 2638810 2638811 2638813 2638814 2638815 2638816 2638817 2638818 2638832 2638833 2638834 2638835 2638836 2638846 2638847 2638848 2638849 2638850 2638851 2638852 2638854 2638855 2638857 2638858 2638859 2638860 2638861 2638862 2638864 2638866 2638867 2638868 2638869 2638870 2638872 2638873 2638874 2638876 2638883 2638884 2638885 2638893 2638895 2638900 2638923 2638927 2638928 2638929 2638931 2638932 2638935 2638936 2638937 2638939 2638942 2638943 2638949 2638952 2638954 2638955 2638956 2638957 2638958 2638959 2638960 2638961 2638962 2638968 2638976 2638978 2638979 2638980 2638983 2638984 2638986 2638988 2638994 2638995 2638998 2638999 2639001 2639002 2639003 2639006 2639011 2639012 2639013 2639014 2639016 2639017 2639018 2639024 2639025 2639030 2639036 2639038 2639039 2639043 2639045 2639046 2639049 2639055 2639057 2639064 2639066 2639067 2639068 2639069 2639072 2639074 2639076 2639079 2639080 2639081 2639085 2639086 2639092 2639098 2639099 2639100 2639101 2639103 2639104 2639105 2639106 2639107 2639109 2639110 2639111 2639112 2639125 2639128 2639129 2639131 2639132 2639133 2639134 2639137 2639138 2639139 2639144 2639146 2639148 2639149 2639159 2639162 2639164 2639165 2639167 2639177 2639179 2639186 2639187 2639188 2639191 2639196 2639197 2639204 2639205 2639208 2639214 2639217 2639218 2639220 2639221 2639223 2639224 2639225 2639226 2639227 2639230 2639236 2639237 2639238 2639239 2639241 2639242 2639246 2639248 2639260 2639262 2639263 2639264 2639270 2639271 2639292 2639293 2639296 2639298 2639299 2639300 2639302 2639303 2639304 2639305 2639306 2639307 2639308 2639309 2639311 2639315 2639316 2639317 2639319 2639321 2639322 2639323 2639324 2639325 2639326 2639327 2639328 2639329 2639330 2639331 2639333 2639336 2639338 2639339 2639341 2639342 2639343 2639344 2639345 2639346 2639348 2639349 2639350 2639356 2639358 2639359 2639360 2639361 2639362 2639364 2639365 2639367 2639368 2639369 2639370 2639373 2639374 2639376 2639378 2639379 2639381 2639386 2639387 2639388 2639389 2639391 2639394 2639396 2639397 2639398 2639400 2639401 2639404 2639405 2639406 2639409 2639410 2639411 2639412 2639419 2639423 2639426 2639427 2639429 2639434 2639437 2639440 2639446 2639448 2639450 2639457 2639465 2639466 2639467 2639468 2639469 2639472 2639473 2639474 2639475 2639478 2639485 2639486 2639487 2639488 2639489 2639491 2639492 2639495
86
2639497 2639498 2639502 2639504 2639505 2639506 2639507 2639508 2639509 2639511 2639512 2639519 2639521 2639522 2639523 2639525 2639527 2639530 2639542 2639543 2639552 2639553 2639554 2639555 2639559 2639560 2639561 2639563 2639564 2639565 2639567 2639574 2639575 2639578 2639579 2639581 2639582 2639584 2639585 2639586 2639587 2639588 2639589 2639591 2639595 2639596 2639597 2639598 2639599 2639605 2639618 2639621 2639623 2639624 2639627 2639628 2639637 2639638 2639639 2639644 2639647 2639648 2639649 2639650 2639654 2639658 2639662 2639665 2639669 I have some sample date here:
http://www.developpez.net/forums/attachments/p57656d1263922095/bases-donnees/oracle/pl-sql/html-affichage-tableaux-conditions/testcase.zip/
I want to know if it's possible to achieve what I want based on the code here.
I'm working on Application Express 3.1.2.00.02
thanks!!
Roseline -
I want to add BWART field from AUFM table to the DS:2LIS_04_P_COMP.
The AUFM table has key fields as :MBLNR,MJAHR and ZEILE.Can someone plz help with the code to put in the existing function module.I see that both 2LIS_04_P_COMP and AUFM have common field AUFNR process order.
Plz help ASAP.I want to add BWART field from AUFM table to the DS:2LIS_04_P_COMP.
The AUFM table has key fields as :MBLNR,MJAHR and ZEILE.Can someone plz help with the code to put in the existing function module.I see that both 2LIS_04_P_COMP and AUFM have common field AUFNR process order.
Plz help ASAP. -
Hi all
we are a MDMP code page system and we upgraded to ECC 6.0.
This is the error iam getting IN UCCHECK for unicode
The system could not perform a static convertibility check on the current
statement, because of untyped or generic operands. It can only carry out this
. runtime.
Whta exactly static convertibility check.
Can anyone suggest what i have to do regarding this
The error is pointing this piece of code
FORM bdc_dynpro *
--> PROGRAM *
--> DYNPRO *
form bdc_dynpro using program dynpro.
clear i_bdcdata.
i_bdcdata-program = program.
i_bdcdata-dynpro = dynpro.
i_bdcdata-dynbegin = 'X'.
append i_bdcdata.
endform.
FORM bdc_field *
--> FNAM *
--> FVAL *
form bdc_field using fnam fval.
clear i_bdcdata.
i_bdcdata-fnam = fnam.
i_bdcdata-fval = fval.
append i_bdcdata.
endform.
This is from the standard include bdcrecx1
Start new screen *
FORM BDC_DYNPRO USING PROGRAM DYNPRO.
CLEAR BDCDATA.
BDCDATA-PROGRAM = PROGRAM.
BDCDATA-DYNPRO = DYNPRO.
BDCDATA-DYNBEGIN = 'X'.
APPEND BDCDATA.
ENDFORM.
Insert field *
FORM BDC_FIELD USING FNAM FVAL.
IF FVAL <> NODATA.
CLEAR BDCDATA.
BDCDATA-FNAM = FNAM.
BDCDATA-FVAL = FVAL.
APPEND BDCDATA.
ENDIF.
ENDFORM.
It looks the same way i wrote the code right.
Thanks
SuchitraHi Srinivas,
This is my actual code
Here iam not comparing FVAL with NODATA
As its being done in SAP Standard code
FORM bdc_dynpro *
--> PROGRAM *
--> DYNPRO *
form bdc_dynpro using program dynpro.
clear i_bdcdata.
i_bdcdata-program = program.
i_bdcdata-dynpro = dynpro.
i_bdcdata-dynbegin = 'X'.
append i_bdcdata.
endform.
FORM bdc_field *
--> FNAM *
--> FVAL *
form bdc_field using fnam fval.
clear i_bdcdata.
i_bdcdata-fnam = fnam.
i_bdcdata-fval = fval.
append i_bdcdata.
endform.
I haven't used the satndard inclue bdcrecx1
which has the code as you mentioned
let me know -
Help Required(Rewriting the query to reduce steps)
With and Without Group ID,I am populating a value into a column,Can anyone please help to write the same query in an other way.This is a sample column.Likewise,there are 5 more columns to be populated.So that I have to write 2 left outer joins for a single column with a little difference.
SELECT
CASE
WHEN T6.ACTUAL_FUNCTION IS NOT NULL
THEN T6.ACTUAL_FUNCTION
WHEN T10.ACTUAL_FUNCTION IS NOT NULL
THEN T10.ACTUAL_FUCNTION
ELSE T5.ACTUAL_FUCNTION
END AF_NOM_PRE_GTEES
FROM
ABC_WT17 T1
INNER JOIN
ABC_CUSTOMER_WT01 T3
ON T1.ORIGINAL_SDS_PARTY_IDR=T3.ORIGINAL_SDS_PARTY_IDR
AND T1.IDR_TYPE_CODE=T3.IDR_TYPE_CODE
LEFT OUTER JOIN /* This is the condition with group ID*/
RESIDUAL_CONTROL T6
ON
T1.NOM_PRE_GTEES = T6.VALUE_MAX
OR
T1.NOM_PRE_GTEES > T6.VALUE_GREATER_THAN
AND
T1.NOM_PRE_GTEES < T6.VALUE_MAX
AND
_ T1.GROUP_ID = T6.GROUP_ID_
AND
T6.FALLBACK_IND = ‘N’
LEFT OUTER JOIN /* this is the condition without Group ID*/
RESIDUAL_CONTROL T10
ON
T1.NOM_PRE_GTEES = T10.VALUE_MAX
OR
T1.NOM_PRE_GTEES > T10.VALUE_GREATER_THAN
AND
T1.NOM_PRE_GTEES < T10.VALUE_MAX
AND
T10.FALLBACK_IND = ‘N’
CROSS JOIN
RESIDUAL_CONTROL T5
ON T5.FALLBACK_IND = ‘Y’
Thanks in advance.KVB wrote:
With and Without Group ID,I am populating a value into a column,Can anyone please help to write the same query in an other way.This is a sample column.Likewise,there are 5 more columns to be populated.So that I have to write 2 left outer joins for a single column with a little difference.
SELECT
CASE
WHEN T6.ACTUAL_FUNCTION IS NOT NULL
THEN T6.ACTUAL_FUNCTION
WHEN T10.ACTUAL_FUNCTION IS NOT NULL
THEN T10.ACTUAL_FUCNTION
ELSE T5.ACTUAL_FUCNTION
END AF_NOM_PRE_GTEES
FROM
ABC_WT17 T1
INNER JOIN
ABC_CUSTOMER_WT01 T3
ON T1.ORIGINAL_SDS_PARTY_IDR=T3.ORIGINAL_SDS_PARTY_IDR
AND T1.IDR_TYPE_CODE=T3.IDR_TYPE_CODE
LEFT OUTER JOIN /* This is the condition with group ID*/
RESIDUAL_CONTROL T6
ON
T1.NOM_PRE_GTEES = T6.VALUE_MAX
OR
T1.NOM_PRE_GTEES > T6.VALUE_GREATER_THAN
AND
T1.NOM_PRE_GTEES < T6.VALUE_MAX
AND
_ T1.GROUP_ID = T6.GROUP_ID_
AND
T6.FALLBACK_IND = ‘N’
LEFT OUTER JOIN /* this is the condition without Group ID*/
RESIDUAL_CONTROL T10
ON
T1.NOM_PRE_GTEES = T10.VALUE_MAX
OR
T1.NOM_PRE_GTEES > T10.VALUE_GREATER_THAN
AND
T1.NOM_PRE_GTEES < T10.VALUE_MAX
AND
T10.FALLBACK_IND = ‘N’
CROSS JOIN
RESIDUAL_CONTROL T5
ON T5.FALLBACK_IND = ‘Y’
Thanks in advance.Thread: HOW TO: Post a SQL statement tuning request - template posting
HOW TO: Post a SQL statement tuning request - template posting -
Hi,
My table data is as below.
Kunnr BDAT EDAT D1 D2 D3 D4 D5
1111 2001 2002 1 2 1 2 1
1111 2003 2008 1 0 4 1 2
1111 2008 2011 1 1 1 1 1
2222 2003 2008 1 2 2 2
2222 2008 2011 1 2 1 1
Here for kunnr between begin and end date we have to caluclate the dependencies. (I.e if there is any value in D1or D2 or D3orD4 it shoulbe counted as 1. of it is zero or blank then it should not be coutned).
for Ex: for 1111 between 2001 & 2002 tot dependencies are 5.
for 1111 between 2003 & 2008 tot dependencies are 4.
in this scenario what will be the best way of writing the code. Do we need to check each and every field when counting the Sum value or and simple way to improve the performance.
Regards,
Vishnu
Edited by: Vishnuvadhan K on May 13, 2011 10:30 AM
Moderator Message: This is not a forum, where you can get your work done by others.
Edited by: kishan P on May 13, 2011 3:52 PMHi Vishnu,
Here, you will have to check for the range of your begin date & end date. If it comes in the said range, then you simply have to add the values of your D1, D2,... DX values which you can store in some variables by setting out a flag as one counter for each.
If your case is satisfied for any of the date range, then just check for the flag values which are satisfied & add them or display the sum of the number of counters.
@Ambujavalli, At End Of won't work here because the date ranges given by Vishnu will differ.
Those statements are useful in a case when suppose for the same field value, you need to calculate a particular sum.
Here, that is not the case. Hence, AT First & At End Of won't work.
Thanks,
Gayathri.
Edited by: gnikesh88 on May 13, 2011 11:52 AM -
Please help me with the code!!
Dear All, I am going to simulate a TCP via UDP , and I have been asked for creating some specific methods , also additional helper methods are allowed but I can't avoid implementing any of the functions described below.
I have bold the functions which are ambiguous to me.
[click here to see the detail assignment explanation|http://www.net.t-labs.tu-berlin.de/teaching/ws0809/PD_labcourse/PDF/u5en.pdf|click here to see the detail assignment explanation]
If you see anything wrong please post , thanks.
• rdt connect()
This function sets all the parameters required for connecting to a server. Moreover, it opens a
UDP socket.
• rdt listen()
This function is the server-side counterpart of rdt connect(). It opens a UDP socket for
incoming connections and sets all the required parameters.
• rdt send()
This function takes an arbirary amount of data as input and writes it into a send buffer. It
does not send anything to the network.
• rdt recv()
This function returns the whole receive buffer. It does not really read data from the network,
but only from the receive buffer.
• rdt select()
This function does the whole work of moving data over the network. It behaves similar to the
system call select(), i.e. it blocks until there is some data in the receive buffer. The received
data can be subsequently read with rdt recv(). A flow diagram of the functionality of this
function follows:
– send all()
This function sends all the data in the send buffer over the network to the receiver. If
more than 500 bytes are present in the send buffer, more packets must be sent. The MSS
(Maximum Segment Size) of an RDT packet is 534 bytes.
*– select()*
This is the well-known system call that waits until the receive buffer contains data.
[ I don't know what to do with the buffer , and how to make it empty]
– recv from()
This is the well-known system all recv from() that reads data from the network.
*– statemachine send()*
This is a function that processes a newly received packet. In RDT 1.0 nothing is done here,
becuase the sender does not expect any ACK packets from the receiver.
– statemachine recv()
This function processes incoming packets. In RDT 1.0 the header is removed and the
payload copied to the receive buffer.
– Payload
rdt select() returns at this point if there’s any data in the receive buffer. If not, it starts
from the beginning.
[ where the data should be returned?]
This is my code:
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.net.DatagramPacket;
import java.net.DatagramSocket;
import java.net.InetAddress;
import java.net.Socket;
import java.net.SocketException;
public class Ex5 {
DatagramSocket socket , client_socket;
DatagramPacket rcv_pkt;
DatagramPacket send_pkt;
byte[] sendData;
byte[] receivedData;
InetAddress ipaddr;
int client_port;
public void rdt_connect(String host , int client_port) throws IOException{
this.client_port = client_port;
client_socket = new DatagramSocket();
ipaddr = InetAddress.getByName(host);
public void rdt_listen(int port) throws SocketException{
//byte[] buffer = new byte[1024];
socket = new DatagramSocket(port);
//DatagramPacket packet = new DatagramPacket(buffer, buffer.length );
public DatagramPacket rdt_send() throws IOException{
sendData = new byte[534];
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
String inString = in.readLine();
sendData = inString.getBytes();
DatagramPacket send_packet = new DatagramPacket(sendData,sendData.length, ipaddr,client_port );
return send_packet;
public DatagramPacket rdt_recv(byte[] receivedData) throws IOException{
//byte[] receivedData = new byte[1024];
DatagramPacket received_packet = new DatagramPacket(receivedData, receivedData.length );
//socket.receive(received_packet);
return received_packet;
public byte[] rdt_select() throws IOException{
rcv_pkt = new DatagramPacket(receivedData,receivedData.length);
while(!receivedData.equals(null)){
return receivedData;
send_all();
return null;
public void send_all() throws IOException{
rcv_pkt = this.rdt_send();
client_socket.send(rcv_pkt);
public DatagramPacket select(){
DatagramPacket local_rcv_pkt = null;
while(receivedData != null){
//local_rcv_pkt = rcv_pkt;
return local_rcv_pkt;
public void recv_from() throws IOException{
rcv_pkt = select();
socket.receive(rcv_pkt);
public void statemachine_send(){
public void statemachine_recv() throws IOException{
String data = new String(rcv_pkt.getData());
receivedData = data.getBytes();
rcv_pkt = this.rdt_recv(receivedData);
}public class Ex5 {
DatagramSocket socket , client_socket;Surely you're not expected to implement the client and the server in the same class?
while(!receivedData.equals(null)){
return receivedData;
}This is just nonsense.
public DatagramPacket select(){See java.nio.channels.Selector.
while(receivedData != null){
//local_rcv_pkt = rcv_pkt;
}More nonsense.
I suggest if you don't understand the assignment you advise those who gave it to you, and/or review whatever supporting information you were supplied or have been taught. -
Hi all,
I need help in acquiring this
I have a table control,in which i have 3 columns out of which 2 are input/outfields and one is output field.
say i have fld1 fld2 fld3
i entera value for fld1 and fld2 then it bring value in fld3.
but sometimes i.e certain values of fld1 the fld2 should be NA and the fld3 should open up for input.
say fld1 = def is exception
first i enter
fld1 = abc and fld2 =aaa then it brings fld3 =bbb
next i enter
fld1 = def and hit enter then fld2 = NA and fld3 should be available for input.
I have the following code written for this
CONTROLS: TABLECONTROL TYPE TABLEVIEW USING SCREEN 9002.
DATA W_TABLECONTROL LIKE LINE OF TABLECONTROL-COLS.
ITAB IS MY TABLE CONTROL INTERNAL TABLE I.E MY TABLE CONTROL FIELDS ARE ITAB-FLD1,ITAB-FLD2,ITAB-FLD3.
loop at TABLECONTROL-cols into w_TABLECONTROL.
IF w_cTABLECONTROL-screen-group4 = 'NAM'.
loop at iTAB.
IF ITAB-FLD1 EQ 'DEF'.
w_TABLECONTROL-SCREEN-INPUT = '1'.
else.
w_TABLECONTROL-SCREEN-INPUT = '0'.
ENDIF.
modify TABLECONTROL-cols from w_TABLECONTROL.
ENDLOOP.
ENDIF.
ENDLOOP.
WHAT I SEE NOW WITH THIS CODE IS WHEN I ENTER THE FIRST RECORD IN
ITAB-FLD1 AS DEF AND HIT ENTER THE FLD2 IS NA AND FLD3 IS READY FOR OUTPUT
NOW THE SECOND ROW FLD3 IS AVAILABLE FOR INPUT WHICH I DON'T WANT BECAUSE MY FLD1 OF SECOND IS NOT YET KNOW AGAIN IFITS DEF THEN IT SHOULD BE AVAILABLE FOR INPUT OTHERWISE IT SHOULD GREY OUT.
HELP ME IN ACHEIVING THIS.
THANKSHi,
Have this code inside the LOOP AT ...ENDLOOP of the PBO..
PROCESS BEFORE OUTPUT.
LOOP AT ITAB INTO WA..
<b>MODULE UPDATE_DATA..</b>
ENDLOOP.
MODULE UPDATE_DATA.
LOOP AT SCREEN.
IF WA-FIELD1 = 'DEF'.
Add the group for the field3 in the attributes..
IF SCREEN-GROUP1 = 'G1'.
Enable for input...
SCREEN-INPUT = '1'.
MODIFY SCREEN.
ENDIF.
ELSE.
IF SCREEN-GROUP1 = 'G1'.
disable for input for other values.
SCREEN-INPUT = '0'.
MODIFY SCREEN.
ENDIF.
ENDIF.
ENDLOOP.
ENDLOOP.
Thanks,
Naren -
Help required for the users report requirement
Hello,
User requirement is to get the report as follows
Period planned order Production order Backlog
Feb2008 15 3 18
March2008 4 11 15
Backlog is the formula for planned order & production order.
My problem is that, In the cube the data for planned order is the char value 'X' or a blank.
It has to count the total of planned order for the entire month of feb,& print the value counting the number of 'X',here as shown as 15.
Planned order, Production order are in rows & are chracteristics.
Is thr any solution to count master data which has a char value(X).
I have tried using the formula variable.I had created the new formula.Then using the data functions as count(Formula variable),using the replacment path.But it did not work
Help me out to find the total for the char value of the master data.
Help would be rewarded!Hello,
For BACKEND:
1) Create a normal KF say counter and include it in the cube.
2) Now you can populate the value for this KF via end routine in transformation.
3) You need to check whether the value for planned order is X. If yes then update KF with value 1.
4) I hope you can take care of this routine part. Once this is done the data in the cube might look in below manner:
Month Planned-Order Counter
Feb 2007 | X | 1
Feb 2007 | X | 1
Feb 2007 | | 0
Feb 2007 | X | 1
Feb 2007 | | 0
Mar 2007 | | 0
Mar 2007 | X | 1
Mar 2007 | | 0
Mar 2007 | | 0
Mar 2007 | X | 1
Now in the report if you include month and counter the report will look like
Month Counter
Feb 2007 | 3
Mar 2007 | 2
If you see the counter is getting aggregated to give you the sum against the value of planned order as X against month.
I think this should work.
If this dosent work let me know i will let you the alternate solution for frontend. but for that too you need to make the above backend changes.
So do the backend changes and try to use counter KF for showing planned orders and i think it should work fine.
Regds,
Shashank -
Efilogin-helper requires for the discrete graphic card
After updating to the latest version of osx on my 2014 macbook pro 15.
There is a process named efilogin-helper always requesting for the discrete graphic card and taking the energy and CPU..
Is there any solution to fix this problem??I have to use a software to change the graphic card to integrated one only..
-
Help required understanding the purpose of having instance Init blocks
I want to know exactly what the purpose of having instance initialization blocks in Java. As in static init blocks, we can execute some commands before creating an instance of a class.
And also in instance init blocks, we are executing some commands which we can do in a constructor. So Im little bit confused of the purpose of having this concept instance init blocks without writing it in the constructor itself.
Really appreciate if anyone can explain this ASAP as I am still a beginner who is studying for SCJP exam.
Thanks in advance.The instance initialization blocks are always executed before the constructor code is executed. This may be used for some activity which is common to all constructors (in case constructors are overloaded).
Maybe you are looking for
-
MacBook Pro Retina (Mid-2014) Cannot Boot Camp
Hi all, I'm running OS X Yosemite (10.10.2) on my MacBook Pro Retina 13" (Mid 2014). I have tried to boot camp the machine but it's not working. After boot camp assistant has created the Windows 8.1 installation disk and saved all the drivers and sof
-
Im in the process of downgrading my ios 7 to 5.1.1 but when I tried to open my previos ios and back to itunes, i can't find the restore settings and the itunes is in original menu... What will I do? please help me... thanks in advance...
-
What is the use of the SAML2Keystore
What is the use of the SAML2Keystore and what is the key service passphrase used in Oracle WebCenter Analytics 10.3
-
Using external Variables between proxies in OSB
Hello there, Im trying to figure out if it is possible, to store some kind of message (could be payload, XML, or just a string) to an external variable so it could be reused among different proxies. Anyone knows if this is possible, and if yes, how c
-
[Ann] D.eval() API brings eval() to Flex 2
The D.eval() (read DEE-val) API is a SWC library for Flex 2 applications to execute text strings of dynamic ActionScript expressions and programs. The language used in D.eval() is called Deval, a subset of ActionScript 3 (AS3). It supports all the AS