Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

when i import my records from an excel file, the info gets split into different records. The file lists the info like this:

Order Number Sku # Title

Author

Print PN Condition

So when it imports it imports three lines as three records. The first record has the order number, sku, and title in their correct fields. The second record only has the author in the title field. And the Third record has "Print PN" in the order number field and condition in the Title field. I can easily move the author name by using a script like this:

Goto Layout ordermanager

show all records

go to first

loop

If ["ordernumber = """]

Copy [select, "title"]

delete record [no diag]

goto previous

Paste [select, Author]

Goto next [exit after last]

else

goto next [exit after last]

end loop

If i duplicate it to move the condition it will skip the second condition so that record one contains the info that corresponds to record one, record 2 contains info for record two except the condition field contains info from record 3 and record 3 conatins all the correct info except the condition field contains the info from record 4, etc look at the pic. I had to change the extension to gif to upload so just chagne it back to a bmp when you download it. Thanks for the help.

Posted

It can be a major pain scripting the collapse of multiple records into a single record. I'd take another look art the excel file. Apparently, your fields are listed vertically, and they should be horizontal. FM will assume that each horizontal row is a single record. Maybe you can rejigger the excel so your three fields are columns rather than rows.

You might also try saving the excel file as a tab-delimited text doc, and import into FM from that.

Steve Brown

Posted

And your question is?

I'll take a guess and assume you are looking for an easier method. FM assumes each new row is a record and each new column a field. I would use the excel copy and Paste Special with the Transpose option to interchange rows and columns before importing into FM.

-bd

Posted

If the excel file is imported on a regular basis, and structure not changed, try

this attachment. it also shows how to deal with serial numbers after multi-line import as well (but this is concept only, not much error checking).

Basically, the file uses auto-enter calcs based on a Mod(SerialNumber;3) calculation. [as we have 3 lines making up the record], and a "fill-down" loop.

Just press button 1, 2,3and 4 consecutuvely. In real live, this would be automatic, but this way it leaves more to play with.

import_3_rows.zip

This topic is 7894 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.