This topic is locked
[SOLVED]

 All detail records update after updating only ONE

1/13/2011 10:33:50 PM
PHPRunner General questions
bbarker author

I know that it's probably something simple. I'd appreciate your help.
When I select my DETAILs link, it shows up at the bottom of the LIST page.
Then when I UPDATE any line on the Detail list, it causes ALL of the detail records to change.
Any idea what I'd done wrong. It's a simple Left Join relationship.

bbarker author 1/13/2011

I might be on to a solution. I'm using a database that was converted from MS ACCESS.

It has a VendorID which links to the Master table.

But there is no UNIQUE RECORD field.

Sergey Kornilov admin 1/13/2011

You do need a unique field in order for edit for work properly. In other case all records will be updated.

bbarker author 1/14/2011

Yes that was the problem. If you import tables from a different database, check to see that they have UNIQUE Id's.
Here's what I did:
-----MySQL DATABASE-----

Use phpMyAdmin

rename "table" -> "table0"

export "table0" STRUCTURE to new "table"

Add new ID field with INT10, auto increment to "table"

Import "table0" data into "table"
------PHP Runner---------

Leave JOIN as Key= "VendorID"

Modify Index on PHPR-PAGES to be new "ID"

Be sure to include the new fields in PHPR-FIELDS page.