I would suggest breaking out a related table. I'm going to list the steps I would take, hoping that someone will chime in with an easier way. I find myself brute-forcing things too often...

Do a find on the existing table to get any checkbox values in the found set.
Sort the existing table by it's unique id.
Export the unique id and the checkbox field as a .csv.
open that .csv in a text editor and:
replace all quotes with nothing
replace all ascii 11 (the checkbox separation character) with a return and a comma
replace all commas with tabs
save the file with a .tab extension

What I'm doing there is to turn this:

"1","Maybe"
"2","NoIDK"
"3","YesMaybe"
"4","Yes"
"5","IDK"
"6","IDK"
"7","IDK"
"8","No"
"9","Maybe"
"10","Yes"
"11","Maybe"
"12",""
"13",""
"14","YesMaybe"

(of course that ascii 11 char isn't going to show up in email, but it's there between the checkbox values in records 2, 3 and 14.)

into this:

1       Maybe
2       No
        IDK
3       Yes
        Maybe
4       Yes
5       IDK
6       IDK
7       IDK
8       No
9       Maybe
10      Yes
11      Maybe
12      
13      
14      Yes
        Maybe

Import that into your new table, which has it's own auto-enter serial id field, the foreign key field, and a value field. the parent id goes into the foreign key field. Yes, it's missing some values. But since it was sorted when we started, we know what those values should be. Record number 3 should relate to parent record id 2, record 5 goes with parent 3, etc. This following script will fill in those missing values:

Fill Down Script:

Go to Record/Request/Page [ First ]
Set Variable [ $last; Value:"" ]
Loop
 If [ IsEmpty(new table::foreign key) ]
  Set Field [ new table::foreign key; $last ]
 Else
  Set Variable [ $last; Value:new table::foreign key ]
 End If
 Go to Record/Request/Page [ Next; Exit after last ]
End Loop


here's the resulting new table:

id      Fkey    Value
1       1       Maybe
2       2       No
3       2       IDK
4       3       Yes
5       3       Maybe
6       4       Yes
7       5       IDK
8       6       IDK
9       7       IDK
10      8       No
11      9       Maybe
12      10      Yes
13      11      Maybe
14      12      
15      13      
16      14      Yes
17      14      Maybe

The new table is joined to the old parent thusly:
Parent Unique ID = Child Foreign Key

You will have some work to do converting that 45 checkbox field into a portal for the new child table...

Hope that helps,

geoff

On Sep 9, 2009, at 5:05 PM, Tami Williams wrote:

Thanks in advance.

Using FileMaker 10 on MacOX 10.411 I need ideas on how to convert a checkbox with approximately 45 different checkbox values, into 45 different fields on the same record.

There are about 44,000 records and more than one checkbox like this.

All ideas welcome.

Thanks.


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"It's better to burn out than to fade away."

Tami Williams
Creative Computing
Improve, manage and unify data with custom database and web applications.
FileMaker and Lasso specialist.

Tel: 770.457.3221
Fax: 770.454.7419
E-Mail: [email protected]
Web: http://www.asktami.com

FileMaker Solutions Alliance Associate | Lasso Professional Alliance Member

Reply via email to