Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 4974 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Many thanks for the reply. It is very useful but what I need is a report which only shows cMonth and sTotal_Weight. Also I like to use them to make a chart. is it possible?

Posted

I need is a report which only shows cMonth and sTotal_Weight.

Use a layout with no body part. It needs to be in List view - a Table view won't work for this.

Posted

Well my problem doesn't solve with this solution. I thing it needs more explanation.

I attach the script which shows Persian Calendar range. what I need is cMonth sets for each range which is a persian month and shows in the report.

is it possible?

Script.jpg

Posted

I need is cMonth sets for each range which is a persian month

That's very different from:

design cMonth to calculate from 20th of each month to 19th next month

I don't see what your script is supposed to accomplish. I'd suggest you add a table of PersianMonths, with fields for MonthName and MonthStart - then lookup the month name from there using a relationship.

Or calculate the Persian month - IF you can find an algorithm you trust. See:

http://fmforums.com/forum/topic/74931-i-need-solar-calendar-for-fm-how-can-i-get-it/page

Posted

I followed the link and got so happy because I find that you are very familiar with persian calendar.

I will explain what i did till now. I created a table "Calendar" with two fields. 1-G_Date (date), 2-Sh_Date (Text)and made 365 records with equal date.

I also created another table "Production" included bellow fields:

Prod_date

Device_name

Prod_name

Prod_QTY

Prod_weight

Operator_name

I linked Prod_date to Sh_Date.

I need a script to make a annual report of any of fields in Production table while using Calendar table.

as you suggested, I have to create cMonth, but I don't know what should the calculation be and how to use any of Prod_date, G_date or Sh_Date.

kind regards

Posted

The "secret" for grouping records in a report is to have a field with a value that is common to all records in the group. In my example, the cMonth field returns the date of January 1, 2011 for all records in that month.

If your Calendar table were built like:


GregorianDate    PersianMonth

...

2011-5-19        1390-02

2011-5-20        1390-02

2011-5-21        1390-02

2011-5-22        1390-03

2011-5-23        1390-03

2011-5-24        1390-03

...

you could group your records by the related Calendar::PersianMonth field - after defining a relationship matching:

Production::Prod_date = Calendar::GregorianDate

This topic is 4974 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.