Record User ID SQl 2008
Posted on 2013-01-03
I'm new to SQL, but I'm trying to transition an access database that used linked tables in SharePoint to an Access front end that uses linked tables in SQL2008 server.
I've used the Access Upscale facility to move the linked tables to a SQL database ... which all worked ok.
I had a problem that the fields that sharepoint used to populate automatically i.e Date modified / created didn't automatically populate. I've solved this now by using triggers to inset the date depending on if the record is updated / inserted.
The problem I have now is how I go about capturing the USER ID and inserting that into Created By / Modified by... Sharepoint was linked to the AD Address book so was able to resolve the users actual name.
Is it possible to capture this data using a trigger also? - I could pass it as part of the sql statement but would ratehr have the server handle this part to remove the possibility of manipulation.