Problems with the primary key of the query string
Moving from asp to php, to work with David Power's book: The Essential Guide to Dreamweaver CS4 with CSS, AJAX, and PHP. Recycling of my brain, so starting from scratch in the learning process.
Everything was going perfectly until I tried to add the primary key of a record in a query string. I compared my code with the example code for the book, and everything matches. When previewing the page in my browser and hover over the link which must pass the main code on the next page, the query string does not appear correctly. It shows user_id = but no figure shows, as it is supposed to. www.webpage.com/update_user.php?user_id=
Here is my code: (Please note, <>have been removed, as I was unable to find a way view the code in the correct way here (copy/paste was doesn't work do not, nor insert syntax))
? PHP {?}
? PHP echo $row_listUser ['family_name'];? PHP echo $row_listUser ["FirstName"];?
? PHP echo $row_listUser ['username'];? ? PHP echo $row_listUser ["admin_priv"];?
a href = "update_user.php? user_id =? php echo $row_listUser ['user_id'];?" "Edit / has
a href = "delete_user.php? user_id =? php echo $row_listUser ['user_id'];?" ' Delete / has
? PHP} while ($row_listUser = mysql_fetch_assoc ($listUser));?
Any ideas that could help me understand why this part does not in particular would be greatly appreciated. Writing to the database worked perfectly, I see that there are numbers in the database as user_id, and it is defined as my primary key in the configuration database. Such a simple process that is causing me headaches!
Thank you
You have the code to request a copy in your folder:
$query_listUser = 'SELECT user_id, username, first_name, family_name, admin_priv from users ORDER BY family_name ASC';
$listUser = mysql_query ($query_listUser, $connSCFDIR) or die (mysql_error ());
$row_listUser = mysql_fetch_assoc ($listUser);
$totalRows_listUser = mysql_num_rows ($listUser);
$query_listUser = 'SELECT username, first_name, family_name, admin_priv from users ORDER BY family_name ASC';
$listUser = mysql_query ($query_listUser, $connSCFDIR) or die (mysql_error ());
$row_listUser = mysql_fetch_assoc ($listUser);
The $listUser table will contain the results of the second query, which does not include the field user_id. delete the redundant code.
Tags: Dreamweaver
Similar Questions
-
problem with the query insert masking character @.
Hi the gems...
I do through xml schema, run... means using a batch file, I'll call the xml files and the xml file contains the names of files containing all the DDLs and LMD...
No problem with the DDL...
now when I run the LMD, all are working well except a few insert scripts...
Insert into TABLE_NAME (EVENT_ID, EVENT_DESC, EVENT_MESSAGE_TEMPLATE, EVENT_MESSAGE_SUBJECT) values (4, 'abcdefgh',)
'Hi,
Order details:
@Order_ID #.
@Instrument_ID #.
This is an automated email. Please do not reply.',
"executed");
This kind of scripts insert failed with the error "[ora: sqlplus] SP2-0310: could not open the file" Order_ID #, .sql.
This problem is due to the @ character before the data...
problem doesn't happen when I run the script explicitly, xml perform only the origin of the problem
So, I need to know if there is a way to hide the sign @...
Please help... Thanks in advanceuser12780416 wrote:
"[ora: sqlplus] SP2-0310: could not open the file" Order_ID #, .sql.In SQL * more the @ character means: run a script. That would explain the error message.
The real problem is that your chain is written on several lines. A string like this might work:{code}
Insert into TABLE_NAME (EVENT_ID, EVENT_DESC, EVENT_MESSAGE_TEMPLATE, EVENT_MESSAGE_SUBJECT) values (4, 'abcdefgh',)
"Hi," | Chr (10)
||' Order of details :'|| Chr (10)
|' @Order_ID #' | Chr (10)
|' @Instrument_ID #' | Chr (10)
||' This is an automated email. Please do not respond. »
"executed");
{code}But it might not be a usable workaound.
As you create the string insert sort, you might be able to replace all line breaks in the present with you own custom lines.Replace (yourEventMessage, Chr (10), "' |) Chr (10): "')
-
Problem with the query in the form of customization mode
Hi all
Can you please help me I'm getting problem while doing the customization form
Scenario:
Marter dot org form that I need to display the default value in the field of the unit of MEASURE value is null
I succeed while doing all the steps below
Condition tab:
----------------------
Trigger the same: ONCE - NEW - ITEM - INSTANCE
Trigger object: MTL_SYSTEM_ITEMS. INVENTORY_ITEM_MIR
Action tab:
------------------
Type: property
type of object: agenda
Trigger object: MTL_SYSTEM_ITEMS. PRIMARY_UNIT_OF_MEASURE_MIR
Property name: VALUE
Value: null
but the problem is when I try to query (F11) the form, I'm not able to ask please help me with the of this
Thank you
EABRThe problem is, you assign a value to an element when the form is opened, so the form will update mode, so the system not allowing you to make the request (f11). If you clear the value that has been missed, you'd be able to F11.
So instead set the VALUE, try the INITIAL_VALUE property and let me know if this worked for you.
Thank you
Pradeep -
Problem with the query.
I created these queries, but is based on the number of files w_Candidates_Pending, w_Candidates_Pending_Revoked this status I have to set one flag either 1, 2 or 3.
1 = when 1 or more records for a candidate given pending status,.
2 = when 1 or more records for a candidate given awaiting status revoked.
3 = in another State.
Can u please help me add County in the query and count on the basis, I put 1 one flag.
WITH w_Pending AS
(SELECT resource_status_id
OF ems.resource_status
WHERE resource_status_desc = 'pending '.
),
w_Pending_Revoked AS
(SELECT resource_status_id
OF ems.resource_status
WHERE resource_status_desc = 'revoke pending. "
),
w_Candidates_Pending AS
(SELECT DISTINCT ec.ems_candidate_id,
Eres.resource_status_id,
Eres.candidate_id
Of ems_candidate ec,.
employee_resources eres
WHERE ec.ems_candidate_id = eres.candidate_id (+)
AND eres.resource_status_id = (SELECT resource_status_id FROM w_Pending)
AND eres.through_date IS NULL
),
w_Candidates_Pending_Revoked AS
(SELECT DISTINCT ec.ems_candidate_id,
Eres.resource_status_id,
Eres.candidate_id
Of ems_candidate ec,.
employee_resources eres
WHERE ec.ems_candidate_id = eres.candidate_id (+)
AND eres.resource_status_id = (SELECT resource_status_id FROM w_Pending_Revoked)
AND eres.through_date IS NULL
)
SELECT DISTINCT CND.ems_candidate_id,
CND. Name,
EEJ.ems_job_id,
(SELECT CASE WHEN COUNT (1) = 0 THEN ELSE 'ADD' END 'n')
OF wCP w_Candidates_Pending
WHERE wCP.candidate_id = cnd.ems_candidate_id) pending_flag;
(SELECT CASE WHEN COUNT (1) = 0 'N' THEN ELSE 'REVOKE' END)
OF w_Candidates_Pending_Revoked wCPR
WHERE wCPR.candidate_id = cnd.ems_candidate_id) pending_revoked_flag
OF ems.ems_candidate cnd.
EMS.employee_resources err,
EMS.ems_jobs EJE,
Rsg EMS.resources_group,
EMS. Groups grp
WHERE cnd.ems_candidate_id = err.candidate_id
AND eej.ems_job_id = cnd.ems_job_id (+)
AND err.resource_group_id = rsg.resource_group_id
AND rsg.group_id = grp.group_id
AND err.through_date IS NULL
AND IN grp.group_id
(SELECT DISTINCT grpe.group_id
Groups_employee grpe, employee emp
WHERE grpe.person_id = emp.person_id
AND grpe.person_id = i_logged_in_person_id);
Maybe
Select ems_candidate_id,
name,
ems_job_id,
cases where count_pending > 0 and count_pending_revoke is null
then 1
When count_pending_revoke > 0 and count_pending is null
then 2
When count_pending > 0 and count_pending_revoke > 0
then 3
end indicator
(Select cnd.ems_candidate_id,
CND. Name,
EEJ.ems_job_id,
RSS.resource_status_id,
RSS.resource_status_desc,
ROW_NUMBER() over (partition of cnd.ems_candidate_id
order of rss.resource_status_desc
) rn,.
sum (case rss.resource_status_desc when 'waiting' then 1 end) on
(cnd.ems_candidate_id order of value null partition
lines between unbounded preceding and following unlimited
) count_pending,.
sum (case rss.resource_status_desc when 'pending Revoke' then 1 end) on
(cnd.ems_candidate_id order of value null partition
lines between unbounded preceding and following unlimited
) count_pending_revoke,.
Count (*) over (partition by order cnd.ems_candidate_id by null
lines between unbounded preceding and following unlimited
) count_candidate_rows
of ems.ems_candidate cnd.
EMS.employee_resources err,
EMS.ems_jobs EJE,
Rsg EMS.resources_group,
GRP EMS. Groups,
EMS.resource_status rss
where cnd.ems_candidate_id = err.candidate_id
and eej.ems_job_id = cnd.ems_job_id (+)
and err.resource_group_id = rsg.resource_group_id
and rsg.group_id = grp.group_id
and err.through_date is null
and grp.group_id in (select distinct)
GRPE.group_id
of groups_employee grpe.
employee emp
where grpe.person_id = emp.person_id
and grpe.person_id = i_logged_in_person_id
)
and err.resource_status_id = rss.resource_status_id
)
where rn = 1
Concerning
Etbin
-
Problem with the query and date
I'm trying to show only the specific results in my query based on the following:
If the 'agreedate' is greater than today's date, less than 60 days, show it. Otherwise I don't want results.
I always get the results of the last year and I don't know why.
Here is my code:
<!-the value date today less than 60 days. This works and shows the correct date->
< cfset invitelimit = #now () # >
< cfset invitelimit = #DateFormat (DateAdd (would be ', - 60, invitelimit), 'dd-mm-yyyy') #.<! - query items from the db and try to catch only to those with a more agreedate then the invitelimit date - >
< name cfquery = "qinvite" datasource = "#Application.ds #" >SELECT DISTINCT * from team a
INNER JOIN followed b ON a.id = b.team_id
INNER JOIN termsagreement c ON a.login = c.loginWHERE c.agreedate > #invitelimit # AND b.comp_id = 0
Group By a.teamname
< / cfquery >
First of all. Confirm that the "argeedate" column is a datetime column. Not another type of data that would be much more difficult to work with.
Secondly, you should provide an appropriate database datetime value. The easiest way would be with the
tag. I.E.
WHERE
c.agreedate >
AND b.comp_id =
-
Problem with the query result set * STILL a QUESTION *.
Summary
What I am tring to do is to return output to the data points that currently have no values.
* Here it is sample data for reasons explaining my question (my data set is MUCH bigger)
xTable
Desired outputYEAR PEOPLE ITEMS TYPE_NUMBER TYPE_DESC CLASS 2010 1 1 REG 1 2010 2 3 2 MISC 1 2010 5 4 3 WEEK 1 2010 1 REG 2 2010 2 MISC 2 2010 3 WEEK 2 2009 1 1 REG 1 2009 2 3 2 MISC 1 2009 5 4 3 WEEK 1 2009 1 REG 2 2009 2 MISC 2 2009 3 WEEK 2 ... (there's over 100 other unique CLASS values)
Oracle: 10.2 GYR PEOPLE ITEMS TOTAL PEOPLE TOTAL_ITEMS 2010 - - - - -- (Class 2 result set) /* FYI, If i wanted the class 1 result set it would look like this: YR PEOPLE ITEMS TOTAL PEOPLE TOTAL_ITEMS 2010 8 7 16 14 -- (Class 1 result set)*/
Currently, the query above will return no rows.select 2010 as yr, nvl(f.people,'-') as people nvl(f.items,'-') as items nvl(to_char(sum(f.people)),'-') as total_people, nvl(to_char(sum(f.items)),'-') as total_items, from Xtable, (2010 as yr, sum(items)as items sum(people) as people from xTable where person_id = 99999 and type_number in (1,2,3) and year = 2010 and class = 2 or class = 1 ) f where person_id = 99999 and type_number in (1,2,3) and yr = f.yr and (year <= 2010 or year = 2010) and (class = 2 or class = 1) group by f.people, f.items
Published by: user652714 on February 2, 2010 13:04How about this?
SQL> WITH xTable AS 2 ( 3 SELECT 2010 AS YEAR, 1 AS PEOPLE, 0 AS ITEMS, 1 AS TYPE_NUMBER, 'REG' AS TYPE_DESC, 1 AS CLASS FROM DUAL UNION ALL 4 SELECT 2010 AS YEAR, 2 AS PEOPLE, 3 AS ITEMS, 2 AS TYPE_NUMBER, 'MISC' AS TYPE_DESC, 1 AS CLASS FROM DUAL UNION ALL 5 SELECT 2010 AS YEAR, 5 AS PEOPLE, 4 AS ITEMS, 3 AS TYPE_NUMBER, 'WEEK' AS TYPE_DESC, 1 AS CLASS FROM DUAL UNION ALL 6 SELECT 2010 AS YEAR, NULL AS PEOPLE, NULL AS ITEMS, 1 AS TYPE_NUMBER, 'REG' AS TYPE_DESC, 2 AS CLASS FROM DUAL UNION ALL 7 SELECT 2010 AS YEAR, NULL AS PEOPLE, NULL AS ITEMS, 2 AS TYPE_NUMBER, 'MISC' AS TYPE_DESC, 2 AS CLASS FROM DUAL UNION ALL 8 SELECT 2010 AS YEAR, NULL AS PEOPLE, NULL AS ITEMS, 3 AS TYPE_NUMBER, 'WEEK' AS TYPE_DESC, 2 AS CLASS FROM DUAL 9 ) 10 -- END SAMPLE DATA 11 SELECT YEAR 12 , NVL(TO_CHAR(SUM(PEOPLE)),'-') AS PEOPLE 13 , NVL(TO_CHAR(SUM(ITEMS)),'-') AS ITEMS 14 , CLASS 15 FROM xTable 16 WHERE CLASS IN (1,2) 17 AND YEAR = 2010 18 GROUP BY YEAR 19 , CLASS 20 ORDER BY CLASS DESC; YEAR PEOPLE ITEMS CLASS -------------------- ------ ----- ----- 2010 - - 2 2010 8 7 1
-
Oracle 11g: problem with disable primary key
Hello
I have this problem:
I performed "EXECUTE IMMEDIATE"ALTER TABLE your table of KEY PRIMARY DISABLE";"
This operation returns an error
but when I did 'insert into table... ". »... Oracle returned ora-0001.
The operations are in the same stored procedure, so in the same session.
Database: Oracle 11.2.0.2
How is that possible?
All solutions?
Thanks in advance.
Best regards.
Alessandro ZenoniTry to add 'DROP INDEX' to your disable command.
not tested
alter table xy disable primary key drop index
-
Need help with the query string manipulation
Hello
With the help of 10.1.0.4.2
Given a table called PREFIX_CODES that contains a column called PREFIX_CODE
with the following data:
PREFIX_CODE - VARCHAR2 (20)
-------------------
AAA
BENAMER
CARTER
and another table called SUBSCRIBERS with a column called SUBSCRIBER_ID
with the following data:
SUBSCRIBER_ID - VARCHAR2 (30)
---------------------
BBBB-123456
AAA-444444
DD-2222222
EEEE-888888
Is there a query that will pull all the SUBSCRIBER_ID that begin with
each of the PREFIX_CODES? The following query is not valid, but it
This will give you an idea of what I'm trying to do:
SELECT SUBSCRIBER_ID
SUBSCRIBERS
WHERE AS SUBSCRIBER_ID (SELECT PREFIX_CODE |) » %'
OF PREFIX_CODES)
Using the data from above, I would like that the query to return:
BBBB-123456
AAA-444444
Thanks for your help!Hello
Welcome to the forum!
You were on the right track. To find if a given subscriber corresponds to any prefix_code, you can do an EXISTS subquery:
SELECT subscriber_id FROM subsribers s WHERE EXISTS ( SELECT NULL FROM prefix_codes WHERE s.subscriber_id LIKE prefix_code || '%' ) ;
This will tell you if at least a prefix code. It won't tell you exactly how many, or what they were.
Your message, I'm guessing that there may be more than one, and you can deduct the subscriber_id itself, then the above query should work for you. -
Problem with the query operation using less
Hi all
I have the dataset of all organization numbers like as below
DataSet:
('528801', '528802', '536101', '536102', '100601 ', '536401', ' 536402 ', ' 530701',' 536501', ' 536502 ', ' 540501',' 599101 ', ' 133301',)
('531101', '143101', '536601', '536602', '534401 ', '535501', ' 535401', ' 536801 ', ' 536802',' 531001 ', ' 537501',' 537502 ', ' 540601',' 540801 ', ' 528401')
And I also have a W_INT_ORG_D table where in a column like ORG_NUM that contains the figures of the Organization in the database, now I'll try to find the numbers of the exclusive organization in the value data that does not exist in W_INT_ORG_D using an oracle sql query.
Here is the sql code I wrote well that my request is wrong you could probably understand what I'm trying to say or do, I'm not ok with creating another table and filled in the data and compare two tables later, I want to do it without creating any additional table. Please let me know if you have an idea to do this, appreciate your time.
Request:_
WITH ABC AS
('528801', '528802', '536101', '536102', '100601 ', '536401', ' 536402 ', ' 530701',' 536501', ' 536502 ', ' 540501',' 599101 ', ' 133301',)
('531101', '143101', '536601', '536602', '534401 ', '535501', ' 535401', ' 536801 ', ' 536802',' 531001 ', ' 537501',' 537502 ', ' 540601',' 540801 ', ' 528401')
SELECT DISTINCT ORG_NUM
OF W_INT_ORG_D, ABC
WHERE DATASOURCE_NUM_ID = ' 211 '.
AND ORG_NUM IN
('528801', '528802', '536101', '536102', '100601 ', '536401', ' 536402 ', ' 530701',' 536501', ' 536502 ', ' 540501',' 599101 ', ' 133301',)
('531101', '143101', '536601', '536602', '534401 ', '535501', ' 535401', ' 536801 ', ' 536802',' 531001 ', ' 537501',' 537502 ', ' 540601',' 540801 ', ' 528401')
LESS
SELECT * FROM ABC
Thank you
SamThis wil give a list of numbers of overall organization of data that are not present in the view:
SELECT column_value org_num FROM TABLE(sys.odciVarchar2List( '528801', '528802', '536101', '536102', '100601', '536401', '536402', '530701', '536501', '536502', '540501', '599101', '133301', '531101', '143101', '536601', '536602', '534401', '535501', '535401', '536801', '536802', '531001', '537501', '537502', '540601', '540801', '528401' ) ) MINUS SELECT DISTINCT ORG_NUM FROM W_INT_ORG_D WHERE DATASOURCE_NUM_ID='211' /
SY.
Published by: Solomon Yakobson, June 29, 2009 10:49
-
Problem creating a hierarchical tree in the generator of forms [problem with the query]
Hi all
I have 2 tables.
box (box_id, box_name)
point (item_id, nom_element, box_id)
There are several items in a box.
I want to create a HIERARCHICAL tree to display items that are present in each box.
AS:
| - BOX1
| |-ITEM 1
| | - ITEM 2
|
| - BOX2
| |-ITEM 1
| | - ITEM 2
I'm trying this query:
SELECT-1 State, box_name, box_id, "icon" val
in zone b, point i;
I don't know what the value for upgrade, I don't know how the code part "connect by front.
Could you please tell me?
Michael.
PS. then I'll eventually use this query in the form designer.Hi MichaelR
I'm getting the FRM - 47321 error in forms Builder...
That's why In order to fill a tree, the select must recover 5 columns:
STATUS, LEVEL, LABEL, ICON, u-VALUE should be noted this command in your application, this will resolve the error and pls notice that the...My advice is to use the online help in your form generator to help u in this...
Initial state : number Node tree depth : number Label for the node : varchar2 Icon for the node : varchar2 Data : varchar2
This must be a TIME NEW FORM INSTANCE trigger to fill your tree...
Another thing why do you think of building your tree I've done here in the following example... Pls take a look here....
I hope this helps...
Kind regards
Amatu Allah.
-
Problem with the query parameter
Hi, I have data some thing like SQL> select * from temp_tabr; INSTITUTE STUDNAME GR MARKS ---------- ---------- -- --------- xxxx abc A 500 xxxx pqq A 550 xxxx zzz B 300 xxxx sss B 400 yxxx abc A 500 yxxx pqq A 550 yxxx zzz B 300 yxxx sss B 400 I want a query to retrive the data based on 3 parameters Institue is mandatory GR and MARKS are optional user may pass any one of the Optional parameters GR or MARKS not both example he may pass Intitute and get all 8 records if he pass Institue and grade it should retrive only those matching if he pass institute and marks it should retrive only those matching only grade or marks will be passed or neighter of them will be passed. create table temp_tabr(institute varchar2(10), studname varchar2(10), grade varchar2(2), marks number); insert into temp_tabr values ('xxxx', 'abc', 'A', '500'); insert into temp_tabr values('xxxx', 'pqq', 'A', 550); insert into temp_tabr values('xxxx' , 'zzz' , 'B' , 300); insert into temp_tabr values('xxxx' , 'sss' , 'B' , 400); insert into temp_tabr values ('yxxx', 'abc', 'A', '500'); insert into temp_tabr values('yxxx', 'pqq', 'A', 550); insert into temp_tabr values('yxxx' , 'zzz' , 'B' , 300); insert into temp_tabr values('yxxx' , 'sss' , 'B' , 400);
Like this?
select * from temp_tabr where institute='&a' and grade = nvl('&b',grade) and marks = nvl(to_number('&c'),marks)
If you pass parameters using the variable, you do not have to use to_number, you can directly pass the name of the variable. I have provided for you to test it in sql * more.
HTH,
Prazy -
Problem with the simple query.
Hi all
I am facing problem with the query below
Select A.COL1, A.COL2
B.COL1, B.COL2
FROM TABLE1 A
TABLE 1 B
WHERE A.header = '123'
AND B.header = '123'
AND nvl (A.COL6, 'ABC') = 'ABC '.
AND NVL (B.COL6, 'DEF') = 'DEF '.
Basically, my requiremenyt is: I have only one table, TABLE1 here, which has a line two lines (for the same header) as "ABC" and another is "DEF". Table 1 has two columns (col1, col2) that should be displayed for both lines.
When the header has two records in table1 top query works. and but if I do not have a record for any header example there are a record for "abc" in col6 only. so my query above does not work because there is no record for 'DEF' in col6. But I want to again request to fecth the output (for b.col1 and b.col2 should have null values)
could you pls suggest me how to get the 4 columns.
Thanks in advance
Kind regards
UVA.
Try to place the status of outer join on column: analytical_criterion_code as
and nvl (AUDIT.analytical_criterion_code, 'AUDIT2') = 'verification2. '
.
.
and nvl (TRANS.analytical_criterion_code, 'TRANS2') = 'TRANS2.
In the sub query based on the opinions that you have given in post # 1, although there is no value "DEF * ' for col6 due to the condition of outer join on b.col6 (+) line is extracted with b.col [1,2,3] as NULL values. Try to remove the (+) sign b.col6 and test.
with t as)
Select 111 col1, col2 'aaa', 'ABC' col6 123 header of all the double union
Select 222 'bbb', 'DEF' col6, 123 double header
)
q as (select 123 double header)
Select A.COL1, A.COL2, A.COL6
B.COL1, B.COL2, b.COL6
q.header
T a
t b
q
where a.col6 (+) = 'ABC '.
and b.col6 (+) = "DEF."
and q.header = a.header (+)
and q.header = b.header (+)
-
Original title: error Windows 7 installation files
I bought a copy of Windows 7 at Tiger Direct on 22/05/2014. I lost my copy and I tried to download the iso from the Microsoft web site, but my product key is not valid. I get this error message
We had a problem with the request for approval.
See for other directions:
http://answers.Microsoft.com/en-us/Windows/wiki/Windows_7-update/how-to-what-are-my-options-for-obtaining-Windows-7/528163c1-0b2e-4AD2-a26d-7112851d1dc2
-
Another user changed the row with a primary key oracle.jbo.Key]
I see many discussions about this error, but still cannot understand the difficulty that I need in my scenario.
I am an Oracle Developer and completely new to ADF, please bear with me.
I use JDeveloper 11.1.1.9.0
My scenario:
Creates an object editable view (UVO) with sub selects in the query, which is from several db tables.
Creating a table using the UVO
When I try to update a field in the table, and then click the validate, I get the error message:
Another user changed the row with a primary key oracle.jbo.Key]
Can someone explain in what scenarios I see this error and how do I solve this problem?
Try the viewObject execution after validation and reQueryOnCommit set to true
For details see - binary: a reason more for "Houston-25014: another user has modified the line containing oracle.jbo.Key primary key '
Ashish
-
Problem with the input query mode. FRM 41009, 40301
Hi all
I have a problem with the mode of input query. What can I say, I'm in the mode of input query, and I click on a button. I get the error THAT FRM-41009 displayed.
Now, I've wanted handled. So I created a trigger of error in order to handle the error.
IF ERR_CODE = 41009 THEN
NULL;
END IF;
A problem is that when you use the null value, it will not terminate the mode of input query, and then I get frm-40301 error.
Second, it's that I can't use exit_form in a trigger of the error.
I am aware that I can press F4 to exit this mode, but I don't want to do whenever I'm sure I'll get the user complaints.
Another solution would be to put the following code in the trigger when key pressed for each button in the form:
If: system.mode = "ENTER-QUERY" then
exit_form;
end if;
But I don't want to reproduce this code in my form.
Please can you give me an idea how to handle this correctly?
Thank you
Michael
PS: Version of the form = > ORACLE FORMS 10g (Forms [32 bit] Version 10.1.2.3.0)I have a problem with the mode of input query. What can I say, I'm in the mode of input query, and I click on a button. I get the error THAT FRM-41009 displayed.
What is the code in the trigger of your button When-Button-Pressed (WBP)? Maybe you should check to see if the form is in the Mode query in your WBP rather than try and remove the error? In other words, eliminate error - do not delete it. :)
If you want instead to remove the error, there is a technique to built-ins call restricted to a trigger that does not allow them. Do this by the use of a millisecond zero Timer. For example:
/* Sample On-Error Trigger */ DECLARE n_err_cd NUMBER := ERROR_CODE; t_on_error TIMER; ZERO NUMBER := 0; BEGIN IF ( n_err_cd = 41009 ) THEN /* Create Timer to execute Exit_Form() */ /* to Cancel Query-Mode. */ t_timer := Create_Timer('ON_ERROR', ZERO, NO_REPEAT); ELSE /* Handle all other errors here... */ END IF; END;
/* Sample When-Timer-Expired Trigger */ DECLARE v_Timer VARCHAR2(30); BEGIN v_timer := Get_Application_Property(TIMER_NAME); IF ( v_timer = 'ON_ERROR' ) THEN /* Notice, the timer name is case sensative! */ Exit_Form; END IF; END;
I am aware that I can press F4 to exit this mode, but I don't want to do whenever I'm sure I'll get the user complaints.
Well, it's just standard features of Oracle Forms. If you switch the Mode request form - you must run a query or cancel the query Mode! This is how it works. Your users need to understand that and accept it - just as they accept the functional also for other programs. ;) Another option would be to add a "Cancel request" button to your form and make it so it is enabled only when the form is placed in Query Mode. Just a thought...
I personally prefer to prevent the occurrence of an error rather than remove the error. :)
I hope this helps.
Craig...
Maybe you are looking for
-
Developer Web Inspector without Console
Hello As a developer, I use the Inspector (Tools-> Web Developer-> Inspector) a lot to find the DOM elements. And I work with several different screen widths, I like the inspector at the bottom of the screen. Since lately, I seem to have a very small
-
WWhy does User Account Control como upwhen I click on the logo of Firefox?
I have Windows 7. For the last 2 weeks, when I go to Firefox on my user account control window appears and asks "do allow you the following program to make changes to this computer? I say Yes. This happens whenever I click on the Firefox logo. How ca
-
E reader vs. software Adobe digital editions...
Sinc does not work. Both are approved for me. How can I down 11 books of my software Adobe digital Editions to my reader (PRS-350)?
-
Cannot add my phone via bluetooth on win 7 64 bit, get code error: 0 x 80070015
the windows error box says "add device failed, leading to an unknown error.the error code is 0 x 80070015.» can someone help me with this...
-
How do I get my printer so that I stop my neighbors to use my wireless printer to print?
I am on a wireless secured with 5 other apartments and a person has been recently able to access and print from my wireless printer. On the printer itself, I can't find where I put a code encryption or security of the printer. So, I hope that someone