Creating/Updating a tag from module

Hello,
I'm receiving data that is pushed into a sql database and i'm recovering it using SRConnection. Using the resulting dataset i'm trying to update or create an historical tag. My dataset contains the tagpath,the tag provider,the new value and the timestamp. I tried to use ManagedTagProvider and do a updateValue but the history doesn't appear to be working as i only got access to the latest value. What is the correct solution to make it work?