mshar Posted March 13, 2007 Posted March 13, 2007 (edited) Hi, Is there a way to clean-up the database by removing all the unwanted carriage returns (CR) and line feeds (LF). I don't want to do it manually by going to each value and deleting this unwanted special lower level characters. Some kind of script or option in Filemaker would be good. Thanks, Max Edited March 13, 2007 by Guest
mr_vodka Posted March 13, 2007 Posted March 13, 2007 What is this "unwanted special lower level character" ? Can you post a sample of what the data looks like and then what you want it to look like?
mshar Posted March 13, 2007 Author Posted March 13, 2007 When I import tables from Filemaker to SQL Sever, for some values, I get characters at the end of the value that look like small boxes. I found out that these characters were actually CR or LF characters which were already present in the source tables in Filemaker (a data entry problem). This creates problem when I am writing queries in SQL. For example, take a value of field Empl_Name as John, so a value John is treated differently than John{CR or LF} but these characters are not visible in Filemaker. So, is there a way to clean all the tables by removing these unwanted linefeeds of carriage returns. Thanks, Max
efen Posted March 13, 2007 Posted March 13, 2007 Use Substitute with a looping script to clean out the character from all records before they are exported
mshar Posted March 13, 2007 Author Posted March 13, 2007 Do you have a sample of the script? Thanks, Max
efen Posted March 13, 2007 Posted March 13, 2007 pseudo code: Goto first record Set field Textfield, Substitute(Textfield,"unwanted cr character","") Loop Goto next record (exit after last) Set field Textfield, Substitute(Textfield,"unwanted cr character","") End loop
mshar Posted March 13, 2007 Author Posted March 13, 2007 Thank yo so much. Let me work on this one. Thanks, Max
Lee Smith Posted March 13, 2007 Posted March 13, 2007 Yes, You will find it in the List of Functions (Right Top) of the Calculation Edit Box. HTH Lee
mr_vodka Posted March 13, 2007 Posted March 13, 2007 Just as a FYI, you could also use 'Replace field contents' with specified results to use it on your found set without a loop script. If you want it on all the records, just do a show all records first.
Lee Smith Posted March 13, 2007 Posted March 13, 2007 and... Caution. You can't Undo these functions. So, you should test this on a copy of your file, not original. Lee
mshar Posted March 13, 2007 Author Posted March 13, 2007 Thank you all...you have been of great help.
Recommended Posts
This topic is 6526 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 accountSign in
Already have an account? Sign in here.
Sign In Now