Attach email script to database update code
I need to send a very simple email to a predetermined
recipient when my Access database is updated. How do I attach an
email script to it?
Thanks.
first is to check out which "E-Mail" Component on the
webserver is installed. Check the FAQ of your hosting company. If
they do not have any e-mail component installed try this:
http://www.webwizguide.com/asp/tutorials/email_using_cdonts_tutorial.asp
you have to use the e-mail component after updating the
database - be sure to control, that the update was really made
before sending the email
regards
Sebastian
Similar Messages
-
Update fails (Failed to run database update script)
Still unable to update my zmm. it fails to uppgrade the sqldb.
logfiles ends like this.
Msg 512, Level 16, State 1, Server xxxxx, Procedure , Line 2
[Microsoft][ODBC SQL Server Driver][SQL Server]Subquery returned more than 1
value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or
when the subquery is used as an expression.
The statement has been terminated.
1> 2> 3> 4> 5> 6> 7> [17:04:44] RunShellCommand: Command: osql exited with code: 1
[17:04:44] RunShellCommand: Exit code indicates failure.
[17:04:44] UpdateDatabase: Failed to run database update script.
Need some help plzdahlholm,
It appears that in the past few days you have not received a response to your
posting. That concerns us, and has triggered this automated reply.
Has your problem been resolved? If not, you might try one of the following options:
- Visit http://www.novell.com/support and search the knowledgebase and/or check all
the other self support options and support programs available.
- You could also try posting your message again. Make sure it is posted in the
correct newsgroup. (http://forums.novell.com)
Be sure to read the forum FAQ about what to expect in the way of responses:
http://forums.novell.com/faq.php
If this is a reply to a duplicate posting, please ignore and accept our apologies
and rest assured we will issue a stern reprimand to our posting bot.
Good luck!
Your Novell Forums Team
http://forums.novell.com -
How do i find the email address that my redemption code is attached to?
Hello My name is Yakira and I'm a fashion design student. My school sent out emails that had links for students to follow in order to download a free copy of Adobe Suite. I followed the instructions and Creative Cloud only allows me to use TRIAL versions of the software.
I just got off Technical Support with my school and they informed me that the email address that is attached to my redemption code is different than the email address I used to download the software in the first place.
The reason for that is because my school was recently bought by another company and the overall email address that was used with the Adobe account is not the same one that out campus uses now. Instead of telling students to use the older email address a lot of students are confused as to why they cannot access their Adobe Suite
So I have the Redemption code but I need the email address that the redemption code is linked to so that I can download everything again.
Hope my explanation was not that confusing.
Regards,
YakiraMoving this discussion to the Adobe Creative Cloud forum.
-
I am enrolled in an online university program that uses Sakai. Fire Fox updated something that attaches computer script to my Word documents when I upload them. I use a PC and Word 2010
sigh...this is quite idiotic, but I have found a solution. It was quite simple, really, and yet quite idiotic. I share it for all those reading so that, if you know of anyone else that did what i did, you can easily be the "hero" in their lives.
After a continued search via youtube or what have you for any possible solutions, I kept coming back to the fact that I was told by my computer that I didn't have "permission" to do the file deletion. I stumbled upon a youtube video that talked about "unlocking", "locking", certain files and what not.
Long story short, the reason why I couldn't do anything to the files that were on my desktop was due to my "locking" the desktop folder. I must have done this a while back not knowing what I was doing nor the ramifications of clicking a simple box.
I undid this by:
Opening Up Finder
then, going to MacHD --> Users --> My Account Folder
clicking on Desktop Folder, I "cmd+I"
I then, unclicked the "locked" option
I went down to the cog/settings and selected "Apply to enclosed items"
resulting then in having all my files on my desktop free accessiblity and delete-ability....
oi...at least I now know what "locking" a folder (even the desktop folder) can do to other files held within it -
I have recently bought my Mac mini ( July 12) and have already requested my free update code for mountain lion, got a reference nr, but I still haven't received a code via email to update with? Its been 12 days. Any advice?
I am still in the return window but i really do not want to return my mac as i know it has the ability to do what i want, my problem is just finding the software that will work as i know there has been a lot of complications with OS X Mountain Lion with softwares that caim to be compatible but then later turn out not to be.
I have been a windows user for years and this is really my first mac but apart from the hole software issue i find the mac 10x better than any windows computer i have ever used. For example i bought a HP laptop 4 weeks ago and has nothing but problems. At first the fans stopped working and making weird noises and then it began switching off when ever it felt like it and freezing like mad when i was trying to access the smallest program. I have found that now a days you dont get what you pay for with Windows especially since Windows 8 was released. Also Laptops such as HP now are just crammed with cheap parts, they dont take pride in their systems like they once used to unlike Apple. I know i will get more than a year or 2 out my mac (hopefully a lot more) but with windows systems it just seems to break all the time costing more money on extending warrantys. Also i like mac because i dont need to send it away if i ever get a problem, i can just take it into the apple shop half a mile down the road and they will fix it in store. Where as with windows i am waiting 2 weeks+ to just hear back from them. -
hi frnds
can anybody tell me how to email script and forms.
well for emailing we have to download the script to pdf file how to do that .has anybody used rstxpdft4 progrm. we have to give the spool request no for downloading into pdf file . but i dont know how to generate the spool request no.Hai Rohit Gupta
Check the following COde
REPORT ZRICH_0003.
DATA: ITCPO LIKE ITCPO,
TAB_LINES LIKE SY-TABIX.
Variables for EMAIL functionality
DATA: MAILDATA LIKE SODOCCHGI1.
DATA: MAILPACK LIKE SOPCKLSTI1 OCCURS 2 WITH HEADER LINE.
DATA: MAILHEAD LIKE SOLISTI1 OCCURS 1 WITH HEADER LINE.
DATA: MAILBIN LIKE SOLISTI1 OCCURS 10 WITH HEADER LINE.
DATA: MAILTXT LIKE SOLISTI1 OCCURS 10 WITH HEADER LINE.
DATA: MAILREC LIKE SOMLREC90 OCCURS 0 WITH HEADER LINE.
DATA: SOLISTI1 LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE.
PERFORM SEND_FORM_VIA_EMAIL.
FORM SEND_FORM_VIA_EMAIL *
FORM SEND_FORM_VIA_EMAIL.
CLEAR: MAILDATA, MAILTXT, MAILBIN, MAILPACK, MAILHEAD, MAILREC.
REFRESH: MAILTXT, MAILBIN, MAILPACK, MAILHEAD, MAILREC.
Creation of the document to be sent File Name
MAILDATA-OBJ_NAME = 'TEST'.
Mail Subject
MAILDATA-OBJ_DESCR = 'Subject'.
Mail Contents
MAILTXT-LINE = 'Here is your file'.
APPEND MAILTXT.
Prepare Packing List
PERFORM PREPARE_PACKING_LIST.
Set recipient - email address here!!!
MAILREC-RECEIVER = '[email protected]'.
MAILREC-REC_TYPE = 'U'.
APPEND MAILREC.
Sending the document
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
DOCUMENT_DATA = MAILDATA
PUT_IN_OUTBOX = ' '
TABLES
PACKING_LIST = MAILPACK
OBJECT_HEADER = MAILHEAD
CONTENTS_BIN = MAILBIN
CONTENTS_TXT = MAILTXT
RECEIVERS = MAILREC
EXCEPTIONS
TOO_MANY_RECEIVERS = 1
DOCUMENT_NOT_SENT = 2
OPERATION_NO_AUTHORIZATION = 4
OTHERS = 99.
ENDFORM.
Form PREPARE_PACKING_LIST
FORM PREPARE_PACKING_LIST.
CLEAR: MAILPACK, MAILBIN, MAILHEAD.
REFRESH: MAILPACK, MAILBIN, MAILHEAD.
DESCRIBE TABLE MAILTXT LINES TAB_LINES.
READ TABLE MAILTXT INDEX TAB_LINES.
MAILDATA-DOC_SIZE = ( TAB_LINES - 1 ) * 255 + STRLEN( MAILTXT ).
Creation of the entry for the compressed document
CLEAR MAILPACK-TRANSF_BIN.
MAILPACK-HEAD_START = 1.
MAILPACK-HEAD_NUM = 0.
MAILPACK-BODY_START = 1.
MAILPACK-BODY_NUM = TAB_LINES.
MAILPACK-DOC_TYPE = 'RAW'.
APPEND MAILPACK.
Creation of the document attachment
This form gets the OTF code from the SAPscript form.
If you already have your OTF code, I believe that you may
be able to skip this form. just do the following code, looping thru
your SOLISTI1 and updating MAILBIN.
PERFORM GET_OTF_CODE.
LOOP AT SOLISTI1.
MOVE-CORRESPONDING SOLISTI1 TO MAILBIN.
APPEND MAILBIN.
ENDLOOP.
DESCRIBE TABLE MAILBIN LINES TAB_LINES.
MAILHEAD = 'TEST.OTF'.
APPEND MAILHEAD.
Creation of the entry for the compressed attachment
MAILPACK-TRANSF_BIN = 'X'.
MAILPACK-HEAD_START = 1.
MAILPACK-HEAD_NUM = 1.
MAILPACK-BODY_START = 1.
MAILPACK-BODY_NUM = TAB_LINES.
MAILPACK-DOC_TYPE = 'OTF'.
MAILPACK-OBJ_NAME = 'TEST'.
MAILPACK-OBJ_DESCR = 'Subject'.
MAILPACK-DOC_SIZE = TAB_LINES * 255.
APPEND MAILPACK.
ENDFORM.
Form GET_OTF_CODE
FORM GET_OTF_CODE.
DATA: BEGIN OF OTF OCCURS 0.
INCLUDE STRUCTURE ITCOO .
DATA: END OF OTF.
DATA: ITCPO LIKE ITCPO.
DATA: ITCPP LIKE ITCPP.
CLEAR ITCPO.
ITCPO-TDGETOTF = 'X'.
Start writing OTF code
CALL FUNCTION 'OPEN_FORM'
EXPORTING
FORM = 'ZTEST_FORM'
LANGUAGE = SY-LANGU
OPTIONS = ITCPO
DIALOG = ' '
EXCEPTIONS
OTHERS = 1.
CALL FUNCTION 'START_FORM'
EXCEPTIONS
ERROR_MESSAGE = 01
OTHERS = 02.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
WINDOW = 'MAIN'
EXCEPTIONS
ERROR_MESSAGE = 01
OTHERS = 02.
Close up Form and get OTF code
CALL FUNCTION 'END_FORM'
EXCEPTIONS
ERROR_MESSAGE = 01
OTHERS = 02.
MOVE-CORRESPONDING ITCPO TO ITCPP.
CALL FUNCTION 'CLOSE_FORM'
IMPORTING
RESULT = ITCPP
TABLES
OTFDATA = OTF
EXCEPTIONS
OTHERS = 1.
Move OTF code to structure SOLI form email
CLEAR SOLISTI1. REFRESH SOLISTI1.
LOOP AT OTF.
SOLISTI1-LINE = OTF.
APPEND SOLISTI1.
ENDLOOP.
ENDFORM.
Thanks & regards
Sreenivasulu P -
Outlook Email script won't work with Reader 9.1
The attached form was designed in ES 8.2 and has worked fine with Reader 8.0. The "properties defaults" tab is set for Reader 9.0 or better. However, upon recent upgrade to Reader 9.1, the Outlook Email script stopped working. I'm new to Livecycle and scripts and was hoping that someone had an easy fix?
okay thanks. One more question. What script is used to activate the "read receipt requested" function in Outlook?
Date: Wed, 12 Aug 2009 12:23:13 -0600
From: [email protected]
To: [email protected]
Subject: Outlook Email script won't work with Reader 9.1
Interesting .....it sounds like an issue in Reader. From a code perspective everything is good .....the code tells Reader's email service to communicate with the mail client. This could be where the issue is.
You may want to post your question on the Acrobat forum and see if they know of anything .....or you can report the issue to Support and have them look into it. Maybe something was introduced into the 9.1 version.
From a Designer perspective all is good.
Paul
> -
Database Source Code Synchronization with PVCS
Hello All,
I would really appreciate your ideas/suggestions on developing, implementing the following requirement.
I am in the process of developing a mechanism to validate the database procedure source code in the application PVCS library, that matches the source code used for QA and PRD environments. The objective is to assure that production version of stored procedure code is the correct / matching version with PVCS, QA and PRD.
Database: Oracle 9i
Source Control System: PVCS
Database Objects: Stored Procedures
Other Questions:
- Do you know any PVCS API's to read the files?
Thanks, MadhaviHello All,
I would really appreciate your ideas/suggestions on
developing, implementing the following requirement.
I am in the process of developing a mechanism to
validate the database procedure source code in the
application PVCS library, that matches the source code
used for QA and PRD environments. The objective is to
assure that production version of stored procedure
code is the correct / matching version with PVCS, QA
and PRD.This is going to take a lot of work and I am not even sure that is is deterministic. And it is easily handled by the correct process control as well.
The following process control steps allow this.
- Developement ONLY delivers scripts for database changes. Thus table changes, data changes, new procs, old procs, what ever are delivered as scripts and are checked into version control.
- QA does NOT use anything that is not in the version control system. No disks, memory sticks, emails, etc (and in particular QA does NOT use developement database servers for testing.)
- QA are the ONLY ones allowed to install anything to production. This includes all the DBAs and it includes "emergency" fixes (which usually greatly diminsh if the above is followed and QA is actually testing stuff.)
The last step can be enforced either by simply disallowing change access to production machines except for QA and non-developement (MUST be non-developement) admin.
But if you insist, people have been interfacing programmitically with Oracle and PVCS for years. You can search the net for thousands of these. I suspect that you will find that Perl is used a lot in this (but that could be my own bias.) -
Is it possible to read , send emails from the database in oracle8.
Hi,
My present project needs me to send emails from the database through procedures. There is an oracle package UTL_HTTP in oracle8 which could be used to read emails from database. So kindly tell how to go about sending an email from the database. Is this feature available in Oracle8i.
Thank you.Okay , Here's my Javascript wgich is in an onload process.
Javascript variable addr_str displays the correct result.
My hidden field is called P101_CHECKVAL.
<html>
<title>CodeAve.com(JavaScript: Display All URL Variables)</title>
<body bgcolor="#FFFFFF">
<script language="JavaScript">
<!--
// Create variable is_input to see if there is a ? in the url
var is_input = document.URL.indexOf('P101_CHECKVAL:');
// Check the position of the ? in the url
if (is_input != -1)
// Create variable from ? in the url to the end of the string
addr_str = document.URL.substring(is_input+1, document.URL.length);
// Loop through the url and write out values found
// or a line break to seperate values by the &
for (count = 0; count < addr_str.length; count++)
if (addr_str.charAt(count) == "&")
// Write a line break for each & found
{document.write ("<br>");}
else
// Write the part of the url
{document.write (addr_str.charAt(count));}
// If there is no ? in the url state no values found
else
{document.write("No values detected");}
-->
</script>
</body>
</html>
Everytime I put the HTML_get code into the javascript, it basically tells me I have an error on the page. So what exactly do I put that sets P101_CHECKVAL equal to the value of addr_str? -
Failed to open the connection.Details: [Database Vendor Code: 17 ]
We have too many reports designed by Crystal Reports XI Release 2 a time ago reports are old but we are calling them in asp.net 4.0 and connection through ODBC Data Sources (Driver SQL SERVER)
but when we refresh the report we are facing this issue....
Failed to open the connection.
Details: [Database Vendor Code: 17 ] Failed to open the connection.
AP Outstanding Check Run Detailed Ver 2 {CF3B13A2-F259-4B1D-ACC9-BF78F44D4AA5}.rpt
Details: [Database Vendor Code: 17 ]
here is the code to set ReportLoginInfo
CrystalDecisions.Shared.TableLogOnInfo logonInfo = new CrystalDecisions.Shared.TableLogOnInfo();
string myTableLocation;
foreach (CrystalDecisions.CrystalReports.Engine.Table myTable in rptDoc.Database.Tables)
myTableLocation = myTable.Name;
logonInfo = myTable.LogOnInfo;
logonInfo.ConnectionInfo.AllowCustomConnection = true;
logonInfo.ConnectionInfo.ServerName = ServerName; // dnsname
logonInfo.ConnectionInfo.DatabaseName = DatabaseName;
if (!(string.IsNullOrEmpty(UserID) || string.IsNullOrEmpty(Password)))
logonInfo.ConnectionInfo.UserID = UserID;
logonInfo.ConnectionInfo.Password = Password;
logonInfo.ConnectionInfo.IntegratedSecurity = false;
logonInfo.ConnectionInfo.Type = CrystalDecisions.Shared.ConnectionInfoType.SQL;
myTable.ApplyLogOnInfo(logonInfo);
myTable.Location = DatabaseName + ".dbo." + myTableLocation;
bool success = myTable.TestConnectivity();
Edited by: zeshansadiq on Nov 4, 2011 3:49 PMresolved by me itself.
Do the following steps:
1. Open the report in the CR XI designer.
2. Select Database -> Set Datasource Location.
3. Set Datasource Location window will appear and in the replace with section connect to the database and replace these tables with the tables in the current datasource by clicking the update button.
4. After updating close the Set Datasource Location window.
5. Go to 'Database menu' and Click 'Verify Database' and click on u2019OKu2019.
6. Preview the report and the save the report. -
How can I script Adobe Reader updates using vbScript, PowerShell or C#?
I would like to script Adobe Reader updates using vbScript, PowerShell or C#, are there any Adobe API calls I use to do this. There are several different version that I support and auto update is not an option. I do updates at a specific time of the month. I would like to write a script that would download and install the update for the currently installed version of Adobe Reader (32 or 64 bit) for the version of the OS (32 or 64bit). I can detect the OS version and the Adobe version. I can download updates but I do not want to hard code anything
Sabian is correct.
Most admins download the updates from the ftp site and push via AIP, GPO, SCCM, or some other method whenever it makes sense for them.
Ben -
Database access code in objects constructor, or in data access object
Given an object that is stored in a database, is it better to have the database access code in a constructor method, or a data access layer object? E.g. I have a Person class
public class Person{
int Id;
String name;
int age;
}When I want to read a person's details from the database, I could use a constructor something like this:
public Person(int id){
Connection con = getDatabaseConnection();
ResultSet rs = con.createStatement().executeQuery("Select name, age from person where person_id = " + id);
rs.next();
this.name = rs.getString(1);
this.age=rs.getInt(2);
}Or I could use a method in a data access object :
public Person getPerson(int id){
Person p = new Person();
Connection con = getDatabaseConnection();
ResultSet rs = con.createStatement().executeQuery("Select name, age from person where person_id = " + id);
rs.next();
p.setName(rs.getString(1));
p.setAge(rs.getInt(2));
return p;
}It seems to me that the constructor approach has two advantages
(1) the SQL code is kept in the relevant class (so if I want to add a field to Person, I only have to make changes to the Person class)
(2) I don't have to have a setter method for each field
Is one or other of these ways generally recognized as 'best practise'?malcolmmc wrote:
But then, on the other hand, everytime a Person gains a new field that's two places you have to change it. if the persistence interface is written in terms of the object and uses ORM, I don't have to touch the implementation. all i have to do is update the object, the database, and the mapping - just like you and your home brew ORM.
besides, so what? i'd fear the resource leak, bad layering, more difficult testing more.
Actually lately I've used annotations to label setters with database field names and run a simple home brew ORM to convert rows into objects even when not using a more complex persistence manager.home brew ORM? why is that necessary when you can choose from hibernate, ibatis, jdo, jpa, etc.? that's just nuts.
% -
To perform database update in a module with AT EXIT-COMMAND addition
Dear All,
I have a function code 'EXIT' with function type 'E'. When this function code is triggered, my screen should close.
In the module that handles this function code (defined with AT EXIT-COMMAND addition), I will prompt the user whether he/she want's to save the data before exiting with the POPUP_TO_CONFIRM_STEP function module. The text message in the dialog box is "Do you want to save before exiting?".
When the user wants to save the data, a simple UPDATE statement will be executed to write the data on screen to database.
The problem here is since the module is defined with AT EXIT-COMMAND addition, the data on screen won't be copied to their corresponding variable on the code (correct me if I'm wrong). Therefore, even though database update is performed, the data written to database are no different that the original.
How to perform database update in a module with AT EXIT-COMMAND addition?
or
Is it even a "custom" or a "good practice" to prompt user to save data before exiting?
Thanks in advance,
HarisWith an exit command, if there's anything that would be lost, I would prompt "Data will be lost, do you wish to continue?". If they do, the database is not updated, if they don't, they stay in the transaction.
This is because the exit command runs before validation. So how can you know the data is correct?
If you have a button to leave the transaction that isn't an exit command, then you could prompt to save instead. There the choices should be - quit without saving, save and quit, don't quit.
Doing a database update in an exit command is not a good idea.
matt
Edited by: Matt on Mar 15, 2011 11:53 AM -
Unable to connect: incorrect log on parameters. Database Vendor Code: 18456
I have imported a report into Info View (that has no parameters), I am able to run the report on Demand in InfoView, and I am also able to run the report within the CMC Preview. I have tried scheduling using the admin account in CMC, through the publishing wizard and also with a authorized users in InfoView. But anytime I try to schedule the report I get this error.
Status: Failed
Printer: The instance is not printed.
External Destination: Mail the instance to " XXX@XXX .com " with a subject of " test ".
Data Refresh Settings: Use the server defaults.
Start Time: 11/18/08 3:02:19 PM
End Time: 11/18/08 3:02:23 PM
Server Used: clr-combr.reportjobserver
Error Message: Error in File C:\Program Files\Business Objects\BusinessObjects Enterprise 11.5\Data\procSched\clr-combr.reportjobserver\~tmp1304574d76168ca.rpt: Unable to connect: incorrect log on parameters. Details: [Database Vendor Code: 18456 ]
I have made sure that the Reportjobobject is enabled and the server for SMTP email is enabled, and I am pretty sure I have the properties set up correctly within there, we created a email account specifically for crystal. And that email account is also set up as a user. I don't know where else to look.
Please help.
ThanksHi Ashley
I would like to suggest you following things with the Report:
1) Please log in into CMC, go to Report which you want to schedule.
2) Click on the report and go to Process
3) Click on the tab Database.
4) There will be two option to make the entries for database logon required for the Report.
Please select the appropriate option. Are you able to Preview the report?
What is the database in use? Please also check the odbc driver settings for that database. -
ok.. i have a vacancies page, each vacancy has a link next to
it called "edit" when you click on the link it does this:
<a href="vacancyedit.cfm?ID=#ID#">
on vacancyedit.cfm there is a form. the fields on the form
are populated with this query:
<cfquery name="edit_vacancy"
datasource="allieddatabase">
SELECT *
FROM new_vacancy_table1
WHERE ID = #ID#
ORDER BY ID DESC
</cfquery>
the form looks like this:
<form
action="<cfoutput>#CurrentPage#</cfoutput>"
method="POST" name="edit_vacancy_form">
<label for="textfield">Auto ID</label>
<input
value="<cfoutput>#edit_vacancy.ID#</cfoutput>"
type="text" name="id" id="id">
<label for="label">Area</label>
<input
value="<cfoutput>#edit_vacancy.area#</cfoutput>"
type="text" name="textfield2" id="label">
<label for="label2">Pattern</label>
<input
value="<cfoutput>#edit_vacancy.pattern#</cfoutput>"
type="text" name="textfield3" id="label2">
<label for="label3">Hours</label>
<input
value="<cfoutput>#edit_vacancy.hrs#</cfoutput>"
type="text" name="textfield4" id="label3">
<label for="label4">Rate</label>
<input
value="<cfoutput>#edit_vacancy.rate#</cfoutput>"
type="text" name="textfield5" id="label4">
<label for="textarea">Description</label>
<textarea name="textarea"
class="text_entry"><cfoutput>#edit_vacancy.description#</cfoutput></textarea>
<br>
<input type="submit" name="Submit" value="Submit"
id="submit_button">
<input type="hidden" name="MM_UpdateRecord"
value="edit_vacancy_form">
</form>
so i make the alterations to the queried data as required
then click submit. this is the update code:
<cfset CurrentPage=GetFileFromPath(GetTemplatePath())>
<cfif IsDefined("FORM.MM_UpdateRecord") AND
FORM.MM_UpdateRecord EQ "edit_vacancy_form">
<cfquery datasource="allieddatabase">
UPDATE new_vacancy_table1
SET area=
<cfif IsDefined("FORM.textfield2") AND #FORM.textfield2#
NEQ "">
<cfqueryparam value="#FORM.textfield2#"
cfsqltype="cf_sql_clob" maxlength="50">
<cfelse>
</cfif>
, pattern=
<cfif IsDefined("FORM.textfield3") AND #FORM.textfield3#
NEQ "">
<cfqueryparam value="#FORM.textfield3#"
cfsqltype="cf_sql_clob" maxlength="50">
<cfelse>
</cfif>
, hrs=
<cfif IsDefined("FORM.textfield4") AND #FORM.textfield4#
NEQ "">
<cfqueryparam value="#FORM.textfield4#"
cfsqltype="cf_sql_clob" maxlength="50">
<cfelse>
</cfif>
, rate=
<cfif IsDefined("FORM.textfield5") AND #FORM.textfield5#
NEQ "">
<cfqueryparam value="#FORM.textfield5#"
cfsqltype="cf_sql_clob" maxlength="50">
<cfelse>
</cfif>
, "description"=
<cfif IsDefined("FORM.textarea") AND #FORM.textarea# NEQ
"">
<cfqueryparam value="#FORM.textarea#"
cfsqltype="cf_sql_clob">
<cfelse>
</cfif>
WHERE ID=<cfqueryparam value="#FORM.id#"
cfsqltype="cf_sql_numeric">
</cfquery>
<cflocation url="vacancyadmin.cfm">
</cfif>
this should then update my changes and take me back to
vacancyadmin.cfm. however all i get is the following error message:
Error Executing Database Query.
Parameter ?_5 has no default value.
The error occurred in
F:\data\webdesigns\wwwroot\CFIDE\Allied\vacancyedit.cfm: line 35
33 : ''
34 : </cfif>
35 : WHERE ID=<cfqueryparam value="#FORM.id#"
cfsqltype="cf_sql_clob" maxlength="10">
36 : </cfquery>
37 : <cflocation url="vacancyadmin.cfm">
SQL UPDATE new_vacancy_table1 SET area= (param 1) , pattern=
(param 2) , hrs= (param 3) , rate= '' , "description"= (param 4)
WHERE ID= (param 5)
DATASOURCE allieddatabase
VENDORERRORCODE 3088
SQLSTATE
Resources:
* Check the ColdFusion documentation to verify that you are
using the correct syntax.
* Search the Knowledge Base to find a solution to your
problem.
Browser Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US;
rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.3
Remote Address 10.0.0.201
Referrer
http://allied-srv-03/CFS/vacancyedit.cfm?ID=14
Date/Time 07-Apr-07 12:56 PM
Stack Trace
at
cfvacancyedit2ecfm242791332.runPage(F:\data\webdesigns\wwwroot\CFIDE\Allied\vacancyedit.c fm:35)
at
cfvacancyedit2ecfm242791332.runPage(F:\data\webdesigns\wwwroot\CFIDE\Allied\vacancyedit.c fm:35)
com.inzoom.adojni.ComException: Parameter ?_5 has no default
value. in Microsoft JET Database Engine code=3088 Type=1
at com.inzoom.ado.Command.jniExecute(Native Method)
at com.inzoom.ado.Command.execute(Command.java:40)
at com.inzoom.jdbcado.Statement.exec(Statement.java:34)
at
com.inzoom.jdbcado.PreparedStatement.execute(PreparedStatement.java:201)
at
coldfusion.server.j2ee.sql.JRunPreparedStatement.execute(JRunPreparedStatement.java:87)
at coldfusion.sql.Executive.executeQuery(Executive.java:756)
at coldfusion.sql.Executive.executeQuery(Executive.java:675)
at coldfusion.sql.Executive.executeQuery(Executive.java:636)
at coldfusion.sql.SqlImpl.execute(SqlImpl.java:236)
at
coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:500)
at
cfvacancyedit2ecfm242791332.runPage(F:\data\webdesigns\wwwroot\CFIDE\Allied\vacancyedit.c fm:35)
at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:152)
at
coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:349)
at
coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
at
coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:225)
at
coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:51)
at coldfusion.filter.PathFilter.invoke(PathFilter.java:86)
at
coldfusion.filter.LicenseFilter.invoke(LicenseFilter.java:27)
at
coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:69)
at
coldfusion.filter.BrowserDebugFilter.invoke(BrowserDebugFilter.java:52)
at
coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:2 8)
at
coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
at
coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
at
coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
at
coldfusion.filter.RequestThrottleFilter.invoke(RequestThrottleFilter.java:115)
at coldfusion.CfmServlet.service(CfmServlet.java:107)
at
coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:78)
at
jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91)
at
jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at
jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:257)
at
jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:541)
at
jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:204)
at
jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:318)
at
jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:426)
at
jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:264)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)
sorry its such a long post but i thought it best to post all
the info. can anyone see what the problem is with my code?
thanks in advance
zacZac,
You really shouldn't make the Primary Key for the table
editable.
Try removing this from the form:
<label for="textfield">Auto ID</label>
<input
value="<cfoutput>#edit_vacancy.ID#</cfoutput>"
type="text" name="id" id="id">
And make it a hidden input like this:
<input
value="<cfoutput>#edit_vacancy.ID#</cfoutput>"
type="hidden" name="id" id="id">
Ken Ford
Adobe Community Expert
Fordwebs, LLC
http://www.fordwebs.com
"zac1234" <[email protected]> wrote in
message news:[email protected]...
> ok.. i have a vacancies page, each vacancy has a link
next to it called "edit"
> when you click on the link it does this:
>
> <a href="vacancyedit.cfm?ID=#ID#">
>
> on vacancyedit.cfm there is a form. the fields on the
form are populated with
> this query:
>
> <cfquery name="edit_vacancy"
datasource="allieddatabase">
> SELECT *
> FROM new_vacancy_table1
> WHERE ID = #ID#
> ORDER BY ID DESC
> </cfquery>
>
> the form looks like this:
>
> <form
action="<cfoutput>#CurrentPage#</cfoutput>"
method="POST"
> name="edit_vacancy_form">
>
> <label for="textfield">Auto ID</label>
> <input
value="<cfoutput>#edit_vacancy.ID#</cfoutput>"
type="text" name="id"
> id="id">
>
> <label for="label">Area</label>
> <input
value="<cfoutput>#edit_vacancy.area#</cfoutput>"
type="text"
> name="textfield2" id="label">
> <label for="label2">Pattern</label>
> <input
value="<cfoutput>#edit_vacancy.pattern#</cfoutput>"
type="text"
> name="textfield3" id="label2">
> <label for="label3">Hours</label>
> <input
value="<cfoutput>#edit_vacancy.hrs#</cfoutput>"
type="text"
> name="textfield4" id="label3">
> <label for="label4">Rate</label>
> <input
value="<cfoutput>#edit_vacancy.rate#</cfoutput>"
type="text"
> name="textfield5" id="label4">
> <label for="textarea">Description</label>
> <textarea name="textarea"
>
class="text_entry"><cfoutput>#edit_vacancy.description#</cfoutput></textarea>
> <br>
> <input type="submit" name="Submit" value="Submit"
id="submit_button">
> <input type="hidden" name="MM_UpdateRecord"
value="edit_vacancy_form">
> </form>
>
> so i make the alterations to the queried data as
required then click submit.
> this is the update code:
>
> <cfset
CurrentPage=GetFileFromPath(GetTemplatePath())>
> <cfif IsDefined("FORM.MM_UpdateRecord") AND
FORM.MM_UpdateRecord EQ
> "edit_vacancy_form">
> <cfquery datasource="allieddatabase">
> UPDATE new_vacancy_table1
> SET area=
> <cfif IsDefined("FORM.textfield2") AND
#FORM.textfield2# NEQ "">
> <cfqueryparam value="#FORM.textfield2#"
cfsqltype="cf_sql_clob"
> maxlength="50">
> <cfelse>
> ''
> </cfif>
> , pattern=
> <cfif IsDefined("FORM.textfield3") AND
#FORM.textfield3# NEQ "">
> <cfqueryparam value="#FORM.textfield3#"
cfsqltype="cf_sql_clob"
> maxlength="50">
> <cfelse>
> ''
> </cfif>
> , hrs=
> <cfif IsDefined("FORM.textfield4") AND
#FORM.textfield4# NEQ "">
> <cfqueryparam value="#FORM.textfield4#"
cfsqltype="cf_sql_clob"
> maxlength="50">
> <cfelse>
> ''
> </cfif>
> , rate=
> <cfif IsDefined("FORM.textfield5") AND
#FORM.textfield5# NEQ "">
> <cfqueryparam value="#FORM.textfield5#"
cfsqltype="cf_sql_clob"
> maxlength="50">
> <cfelse>
> ''
> </cfif>
> , "description"=
> <cfif IsDefined("FORM.textarea") AND #FORM.textarea#
NEQ "">
> <cfqueryparam value="#FORM.textarea#"
cfsqltype="cf_sql_clob">
> <cfelse>
> ''
> </cfif>
> WHERE ID=<cfqueryparam value="#FORM.id#"
cfsqltype="cf_sql_numeric">
> </cfquery>
> <cflocation url="vacancyadmin.cfm">
> </cfif>
>
> this should then update my changes and take me back to
vacancyadmin.cfm.
> however all i get is the following error message:
>
> Error Executing Database Query.
> Parameter ?_5 has no default value.
>
> The error occurred in
F:\data\webdesigns\wwwroot\CFIDE\Allied\vacancyedit.cfm:
> line 35
>
> 33 : ''
> 34 : </cfif>
> 35 : WHERE ID=<cfqueryparam value="#FORM.id#"
cfsqltype="cf_sql_clob"
> maxlength="10">
> 36 : </cfquery>
> 37 : <cflocation url="vacancyadmin.cfm">
>
> SQL UPDATE new_vacancy_table1 SET area= (param 1) ,
pattern= (param 2) ,
> hrs= (param 3) , rate= '' , "description"= (param 4)
WHERE ID= (param 5)
> DATASOURCE allieddatabase
> VENDORERRORCODE 3088
> SQLSTATE
> Resources:
>
> * Check the ColdFusion documentation to verify that you
are using the
> correct syntax.
> * Search the Knowledge Base to find a solution to your
problem.
>
> Browser Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US;
rv:1.8.1.3)
> Gecko/20070309 Firefox/2.0.0.3
> Remote Address 10.0.0.201
> Referrer
http://allied-srv-03/CFS/vacancyedit.cfm?ID=14
> Date/Time 07-Apr-07 12:56 PM
> Stack Trace
> at
>
cfvacancyedit2ecfm242791332.runPage(F:\data\webdesigns\wwwroot\CFIDE\Allied\vaca
> ncyedit.cfm:35) at
>
cfvacancyedit2ecfm242791332.runPage(F:\data\webdesigns\wwwroot\CFIDE\Allied\vaca
> ncyedit.cfm:35)
>
> com.inzoom.adojni.ComException: Parameter ?_5 has no
default value. in
> Microsoft JET Database Engine code=3088 Type=1
> at com.inzoom.ado.Command.jniExecute(Native Method)
> at com.inzoom.ado.Command.execute(Command.java:40)
> at com.inzoom.jdbcado.Statement.exec(Statement.java:34)
> at
com.inzoom.jdbcado.PreparedStatement.execute(PreparedStatement.java:201)
> at
>
coldfusion.server.j2ee.sql.JRunPreparedStatement.execute(JRunPreparedStatement.j
> ava:87)
> at
coldfusion.sql.Executive.executeQuery(Executive.java:756)
> at
coldfusion.sql.Executive.executeQuery(Executive.java:675)
> at
coldfusion.sql.Executive.executeQuery(Executive.java:636)
> at coldfusion.sql.SqlImpl.execute(SqlImpl.java:236)
> at
coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:500)
> at
>
cfvacancyedit2ecfm242791332.runPage(F:\data\webdesigns\wwwroot\CFIDE\Allied\vaca
> ncyedit.cfm:35)
> at
coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:152)
> at
coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:349)
> at
coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
> at
coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:225)
> at
coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:51)
> at
coldfusion.filter.PathFilter.invoke(PathFilter.java:86)
> at
coldfusion.filter.LicenseFilter.invoke(LicenseFilter.java:27)
> at
coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:69)
> at
coldfusion.filter.BrowserDebugFilter.invoke(BrowserDebugFilter.java:52)
> at
>
coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilt
> er.java:28)
> at
coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
> at
coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
> at
coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
> at
>
coldfusion.filter.RequestThrottleFilter.invoke(RequestThrottleFilter.java:115)
> at coldfusion.CfmServlet.service(CfmServlet.java:107)
> at
coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:78)
> at
jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91)
> at
jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
> at
jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:257)
> at
jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:541)
> at
>
jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:204)
> at
>
jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPool.java:318)
> at
>
jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:426)
> at
>
jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool.java:264)
> at
jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)
>
>
>
> sorry its such a long post but i thought it best to post
all the info. can
> anyone see what the problem is with my code?
>
> thanks in advance
>
> zac
>
>
Maybe you are looking for
-
How do I get Snow Leopard onto my Blackbook?
Hi folks. With Lion coming up, I have to have 10.6.8 on my Blackbook. A drive recently failed and I have installed Tiger onto it. My Pro has Snow Leopard on it, but I can't install it onto my laptop. How can I get Snow Leopard onto it? Cheers
-
Cold Weather Temperatures for Mac Pro Book
Hi I have meeting tomorrow, near the mountains, I wanted to take my mac Book Pro and keep it locked in the car for 3 to 4 hours while I ski.....before the meeting. The temperature should be around 20 degrees farenheit, is this too cold? Or should I b
-
NSM 2.5.2.1 - Massive DBASE directory
Today I noticed that the volume NSM is installed on was out of space, upon closer inspection I discovered the DBASE directory was just over 20GB, yes, 20GB. Is there anyway of purging old data from the dbase to free up space? Thanks, Gabriel
-
Regd. SAP Netweaver 7.0 & BI
Hi, I'm new to SAP and i want to learn SAP BI. For this i've downloaded "SAP Netweaver 7.0 Java VMWare" trial version. Is this the correct package or should i download "SAP NetWeaver 7.0 - Java and ABAP Trial Version on Linux - VMware Edition" Als
-
Mountain lion doesn't shut down.(Macbook pro with retina)
I had tried 3 times delete "com.apple.dock.plist" and conduct "sudo reboot /w", deleted "itunes help" from login item, It work for one day or two then problem come back again. Anyone could help me ?