Click here to Skip to main content
16,011,120 members
Home / Discussions / Database
   

Database

 
GeneralRe: SQLServer problem: fetching TEXT field using OLE DB Pin
James R. Twine13-Sep-02 5:39
James R. Twine13-Sep-02 5:39 
GeneralRe: SQLServer problem: fetching TEXT field using OLE DB Pin
taualex13-Sep-02 8:04
taualex13-Sep-02 8:04 
GeneralRe: SQLServer problem: fetching TEXT field using OLE DB Pin
James R. Twine13-Sep-02 9:02
James R. Twine13-Sep-02 9:02 
QuestionTRICKY - How to SELECT TOP X records when using UNION? Pin
Garth11-Sep-02 17:31
Garth11-Sep-02 17:31 
AnswerRe: TRICKY - How to SELECT TOP X records when using UNION? Pin
Rein Hillmann11-Sep-02 19:11
Rein Hillmann11-Sep-02 19:11 
AnswerRe: TRICKY - How to SELECT TOP X records when using UNION? Pin
Richard Deeming13-Sep-02 6:01
mveRichard Deeming13-Sep-02 6:01 
GeneralSQLDMO & DTS Pin
Paul Watson10-Sep-02 7:08
sitebuilderPaul Watson10-Sep-02 7:08 
GeneralRe: SQLDMO & DTS Pin
Nick Parker11-Sep-02 13:12
protectorNick Parker11-Sep-02 13:12 
Paul Watson wrote:
Anybody got a clue as to how to run a DTS package using SQLDMO?

Not sure if this can be considered a clue or if I am just the first lucky soul to *try* and answer your question; you choose. Wink | ;)

'**********************************************************************
'  Visual Basic ActiveX Script
'**********************************************************************

Function Main()
	Call Paul_Watson_Fun()
	Main = DTSTaskExecResult_Success
End Function


Function Paul_Watson_Fun()
Dim oServer 		'DMO Server object.
Dim oResult		'Result set.
Dim sParamValue

	'Create a SQLDMO server object.
	Set oServer =  CreateObject("SQLDMO.SQLServer")

	' Make a connection to the local server.
	oServer.Connect ".", "sa"

	'Select the desired row from the table.
	set oResult = oServer.Databases("pubs").ExecuteWithResults_
("select  paramvalue from  my_param_table")

	'Retrieve the first row, first column from the results.
	sParamValue = oResult.GetColumnString (1,1)

	'Set the global variable.
	DTSGlobalVariables("MyGlobalVar").Value = sParamValue

	Main = DTSTaskExecResult_Success
End Function


HTH

Nick Parker


Questionsp_OASetProperty limitations? Pin
Jeremy Falcon6-Sep-02 7:50
professionalJeremy Falcon6-Sep-02 7:50 
AnswerRe: sp_OASetProperty limitations? Pin
Jeremy Falcon6-Sep-02 9:33
professionalJeremy Falcon6-Sep-02 9:33 
AnswerRe: sp_OASetProperty limitations? Pin
Nick Parker11-Sep-02 8:40
protectorNick Parker11-Sep-02 8:40 
GeneralRe: sp_OASetProperty limitations? Pin
Jeremy Falcon12-Sep-02 5:56
professionalJeremy Falcon12-Sep-02 5:56 
GeneralInserting values into sql table with C# help Pin
halbichmi6-Sep-02 6:13
halbichmi6-Sep-02 6:13 
GeneralImport diagram to SQL-server 2000 Pin
Rulle6-Sep-02 1:47
Rulle6-Sep-02 1:47 
GeneralRe: Import diagram to SQL-server 2000 Pin
notadood6-Sep-02 2:56
notadood6-Sep-02 2:56 
GeneralRe: Import diagram to SQL-server 2000 Pin
Rulle6-Sep-02 6:57
Rulle6-Sep-02 6:57 
GeneralAutomation Error Pin
bugbuster5-Sep-02 11:35
bugbuster5-Sep-02 11:35 
GeneralRe: Automation Error Pin
notadood6-Sep-02 2:53
notadood6-Sep-02 2:53 
GeneralIdentity Seed/Increment Customize Pin
Robby5-Sep-02 5:25
Robby5-Sep-02 5:25 
GeneralRe: Identity Seed/Increment Customize Pin
Jon Hulatt6-Sep-02 3:55
Jon Hulatt6-Sep-02 3:55 
GeneralLEFT OUTER JOIN leaves rows Pin
Knappen4-Sep-02 10:18
Knappen4-Sep-02 10:18 
Generala sql query question Pin
freeworldbird4-Sep-02 7:54
freeworldbird4-Sep-02 7:54 
GeneralRe: a sql query question Pin
Mazdak4-Sep-02 7:59
Mazdak4-Sep-02 7:59 
GeneralRe: a sql query question Pin
freeworldbird4-Sep-02 8:07
freeworldbird4-Sep-02 8:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.