2006 Jan 23 6:20 PM
Is it advicable to make all the fields in a table as key? The case is to maintain a control table where 2 fields are required and it should be unique also. is there any thing wrong in doing it?
2006 Jan 23 7:04 PM
You can, but why? IF you know all of the key fields, there's nothing that the database can tell you when you select it.
Rob
Is it advicable to make all the fields in a table as key? The case is to maintain a control table where 2 fields are required and it should be unique also. is there any thing wrong in doing it?
2006 Jan 23 6:31 PM
Well in your scenario, where you have only two fields in tables, and they need to be unique..Yes u can make it. As I also develop a screen in which we have to store two dates as a key in table...
Hope thisll help you .
Bye
2006 Jan 23 6:37 PM
Thanks Javed,
I was checking whether its a good practice to do making all the fields in table as key.
2006 Jan 23 6:38 PM
2006 Jan 23 7:04 PM
You can, but why? IF you know all of the key fields, there's nothing that the database can tell you when you select it.
Rob
2006 Jan 23 7:15 PM
hi Rob,
I wanted to record whether a particular transaction has occured or not. If ocuured on the same date it should not be allowed once again. So the transaction and date are my only fields and only keys. Is there any SAP tables with all the fields as key.
2006 Jan 23 7:25 PM
I figured that out right after I made the post. I don't know of any tables like that, but it shouldn't be a problem. You might want to add the client as the first key field.
Rob
2006 Jan 23 8:04 PM
There are lots of SAP tables like this - TB040 for instance.
Rob
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |