close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Manage Relational Table - Working Tutorial?

Thread began 12/16/2010 7:44 am by Andrew Read | Last modified 5/10/2011 8:42 am by Andrew Read | 10925 views | 21 replies

Andrew Read

Manage Relational Table - Working Tutorial?

Hello,

Just wondering if there is a working tutorial for the Manage Relational Table (MRT) Server Behaviour? I have done some reading from the site and can't quite get it working. None of my checked items get inserted into the binding table.

I have three tables (Contracts, Venues, Link_CV.)

Contracts - contains contract information
Venues - contains venue information
Link CV - has unique ID and two fields "venue_ID" and "Contract_ID"

1. On insert page I have removed redirect URL from DataAssist insert behaviour.

2. I have created a looping checkbox set using a database query that retrieves all of the venues.

php:
<?php $setRows=0?><?php do { ?>
          <?php
    
// RepeatSelectionCounter_1 Begin Loop
    
$RepeatSelectionCounter_1_IterationsRemaining $RepeatSelectionCounter_1_Iterations;
    while(
$RepeatSelectionCounter_1_IterationsRemaining--){
        if(
$RepeatSelectionCounterBasedLooping_1 || $row_getVenues){
?>
          <div id="repeatBox">
            <label>
              <input type="hidden" name="WADA_RepeatID_venue_id_<?php echo $RepeatSelectionCounter_1?>" id="WADA_RepeatID_venue_id_<?php echo $RepeatSelectionCounter_1?>" value="<?php echo $row_getVenues["venue_id"]; ?>" />
              <input <?php if (!(strcmp($row_getVenues['venue_id'],WA_AB_returnPreSelectValue($WA_PreSelect_RelationalTable_1$row_getVenues['venue_id'])))) {echo "checked=\"checked\"";} ?> type="checkbox" name="venueCheck[<?php echo $row_getVenues['venue_id']; ?>]_<?php echo $RepeatSelectionCounter_1?>" id="venueCheck_<?php echo $row_getVenues['venue_id']; ?>_<?php echo $RepeatSelectionCounter_1?>" value="<?php echo $row_getVenues['venue_id']; ?>"/>
              <?php echo $row_getVenues['venue_short']; ?></label>
          </div>
          <?php $setRows++; echo $setRows; if ($setRows == 3) { echo "<br/>"$setRows=0; }?>
          <?php
    
// RepeatSelectionCounter_1 Begin Alternate Content
    
else{
?>
No records match your request.
<?php // RepeatSelectionCounter_1 End Alternate Content
        
if(!$RepeatSelectionCounterBasedLooping_1 && $RepeatSelectionCounter_1_IterationsRemaining != 0){
            if(!
$row_getVenues && $RepeatSelectionCounter_1_Iterations == -1){$RepeatSelectionCounter_1_IterationsRemaining 0;}
            
$row_getVenues mysql_fetch_assoc($getVenues);
        }
        
$RepeatSelectionCounter_1++;
    } 
// RepeatSelectionCounter_1 End Loop
?>
          <?php } while ($row_getVenues mysql_fetch_assoc($getVenues)); ?>



3. added MRT behaviour to page using:

WIZZARD PAGE 1
Trigger - Button:Insert Pressed
DB connection
relational table set to link table
goto set to results page

WIZZARD PAGE 2
Foreign key column - contractID from link table
data type - numeric
key value - set to created insert record id from contract table (WADAnsertRecordID)

WIZZARD PAGE 3
foreign key column - linked table venue id
data type - numeric
options form field - wada repeat id venue id in repeat selection

WIZZARD PAGE 4
no changes made

Something is wrong - maybe with the name or ids given to my looping checkboxes? Any help would be appreciated - and when this is working I will make a step by step guide for this as nobody else has done it yet. :)

Thanks.

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...