PC Review


Reply
Thread Tools Rate Thread

Database field update with added text.

 
 
Mettá
Guest
Posts: n/a
 
      27th Jun 2005
When a user updates a memo field via a form I want to add an addition at the
end to say something like
Updated dd/mm/yyyy

I have done this by adding a hidden field to the form which repeats the
field name with the value
Updated <%=Now()%>

However it shows up as
..... text, Updated dd/mm/yyyy

I get the usual FP warning about duplicate field names and it works but I
would like to get rid of the comma.

How can I prevent the comma showing up??

Thanks
M


 
Reply With Quote
 
 
 
 
Thomas A. Rowe
Guest
Posts: n/a
 
      27th Jun 2005
You have to combine the two fields together prior to inserting/updating the single field in the
database. Each field on the form must be uniquely named.

Memo1 = request.form("memofield")
MUpdate = request.form("memoupdate")

Memo = Memo1 + "<br>" + "Updated " + MUpdate

This will require you to hand write the entire ASP/VBScript code to update the record.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WebMaster Resources(tm)
http://www.ycoln-resources.com
FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================

"Mettá" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> When a user updates a memo field via a form I want to add an addition at the end to say something
> like
> Updated dd/mm/yyyy
>
> I have done this by adding a hidden field to the form which repeats the field name with the value
> Updated <%=Now()%>
>
> However it shows up as
> .... text, Updated dd/mm/yyyy
>
> I get the usual FP warning about duplicate field names and it works but I would like to get rid of
> the comma.
>
> How can I prevent the comma showing up??
>
> Thanks
> M
>



 
Reply With Quote
 
Mettá
Guest
Posts: n/a
 
      27th Jun 2005
Thanks, I will have a go.

M


"Thomas A. Rowe" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> You have to combine the two fields together prior to inserting/updating
> the single field in the database. Each field on the form must be uniquely
> named.
>
> Memo1 = request.form("memofield")
> MUpdate = request.form("memoupdate")
>
> Memo = Memo1 + "<br>" + "Updated " + MUpdate
>
> This will require you to hand write the entire ASP/VBScript code to
> update the record.
>
> --
> ==============================================
> Thomas A. Rowe (Microsoft MVP - FrontPage)
> WebMaster Resources(tm)
> http://www.ycoln-resources.com
> FrontPage Resources, WebCircle, MS KB Quick Links, etc.
> ==============================================
> If you feel your current issue is a results of installing
> a Service Pack or security update, please contact
> Microsoft Product Support Services:
> http://support.microsoft.com
> If the problem can be shown to have been caused by a
> security update, then there is usually no charge for the call.
> ==============================================
>
> "Mettá" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> When a user updates a memo field via a form I want to add an addition at
>> the end to say something like
>> Updated dd/mm/yyyy
>>
>> I have done this by adding a hidden field to the form which repeats the
>> field name with the value
>> Updated <%=Now()%>
>>
>> However it shows up as
>> .... text, Updated dd/mm/yyyy
>>
>> I get the usual FP warning about duplicate field names and it works but I
>> would like to get rid of the comma.
>>
>> How can I prevent the comma showing up??
>>
>> Thanks
>> M
>>

>
>



 
Reply With Quote
 
Mettá
Guest
Posts: n/a
 
      28th Jun 2005
<%Dim text1c
Text1c=request.form("text1")&request.form("text1b")%>


The above outputs Text1 and Text1b as one string on screen with <%=text1c%>
but it does not save to the db??

The sql reads as
bla...text1='::text1c::'...


What am I doing wrong?



"Mettá" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Thanks, I will have a go.
>
> M
>
>
> "Thomas A. Rowe" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> You have to combine the two fields together prior to inserting/updating
>> the single field in the database. Each field on the form must be uniquely
>> named.
>>
>> Memo1 = request.form("memofield")
>> MUpdate = request.form("memoupdate")
>>
>> Memo = Memo1 + "<br>" + "Updated " + MUpdate
>>
>> This will require you to hand write the entire ASP/VBScript code to
>> update the record.
>>
>> --
>> ==============================================
>> Thomas A. Rowe (Microsoft MVP - FrontPage)
>> WebMaster Resources(tm)
>> http://www.ycoln-resources.com
>> FrontPage Resources, WebCircle, MS KB Quick Links, etc.
>> ==============================================
>> If you feel your current issue is a results of installing
>> a Service Pack or security update, please contact
>> Microsoft Product Support Services:
>> http://support.microsoft.com
>> If the problem can be shown to have been caused by a
>> security update, then there is usually no charge for the call.
>> ==============================================
>>
>> "Mettá" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>>> When a user updates a memo field via a form I want to add an addition at
>>> the end to say something like
>>> Updated dd/mm/yyyy
>>>
>>> I have done this by adding a hidden field to the form which repeats the
>>> field name with the value
>>> Updated <%=Now()%>
>>>
>>> However it shows up as
>>> .... text, Updated dd/mm/yyyy
>>>
>>> I get the usual FP warning about duplicate field names and it works but
>>> I would like to get rid of the comma.
>>>
>>> How can I prevent the comma showing up??
>>>
>>> Thanks
>>> M
>>>

>>
>>

>
>



 
Reply With Quote
 
Mettá
Guest
Posts: n/a
 
      28th Jun 2005
I also tried

set Text1=('::Text1::'&'::Text1a::')

and
set Text1='::Text1::'&'::Text1a::'

within the sql update

Thanks
M


