Is it possible to create table templates in Filemaker? - filemaker

I'm using Filemaker Pro 12 and I was wondering if there is a way of creating a template for tables. There are a number of fields I'm placing in my tables that are identical utility-fields like modification time-stamp, active/inactive flags, etc. I was hoping there was a way that I could define the skeleton of each table somehow instead of having to manually add these identical fields every time.

If you are using the Advanced version, you can copy&paste fields among tables/files.
Using the regular version, you can import records from your "default" table and specify [New Table...] as the target table. This will recreate the source table's structure in the target file. The source table does not have to contain any records for this to work.

To expand a little bit on michael-hor257k's answer, if you're using FileMaker Pro Advanced, a good practice is to create a "Default" table that has your core utility fields. When you want to make a new table in Manage Database, instead:
Highlight the Default table,
Copy & Paste the table, then
Rename the new table.

Related

Filemaker Pro 14 History tables

With a few solutions Ive worked with I've created temp table's or history tables. Normally I script it to take a handful of fields needed from a main table and copy it over to the other table by
Setting a variable then setting field to the variable for each field in the new table / new record.
I have a situation now, where Im building a history table that needs to copy the current record as is. A snapshot where all fields from that instance of the record are copied to the history table.
Rather then setting a variable then set field to the variable, Id like to get some input on a quicker way to get this done where I can do this on a record level and not type out field by field to get it done. Also if fields are added to both tables then I have to make sure my script gets updated.
Ill keep hunting around.. appreciate any help.
-Rich
Do you have a sample of copying a record from 1 table to another
including all fields and setting some fields?
As I suggested in comments, use the Import Records[] script step, and select the same file as the source. If you choose Arrange by: [ matching names ] in the Import Field Mapping dialog, it will automatically map all source fields to their similarly named counterparts.
Note that you must establish a found set in the source table before importing.
For "setting some fields", you can define auto-enter options and activate them during the import, or run Replace Field Contents[] immediately after the import.

Some fields are missing in the fieldexplorer. How to show all fields?

i'm using Crystal Reports with my ERP-System. There have been predefined reports i now want to change.
In the field-explorer are some tables which have been renamed for better readability. But those tables are missing some fields, i want to use. If i connect the whole table again, all fields are there. Is there a way to display all fields in the predefined tables.
I tried to refresh the Database but nothing changes. If i delete the predefined table and then rename the new one to the old one, so i can use all predefinded formulas, all used fields in the report get deleted. I would need to recreate the whole report then.
Thanks for the help
If it is truly the same table and is not showing all the fields then you need to do "Database > Verify Database". That will force CR to refresh the structure of the table (instead of just the data). If this doesn't add the missing fields then the table in the report is actually a different object.
To see what the table/view the report is actually using go to "Database > Set DataSource Location" and look at the properties node for that table. It will show if it is a table/view/SP and what the true object name is.
If you want to replace the existing table with a different table you go to "Database > Set DataSource Location" again. Highlight the existing table in the top window, connect and highlight the replacement table in the bottom window. Then click update. Crystal will replace one table with the other and all of the fields in the report that exist in the new table will be mapped automatically. Note that the new table will keep the alias of the original table. If you are unsure if the table was updated you can look at the properties node in the top window to see the change.

Kentico Import Toolkit 8.1

I am currently using the Kentico Import Toolkit to create documents in the tree.
At this point, I have imported around 100 documents using the toolkit, and they are all located at the correct place in the tree. Now the issue/concern that I had was, as I have imported these documents, my spreadsheet has been updated, so extra fields and data were added, so how do I go about importing this extra data into the currently existing documents? Also just bear in mind I don't want other fields or data to be affected by this, as some of the documents were updated with some other content by the content editors using CMS Desk, which isn't available in the spreadsheet.
Import toolkit is not the right tool to achieve this task. Even if you select "Import new and overwrite existing pages" it'll overwrite most of your columns. Actually it only preserves system and id columns from the existing documents - all other columns get overwritten.
Either you can write a piece of custom code or you can try following:
Open SSMS and navigate to the coupled table of your page type (something like CONTENT_MyDocType). This is where your custom columns are stored.
Right click -> Edit top 200 rows
Click "Show SQL Pane"
Adjust the columns, ORDER BY and WHERE clause to match your excel file, re-run the query
Select desired rows in your excel file and copy them to clipboard
Paste the data in the SSMS
rocky is right, Import Toolkit is meant for importing complete objects, not partial/continuous update.
You could map the fields that you know are not changed in the spreadsheet to a SQL query selecting the value from the target database.
To achieve this, just insert #<target> at the beginning of the SQL select statement you will be mapping the field to.
It will be rather laborious though and it also requires certain knowledge about the nature of the spreadsheet changes.

Crystal: Autoupdating table names in database expert

It is more of an annoyance rather than real issue: when in Crystal reports you change the data source to one with different name (and do all the linking old columns to new columns) all the table names in Field explorer and (obviously) in formulas are changed. But the Database expert still shows the old table/view name!
Let me show this on example: Lets say I change TABLE_1 with column EQUIPMENT to VIEW_1 with column UNIT. Via the datasource location I can do the substitution and link old column EQUIPMENT to new one - UNIT.
But when I check either Datasource location or database expert it will be still showing old TABLE_1 (if you check the columns in the link tab you will notice that the TABLE_1 has now column UNIT instead of EQUIPMENT).
This can be quite annoying and frankly bit dangerous, especially if you return to report after a longer while. Is there somewhere a setting that allows to autoupdate table names in the database expert?
When you create the report it will create tables and each table will be linked to a datasource table. So the report table will have a name and datasource , which might be the same. When you change the datasource the datasource of the table will be updated but the report table name will remain the same. Think about this name as an alias. It might differs from th datasource name if you use the same table multiple times
I don't think there is auto update option in crystal reports but one thing you can do is to use Verify Database option under Database tab whenever you update the tables.
You need to manually edit table names in Database expert, there's no automatic way (and like Lan already answered, it is generally not possible).

Tableau: mapping fields in new datasource when field names are different in the new version

I had some trouble previously when I wanted to take an existing visualization in tableau, and re-use it for a very similar data-set, but one where the field names are different.
In one case, as a workaround, I just renamed the new fields to the original field names even if the name didn't really apply. this allowed me to use the same chart I like. However, I wondered if there was a clean way to import a new data source and map the fields in the chart to the new field "titles" and preserve the chart?
I'm relatively new to tableau, so I'm sorry if this has been answered previously (I imagine it has somewhere). thanks
Right click on a field in the data view pane and select "replace references"
This is essentially a replace-all feature. Usually, you would do this when a field in the data source no longer exists by the original name (and is shown with a red X). Rather than recreating all your views, if there is a new field that you can use instead, you can replace all references to the old field with the new one in one command.
You could also use custom SQL to specify field names, define a database view or rename fields as you suggest