Friday, February 10, 2012
  Search
Support Forum
hidden fielkd with field query
Last Post 09 Jan 2010 02:30 PM by judy. 2 Replies.
AddThis - Bookmarking and Sharing Button Printer Friendly
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
judy
New Member
New Member
Send Private Message
Posts:15


--
07 Jan 2010 04:33 PM  
I have a a hidden field with a field query to calculate mmddyyhhmm (time and date). I test the query and I see good results.

I have a token set on the hidden filed called [DATETIME].  I have this token set on my custom email template

I have a field name called DateTime and it is mapped in the table - it is nvar set to 10.

I complete the form and submit.

When I go to the table I see the column for DateTime but it is empty.

When I get the email the [DATETIME] is blank

Why is the query not getting into the field/token?

Here is the query I used to calculate (I got it from this forum :):
<!--[if gte mso 9]> Normal 0 false false false MicrosoftInternetExplorer4 <!-- /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman";} @page Section1 {size:8.5in 11.0in; margin:1.0in 1.25in 1.0in 1.25in; mso-header-margin:.5in; mso-footer-margin:.5in; mso-paper-source:0;} div.Section1 {page:Section1;} --> <!--[if gte mso 10]> select CASE len(datepart(mm,GetDATE())) when 1 then '0'+convert(varchar,datepart(mm,GetDATE())) else convert(varchar,datepart(mm,GetDATE())) end+

CASE len(datepart(dd,GetDATE())) when 1 then '0'+convert(varchar,datepart(dd,GetDATE())) else convert(varchar,datepart(dd,GetDATE())) end+

substring(convert(varchar,datepart(yy,GetDATE())),3,2)+

CASE len(datepart(hour,GetDATE())) when 1 then '0'+convert(varchar,datepart(hour,GetDATE())) else convert(varchar,datepart(hour,GetDATE())) end+

CASE len(datepart(minute,GetDATE())) when 1 then '0'+convert(varchar,datepart(minute,GetDATE())) else convert(varchar,datepart(minute,GetDATE())) end as TrackNumber




Code 5
Moderator
Advanced Member
Advanced Member
Send Private Message
Posts:907


--
07 Jan 2010 11:38 PM  
Lets start with a more simple SQL statement to populate the hidden field

See this link.

http://www.code5systems.com/Support...fault.aspx
judy
New Member
New Member
Send Private Message
Posts:15


--
09 Jan 2010 02:30 PM  
Thanks, the above query worked fine (I couldn't get the simpler one to work). My problem turned out to be much more fundamental. I did not have my form set-up to properly auto fill with the results of the query. This product is great, but sometimes I have trouble figuring out how to make all of the pieces work together. I there more documentation available that covers how to make all the pieces work together. The users guide is good at explaining set-up items individually, but more of a "how to" would be really helpful. However, this forum is great and your quick replies usually help me put the pieces together.

Judy
You are not authorized to post a reply.

Active Forums 4.2
Copyright 2004-2012 Code 5 Systems, LLC.