Iron Speed Technical Forums
Register Latest Topics
 
 
 


Reply
  Author   Comment  
rchurch22

Registered:
Posts: 8
Reply with quote  #1 
I am trying to import an excel file from a child table using a Parent Page with a Child Tab. I have added the import button and it does import the data within the Excel file, but it does not put in the FK on the data to keep the relationship together. I had to turn off the "not null" option in the SQL table to get it to insert. I have read through the forums and found a few articles similar, but none had an absolute solution. I have tried passing the FK as a session variable, but not exactly sure where to put that in. The excel file does not have a field for the FK so I would need to add this to each line as it is being inserted.

Currently I am using a web site for .net with .net 3.5.

The parent table is Jobs with a PK of JobID and the child table is Job Details with a FK of JobID

Any help or suggestions would be greatly appreciated.

Thank you

__________________
Robert Church
JBEMETO

Registered:
Posts: 160
Reply with quote  #2 
Hello,
If the FK exists you will have no problems importing the child records.
In creating the relationship ensure that the FK is not mandatory, otherwise you must supply the FK values at the child level

__________________
JBEMETO
rchurch22

Registered:
Posts: 8
Reply with quote  #3 
The file that I am uploading does not have the FK within the file so I need to supply it at the child level. I have done this by passing it as a session variable, but can't seem to get it into the import. Making the FK no mandatory does allow the file to load, but it does not have any relationship to the parent without the FK.
__________________
Robert Church
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Download Iron Speed Designer

Terms of Service Privacy Statement