"Mettá" <(E-Mail Removed)> wrote in message
news:u1nBTW$(E-Mail Removed)...
> <%Dim text1c
> Text1c=request.form("text1")&request.form("text1b")%>
>
>
> The above outputs Text1 and Text1b as one string on screen with
> <%=text1c%> but it does not save to the db??
>
> The sql reads as
> bla...text1='::text1c::'...
>
>
> What am I doing wrong?
>
>
>
> "Mettá" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Thanks, I will have a go.
>>
>> M
>>
>>
>> "Thomas A. Rowe" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>>> You have to combine the two fields together prior to inserting/updating
>>> the single field in the database. Each field on the form must be
>>> uniquely named.
>>>
>>> Memo1 = request.form("memofield")
>>> MUpdate = request.form("memoupdate")
>>>
>>> Memo = Memo1 + "<br>" + "Updated " + MUpdate
>>>
>>> This will require you to hand write the entire ASP/VBScript code to
>>> update the record.
>>>
>>> --
>>> ==============================================
>>> Thomas A. Rowe (Microsoft MVP - FrontPage)
>>> WebMaster Resources(tm)
>>> http://www.ycoln-resources.com
>>> FrontPage Resources, WebCircle, MS KB Quick Links, etc.
>>> ==============================================
>>> If you feel your current issue is a results of installing
>>> a Service Pack or security update, please contact
>>> Microsoft Product Support Services:
>>> http://support.microsoft.com
>>> If the problem can be shown to have been caused by a
>>> security update, then there is usually no charge for the call.
>>> ==============================================
>>>
>>> "Mettá" <(E-Mail Removed)> wrote in message
>>> news:(E-Mail Removed)...
>>>> When a user updates a memo field via a form I want to add an addition
>>>> at the end to say something like
>>>> Updated dd/mm/yyyy
>>>>
>>>> I have done this by adding a hidden field to the form which repeats the
>>>> field name with the value
>>>> Updated <%=Now()%>
>>>>
>>>> However it shows up as
>>>> .... text, Updated dd/mm/yyyy
>>>>
>>>> I get the usual FP warning about duplicate field names and it works but
>>>> I would like to get rid of the comma.
>>>>
>>>> How can I prevent the comma showing up??
>>>>
>>>> Thanks
>>>> M
>>>>
>>>
>>>

>>
>>

>
>



 
Reply With Quote
 
Thomas A. Rowe
Guest
Posts: n/a
 
      28th Jun 2005
Ok, based on my example:

Memo1 = request.form("memofield")
MUpdate = request.form("memoupdate")
MemoA = Memo1 + "<br>" + "Updated " + MUpdate


SQL Insert Statement:

Memofile = '" & MemoA & "'

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WebMaster Resources(tm)
http://www.ycoln-resources.com
FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================

"Mettá" <(E-Mail Removed)> wrote in message
news:u1nBTW$(E-Mail Removed)...
> <%Dim text1c
> Text1c=request.form("text1")&request.form("text1b")%>
>
>
> The above outputs Text1 and Text1b as one string on screen with <%=text1c%> but it does not save
> to the db??
>
> The sql reads as
> bla...text1='::text1c::'...
>
>
> What am I doing wrong?
>
>
>
> "Mettá" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Thanks, I will have a go.
>>
>> M
>>
>>
>> "Thomas A. Rowe" <(E-Mail Removed)> wrote in message news:(E-Mail Removed)...
>>> You have to combine the two fields together prior to inserting/updating the single field in the
>>> database. Each field on the form must be uniquely named.
>>>
>>> Memo1 = request.form("memofield")
>>> MUpdate = request.form("memoupdate")
>>>
>>> Memo = Memo1 + "<br>" + "Updated " + MUpdate
>>>
>>> This will require you to hand write the entire ASP/VBScript code to update the record.
>>>
>>> --
>>> ==============================================
>>> Thomas A. Rowe (Microsoft MVP - FrontPage)
>>> WebMaster Resources(tm)
>>> http://www.ycoln-resources.com
>>> FrontPage Resources, WebCircle, MS KB Quick Links, etc.
>>> ==============================================
>>> If you feel your current issue is a results of installing
>>> a Service Pack or security update, please contact
>>> Microsoft Product Support Services:
>>> http://support.microsoft.com
>>> If the problem can be shown to have been caused by a
>>> security update, then there is usually no charge for the call.
>>> ==============================================
>>>
>>> "Mettá" <(E-Mail Removed)> wrote in message
>>> news:(E-Mail Removed)...
>>>> When a user updates a memo field via a form I want to add an addition at the end to say
>>>> something like
>>>> Updated dd/mm/yyyy
>>>>
>>>> I have done this by adding a hidden field to the form which repeats the field name with the
>>>> value
>>>> Updated <%=Now()%>
>>>>
>>>> However it shows up as
>>>> .... text, Updated dd/mm/yyyy
>>>>
>>>> I get the usual FP warning about duplicate field names and it works but I would like to get rid
>>>> of the comma.
>>>>
>>>> How can I prevent the comma showing up??
>>>>
>>>> Thanks
>>>> M
>>>>
>>>
>>>

>>
>>

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Added table to database, added to form, now cannot update =?Utf-8?B?ZGhvZWZ0?= Microsoft Access Forms 1 22nd Mar 2006 09:54 PM
Update Query to populate newly added field =?Utf-8?B?dmFidWxvdXM=?= Microsoft Access Queries 3 12th Apr 2005 04:49 PM
Update Field on New Record Added =?Utf-8?B?Q0s=?= Microsoft Access Forms 2 14th Dec 2004 02:45 PM
update oledb database from text field =?Utf-8?B?UGFtIEFtbW9uZA==?= Microsoft C# .NET 9 27th Nov 2004 03:39 PM
Added text field to database. New entries not equal to "" ??? Noozer Microsoft Access 3 18th Jun 2004 01:33 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:39 AM.