Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Due today

Status
Not open for further replies.

mudflap

MIS
Feb 14, 2002
194
CA
I need to scan through a date field and match it to todays date and spit out the ones that are due today.
Any ideas how to do that?
 
in the conditional suppress of the detail line put

{table.datefield} <> currentdate


only trick is making sure the {table.datefield} is not a date/time field...I hate those since rarely do you need the time in a report

if it is a datetime value then use

Date({table.datefield}) <> currentdate

Jim
JimBroadbent@Hotmail.com
 
I am a real idiot when it comes to this.
I tried making a formula and it said that there is a missing string.

{Prepress WIP.Due Date (Proofs) (User Defined)} <> currentdate

What do you mean by:
&quot;in the conditional suppress of the detail line put&quot;
Thanks
Peter

 
&quot;{Prepress WIP.Due Date (Proofs) (User Defined)} &quot;

What is this??? Proofs?? User Defined??

not a standard report field...are you trying to multiply something??

I think you should do some basic reading on how Crystal works, Peter. George Peck's book on Crystal reports:

The Complete Reference Crystal Reports 8.5 would be a good choice for you.

If you look in the Section Expert of a report and click on a specific section you will see a number of options such as &quot;Suppress Blank Section&quot; or &quot;New Page After&quot;. Beside these options are small buttons with X2 on them .... you will see these buttons also in the format editor of a field. These are conditional formula locations. Click on these buttons and you can put a formula that will conditionally do the option rather than all or nothing.

For example:

Let us say I only want a detail line to be suppressed if a field {Table.fruit} is equal to &quot;APPLE&quot;

then in the section expert in the detail section there is an option to &quot;suppress (no drill down)&quot;. Now you don't want to check the box off for this option since it will suppress ALL detail lines...BUT if you click on the X2 button and add the formula:

WhilePrintingRecords;
{Table.fruit} = &quot;APPLE&quot;;

then now when this is true...the line will be suppressed.

So we would describe it here when advising someone by saying....&quot;put this formula in the conditional suppress of the detail line&quot; or if it was just a formula field we would say ....&quot;put this formula in the conditional suppress of the field, {Table.fruit} &quot;



Jim
JimBroadbent@Hotmail.com
 
I wish I had the cash for the book...But the company just layed off people and I have to do this.. Unfortuantly I am gone here in a month so no money for books. As much as I need one...Anyways..

I tried this.

WhilePrintingRecords;
{Prepress WIP.Due Date (Proofs) (User Defined)} = currentdate

I am trying to put this were you tell me.
How do I get it to check the current date and print which are due today??? That {Prepress WIP.Due Date (Proofs) (User Defined)} is just a field in out form from Outlook.


Thanks
Peter
 
are you saying that you only want the report to bring in the ones that are due today?

LMC cryerlisa@hotmail.com

select * from Management where proj_mgmt_skills <> NULL

0 records returned
 
sorry but I don't understand this syntax:

{Prepress WIP.Due Date (Proofs) (User Defined)} Jim
JimBroadbent@Hotmail.com
 
That is just a field pulled from our Outlook Form.
Don't worry about the user defined part. That is just text.

PLain and simple I want to know which jobs are due today by getting Crystal reports to scan through that field and put that on the report.

Thanks alot















 
Mudflap-

Put the folowing in your record selection formula:

{Prepress WIP.Due Date (Proofs) (User Defined)} in CurrentDate

This will restrict records on the report to only those that are due today. Software Support for Macola, Crystal Reports and Goldmine
dgilsdorf@mchsi.com
 
I get a string is required here..And it moves to the front of current date..
I don't want to restrict the dates. Because I need to see them all and also make like a sub line that will tell me which or how many are due today...Just for a quick reference.
I know I am a huge pain... sorry..

Hopefully my next job can afford atleast to buy me a good book.

Thanks
Peter
 
cant you just set a formula that says

if date(Prepress WIP.Due Date) in currentdate then
(whatever you want here that will show that it is in todays date)
else &quot;&quot;

??? LMC cryerlisa@hotmail.com

select * from Management where proj_mgmt_skills <> NULL

0 records returned
 
Tried that one...
Just keeps saying string is requird here and points to the current date field...This is so frusterating.


Hmmm...Thanks for the help. Not sure what to do.
 
ohhhh


AH! ok. I think what is happening is your db field is a string field, yes?

you cant compare a string field as being IN a date field...

what I would try doing is putting this:

todate( )

around your database field and see if that balances it off so that it reads as a date ...

LMC cryerlisa@hotmail.com

select * from Management where proj_mgmt_skills <> NULL

0 records returned
 
Here is what I put in.

if date todate ({Prepress WIP.Due Date (Proofs) (User Defined)}) in currentdate then
&quot;showdate&quot;
else &quot;&quot;

Gives me errors saying I need a then after the todate.
Also what should I put in the &quot;showdate&quot; spot..


Thanks
 
Well,

I see your error - you should remove the word date...so it
looks like this...


if todate({Prepress WIP.Due Date (Proofs) (User Defined)}) in currentdate then
&quot;showdate&quot;
else &quot;&quot;

what you put in &quot;showdate&quot; will depend on what your user wants to see. What do you want it to tell you if it is in the current date? Do you want to sort by it? Do you want a little asterisk that shows up when it is = currentdate?

You are going to need to look at that field called
{Prepress WIP.Due Date (Proofs) (User Defined)} ...
see what the datatype is..because this does not look like
a standard field in a database, I have not seen anything like this before. Can you tell me what datatype it is??


LMC cryerlisa@hotmail.com

select * from Management where proj_mgmt_skills <> NULL

0 records returned
 
Still tells me it is expecting a number, boolean or string in front of the todate part
 
ok, that is because you have a string as your output.

try replacing the &quot;showdate&quot; with 0 and then else 0 and see what that does LMC cryerlisa@hotmail.com

select * from Management where proj_mgmt_skills <> NULL

0 records returned
 
I need to know more about your field that you are using with the date in it. What is the datatype? What does the data inside of it LOOK LIKE?

LMC cryerlisa@hotmail.com

select * from Management where proj_mgmt_skills <> NULL

0 records returned
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top