Gossamer Forum
Home : Products : DBMan : Installation :

Load value-fields from db1

Quote Reply
Load value-fields from db1
I have two DB's running on my server. In the first one, the db-key is userid, so anyone can add only one record in that db.
The thing I want to work out, is, that a registered user, with his name, adress, tel.nr, etc. loaded in DB1, take that value in DB2 (that works, thanks JPD), but when this user adds a record in DB2 (ther he can add more records), the adding screen came, but I set this screen up, that only the important fields must be fill in. So not the user's name, adress, etc. But, in the record_long that whole info must be stored, also his name, adress, etc. When that user adds his record, the add_record_failure screen came, with the message, that some fields cannot be left blanc, these are the name. adress, etc. fields. I feel this can be fixed but I've searched one whole evening, without any result.

Thanks in advance.
Mart.
Quote Reply
Re: Load value-fields from db1 In reply to
I'm not sure I understand your question. (I do realize there's a language problem. I don't speak Dutch! Smile )

In your second database, you have to have fields on the add form to hold the information from the first database. You can make them hidden fields if you'd like, but the fields have to exist or they won't be added to the record.

Does this seem like an answer to your question?


------------------
JPD





Quote Reply
Re: Load value-fields from db1 In reply to
The fields all exist in DB2, but how do I make 'hidden' fields??
Quote Reply
Re: Load value-fields from db1 In reply to
In html_record_form, right after

print qq|

add

<input type="hidden" name="FieldName" value="$rec{'FieldName'}">

Add one of those lines for each field you want to be hidden.

They will not show up on the html page at all and don't have to be within a table.


------------------
JPD





Quote Reply
Re: Load value-fields from db1 In reply to
Thanks, Wink
This seems easy, I'm learning every day...