You want to select records after date1 and before date2.

First you need to know the timestamp format you're using. (see the docs on Format attribute).

Then convert date1 and date2 to timestamp format, eg:

<@ASSIGN NAME="@@request$ts1" VALUE="<@VAR SCOPE='request' NAME='date1' FORMAT='%Y-%m-%d %H:%M:%S'>"> <@ASSIGN NAME="@@request$ts2" VALUE="<@VAR SCOPE='request' NAME='date2' FORMAT='%Y-%m-%d %H:%M:%S'>">
Note (the above format is just a guess).

Then use ts1 and ts2 in your query:

BTW, instead of having Witango insert records using a value of <@CURRENTTIMESTAMP> for a column, investigate having the DBMS do it -- it's faster.

Bill


On Feb 23, 2008, at 8:50 PM, James Robb wrote:

Hi

I am still learning WiTango and I am not sure how to extract records between two dates to export to a file. I am able to pull all the reocrds from the table with out any problem. The date is stored in the table using the <@tstosecs ts=<@currenttimestamp>> tag. So what I need to do is create a date range so we can pull out the records for a specific time frame. I know I need to convert the field back to a Date using this tag <@secstodate secs=<@COLUMN dbo.table.cell">> after this I am not sure how to create the range from the dates in the file, if any one can point me in the rigth direction I would much appreciate it.

Best,
James Robb ______________________________________________________________________ __ TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Reply via email to