Link to home
Start Free TrialLog in
Avatar of varvoura
varvoura

asked on

Strange question

Hi all,

I have the following scenario and I am not so sure if/how it can be achievable

I have a product test form which has many field. Among those field, is a certificate field, which holds a certificate when the product test is completed. However, as the product test is a constant process set by intervals, I will need the certificate field to be updated with the new certificate number without overwriting the previous one. In saying that though, I won't be able to have them in the same field as it will become too large as many will be carried out on the one product, so what I'd require some sort of linkage to all previous certificate id's for a specific product.

Any ideas will be appreciated.
SOLUTION
Avatar of madheeswar
madheeswar
Flag of Singapore image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Sjef Bosman
I would say that the certificate isn't a separate document, but is is the positive result of a product test. In that case, the reward is a certificate number. I assume product test documents cannot be modified?
Avatar of marilyng
marilyng

sjef.. Ok, I read that three times, I have no idea what you just said? :)  Care to restate and clarify?

Varvoura, do they need to see the old certificate numbers? - why not turn on versioning so new documents become new versions? And you can add a bit of code to remove the previous certificate number from the field on new documents.

You can turn on versioning in the Form Properties.  Easy, no muss, no fuss.
I didn't know I had it in me... ;) It's just complete and utter nonsense, please ignore.

What I meant to say was (also after having re-read the question), that the product test is finished when a certificate has been awarded on a certain date. Which means, IMHO, that the Product Test document should be blocked for updates and a new Product test document should be created for the same product, to be updated constantly while testing and to be blocked in its turn when a new certificate has been granted. After a while, there will be many Product test documents, each with a certificate number and a date, except for the last one that's still Open. A categorized view of these Product test documents, with a second column containing the certification date or the creation date (sorted descending) wll provide the information required.
So,... versioning... right?  Ha!  Said it first! Nah, Nah!
Experts,
Don't you think Response and Embedded view will do the trick?
Even if it is not a Response document, he can make use of @Unique and create documents and use Embedded view.

What say?
Why do response with code and logic when you can do versioning with no code and no logic?  
No, not versioning (as Notes does it)! Each update results in a new version, whether it be for a simple update or a truely new certificate.
Avatar of varvoura

ASKER

OK, the form that has the certificateID field is a response to response document, so it may just be a good idea just to create a button next to certificateID field on that response to response form, which will have an embedded view that has only certificateID as first column sorted descending, test as 2nd column to relate the certificateID to a specific test, then when if the user wishes to view the list of certificate for all the tests for a specific product, they can click the button which will then launch the embeded single category view?

Does this sound feasible?

form versioning won't help me here, sorry guys, I would love it if it worked, life would me so much easier

Eeeeehh... I don't understand.

What's the structure of your database? Something like:

Product   1---->n   ???  1---->n   Product Test

Please can you make some sort of drawing or so? I assume it would be possible to have multiple Product Test documents for a product? An embedded view seems a possibility, but why the button? You can also do a @DbLookup in a text-field.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
The structure of the database is a document/response/response to response database, where:

1. Customer is the main form
2. Product is the response form
3. Test is the response to response form.

Customer has customer name, code which can be inherited by the response document

Response to response also inherits the customer name and customer code from the response doc which are inherited from main.

and obviously many other individual non-inherited fields on each form.

We will create a customer document in the database. Each customer can have many products, hence we can create many response product documents for one customer and each product has to undergo many test per year, based on test intervals, hence the test form which is a response to response document.

I hope this is clearer.
Now if Marylin's versionning works with this scenario, I'll be very happy to use it as there is enough coding in this db without this extra bit. One thing to keep in mind is someone created a test document and decided to save it then to go back and update it later, will still versionning still works without any problems?

Also, I can't seem to be able to display the response to response document in the view, not matter what I do, I see the hierarchy of document-response and when I include a field from the response to respone document in that view, it doesn't display it. Very odd, I probably designed over 10 discussion dbs which work fine. Any ideas what could stop this from working?
I am going to look into it now and will probably figure out the problem.

Response to responses are displaying in view, so that's one thing out of the way
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
OK, it is a physical product(electrical) where a customer purchases, then as a maintenance measure, one of our technician visits in quarterly interval to test that product to make sure it doesn't fail, that's all. As I said this test happens for the life of the product, until it is decommissioned, hence the many response to response test documents for test. One product can undergo 1000 test, another may go through 5 tests before it dies and is replaced.

Is this a bit better?
:)

Back to you question: you say that you "need the certificate field to be updated with the new certificate number without overwriting the previous one". I supposed that, each time the technician visits the product, he creates an entirely new test document. I also assumed that, when he's ready and the equipment was tested successfully, a new certificate number is the result of the test, that it is placed in the test document and that the test document is frozen forever.

Did I go wrong somewhere??
Nope, but I do have another question about this which I am going to think about carefully first so I don't confuse you and then I'll ask it.

Can I do a lookup on certificate number per test?

For example, when I create a test, I will need to always assign the test that I close a new certificate number which will be the next number from the previous test.
I was thinking view lookup by key, but then would that work?
Remember that they'll always be many other tests in that view, so it will probably have to be by key(reference no of test) but then how will I go about grabing the last number for that specific test in that view, if they is 50 tests for 20 products.

Will embeded view by single category work here, where the view is categorized by reference number of a specific test.

Sorry sjef, but I am really confused here and I think that I've confused you too or did you understand what I am trying to get at?
This seems a different issue (for which you might start a different question). Standard approach: create a new (hidden) view, sorted by product (ascending) and date certified (descending), then do a GetDocumentByKey with the product name and you'll get the latest certified test for a product. Get its certificate number, and create a new one for the current test certificate number.

You don't need an embedded view for this, I think.
Marilyn,

a few hours ago, I've asked customer service to actually help me increase the points on this question so I can give a fair split because there was so much work done on it and the points assigned were not sufficient. You can check with them for yourself, I'd say this was around 4 hours ago or so.
Something went wrong and I couldn't increase the points.
Anyway, as soon I hear back from them, I'll assign and close this question.

Thanks Marilyn