Thursday, March 8, 2012
Custom Filter for .msg files
field in SQL 2000. I have found where certain types of files have built in
filter support for searching, but .msg is not included as one of these.
Is anyone aware of anyway to do searches on the .msg file type within SQL.
BOL references the ability to create custom filters, but I am unable to find
the reference.
TIA,
J. Clay
did you try the following?
open up hkey_classes_root, locate msg, add a sub key to .msg called
PersistentHandler, add a string value called (Default)
with the value {5645C8C2-E277-11CF-8FDA-00AA0X0A14F93}
this uses mimefilt.dll which should be on most modern os's - win2k and
above.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"J. Clay" <JClay@.NoSpam.nospam> wrote in message
news:ew8U6WNUFHA.628@.TK2MSFTNGP09.phx.gbl...
> I have an app that is automatically storing e-mails from Outlook in an
image
> field in SQL 2000. I have found where certain types of files have built
in
> filter support for searching, but .msg is not included as one of these.
> Is anyone aware of anyway to do searches on the .msg file type within SQL.
> BOL references the ability to create custom filters, but I am unable to
find
> the reference.
> TIA,
> J. Clay
>
>
|||No. (Wouldn't have known how!) I will give it a try though and report
back.
Thank you very much!
Jim
"Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
news:O$osm5NUFHA.3280@.TK2MSFTNGP09.phx.gbl...[vbcol=seagreen]
> did you try the following?
> open up hkey_classes_root, locate msg, add a sub key to .msg called
> PersistentHandler, add a string value called (Default)
> with the value {5645C8C2-E277-11CF-8FDA-00AA0X0A14F93}
> this uses mimefilt.dll which should be on most modern os's - win2k and
> above.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "J. Clay" <JClay@.NoSpam.nospam> wrote in message
> news:ew8U6WNUFHA.628@.TK2MSFTNGP09.phx.gbl...
> image
> in
SQL.
> find
>
>
|||Actually MIME IFilter is capable of extracting text, but it does not deal
with attachments. In order to have full access to the information inside
..msg file I suggest using MSG IFilter, developed by Alna:
http://www.alna.com/vid.php4?mid=93&cat_id=4&prod_id=2.
Best regards,
Michailas
"J. Clay" <JClay@.NoSpam.nospam> wrote in message
news:OTUOX9NUFHA.3596@.TK2MSFTNGP14.phx.gbl...
> No. (Wouldn't have known how!) I will give it a try though and report
> back.
> Thank you very much!
> Jim
> "Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
> news:O$osm5NUFHA.3280@.TK2MSFTNGP09.phx.gbl...
> SQL.
>
>
|||Thanks Michailas - I think that is what I am looking for. I will make some
inquiries.
Regards,
Jim
"MT" <mtraubas@.alna.lt> wrote in message
news:%23E4qd1hUFHA.3716@.TK2MSFTNGP12.phx.gbl...[vbcol=seagreen]
> Actually MIME IFilter is capable of extracting text, but it does not deal
> with attachments. In order to have full access to the information inside
> .msg file I suggest using MSG IFilter, developed by Alna:
> http://www.alna.com/vid.php4?mid=93&cat_id=4&prod_id=2.
> Best regards,
> Michailas
>
> "J. Clay" <JClay@.NoSpam.nospam> wrote in message
> news:OTUOX9NUFHA.3596@.TK2MSFTNGP14.phx.gbl...
an[vbcol=seagreen]
these.[vbcol=seagreen]
to
>
>
Wednesday, March 7, 2012
Custom error msg breaks my error handler
Hi,
I added this line of code to my error handler script, in red.
User:criptError is a package-level string variable
User:criptError has a value assigned to it when another script encounters an error condition (which I define)
I added "User:criptError" as a read-only variable to the error handler script task.
Public Sub Main()
Dim messages As Collections.ArrayList
Try
messages = CType(Dts.Variables("errorMessages").Value, Collections.ArrayList)
Catch ex As Exception
messages = New Collections.ArrayList()
End Try
messages.Add(Dts.Variables("SourceName").Value.ToString)
messages.Add(Dts.Variables("ErrorDescription").Value.ToString())
messages.Add(Dts.Variables("scriptError").Value.ToString)
Dts.Variables("errorMessages").Value = messages
Dts.TaskResult = Dts.Results.Success
End Sub
Now, when I run the package, and an it encounters an error, it task just hangs, that is, it stays yellow instead of turning red... if I remove the line in red above, it works ok again.
Why would this line cause a problem?
Thanks
Make sure you are unlocking the scriptError variable in the first task. It might help if you post the script from that task.|||Hi,
What do you mean by "unlocking the scriptError variable"?
Thanks
|||Dts.Variables.Unlock()|||I will try that. Why is unlocking necessary? I've never run into this before.
Thanks
|||If the first task is raising an error, the error handling task can be fired before the variable is unlocked in the first task. Make sure that you unlock it in the error handler in the first script.|||This is the part of my code that seems to be causing the problem. I am trying to set the "scriptError" variable to the error message below. As you can see, I am setting the Dts.TaskResult to "failure" BEFORE assigning the value to my variable. The "failure" causes execution to go to my Error Handler script task. That's where it hangs.
Perhaps I should put the the "failure" AFTER the variable assignment.
I don't understand all this "unlocking" stuff quite yet. What do you mean by "unlock it in the error handler"? Perhaps that doesn't apply here, I don't know.
Thanks
Else
Dts.TaskResult = Dts.Results.Failure
Dts.Variables("scriptError").Value = "The extracts in " & CStr(Dts.Variables("Folder").Value) & " are not current! Data NOT loaded."
End If
|||AddingDts.Variables.Unlock()
right after the variable is written to (but not before) works!
Custom error msg breaks my error handler
Hi,
I added this line of code to my error handler script, in red.
User:criptError is a package-level string variable
User:criptError has a value assigned to it when another script encounters an error condition (which I define)
I added "User:criptError" as a read-only variable to the error handler script task.
Public Sub Main()
Dim messages As Collections.ArrayList
Try
messages = CType(Dts.Variables("errorMessages").Value, Collections.ArrayList)
Catch ex As Exception
messages = New Collections.ArrayList()
End Try
messages.Add(Dts.Variables("SourceName").Value.ToString)
messages.Add(Dts.Variables("ErrorDescription").Value.ToString())
messages.Add(Dts.Variables("scriptError").Value.ToString)
Dts.Variables("errorMessages").Value = messages
Dts.TaskResult = Dts.Results.Success
End Sub
Now, when I run the package, and an it encounters an error, it task just hangs, that is, it stays yellow instead of turning red... if I remove the line in red above, it works ok again.
Why would this line cause a problem?
Thanks
Make sure you are unlocking the scriptError variable in the first task. It might help if you post the script from that task.|||Hi,
What do you mean by "unlocking the scriptError variable"?
Thanks
|||Dts.Variables.Unlock()|||I will try that. Why is unlocking necessary? I've never run into this before.
Thanks
|||If the first task is raising an error, the error handling task can be fired before the variable is unlocked in the first task. Make sure that you unlock it in the error handler in the first script.|||This is the part of my code that seems to be causing the problem. I am trying to set the "scriptError" variable to the error message below. As you can see, I am setting the Dts.TaskResult to "failure" BEFORE assigning the value to my variable. The "failure" causes execution to go to my Error Handler script task. That's where it hangs.
Perhaps I should put the the "failure" AFTER the variable assignment.
I don't understand all this "unlocking" stuff quite yet. What do you mean by "unlock it in the error handler"? Perhaps that doesn't apply here, I don't know.
Thanks
Else
Dts.TaskResult = Dts.Results.Failure
Dts.Variables("scriptError").Value = "The extracts in " & CStr(Dts.Variables("Folder").Value) & " are not current! Data NOT loaded."
End If
|||AddingDts.Variables.Unlock()
right after the variable is written to (but not before) works!
Custom error msg breaks my error handler
Hi,
I added this line of code to my error handler script, in red.
User:criptError is a package-level string variable
User:criptError has a value assigned to it when another script encounters an error condition (which I define)
I added "User:criptError" as a read-only variable to the error handler script task.
Public Sub Main()
Dim messages As Collections.ArrayList
Try
messages = CType(Dts.Variables("errorMessages").Value, Collections.ArrayList)
Catch ex As Exception
messages = New Collections.ArrayList()
End Try
messages.Add(Dts.Variables("SourceName").Value.ToString)
messages.Add(Dts.Variables("ErrorDescription").Value.ToString())
messages.Add(Dts.Variables("scriptError").Value.ToString)
Dts.Variables("errorMessages").Value = messages
Dts.TaskResult = Dts.Results.Success
End Sub
Now, when I run the package, and an it encounters an error, it task just hangs, that is, it stays yellow instead of turning red... if I remove the line in red above, it works ok again.
Why would this line cause a problem?
Thanks
Make sure you are unlocking the scriptError variable in the first task. It might help if you post the script from that task.|||Hi,
What do you mean by "unlocking the scriptError variable"?
Thanks
|||Dts.Variables.Unlock()|||I will try that. Why is unlocking necessary? I've never run into this before.
Thanks
|||If the first task is raising an error, the error handling task can be fired before the variable is unlocked in the first task. Make sure that you unlock it in the error handler in the first script.|||This is the part of my code that seems to be causing the problem. I am trying to set the "scriptError" variable to the error message below. As you can see, I am setting the Dts.TaskResult to "failure" BEFORE assigning the value to my variable. The "failure" causes execution to go to my Error Handler script task. That's where it hangs.
Perhaps I should put the the "failure" AFTER the variable assignment.
I don't understand all this "unlocking" stuff quite yet. What do you mean by "unlock it in the error handler"? Perhaps that doesn't apply here, I don't know.
Thanks
Else
Dts.TaskResult = Dts.Results.Failure
Dts.Variables("scriptError").Value = "The extracts in " & CStr(Dts.Variables("Folder").Value) & " are not current! Data NOT loaded."
End If
|||AddingDts.Variables.Unlock()
right after the variable is written to (but not before) works!