Vista ADODB Recordset Can't Create ActiveX Object

Jul 19, 2007

Somehow, (I think the user ran a registry cleaner) on Vista, I can no longer create an adodb recordset object.



The app is a VB6 app that works fine on my own Vista Ultimate, my XP boxes and about everthing else prior, but not on the one Vista Home Premium.



I get Error 429 ... Cannot Create ActiveX Object when creating a new adodb.recordset object.



I guess what I need is a way to repair the Vista Home-P machine without having to wipe it.



I see that MDAC_Typ is not recommended as a fix.



I'm at a loss on this one.



View 3 Replies


ADVERTISEMENT

Script Component Has Encountered An Exception In User Code - Object Is Not An ADODB.RecordSet Or An ADODB.Record

Nov 26, 2007

hi have written SSIS script and i am using script component to Row count below my code what i have written. and i am getting error below i have mention...after code see the error
using System;

using System.Data;

using Microsoft.SqlServer.Dts.Pipeline.Wrapper;

using Microsoft.SqlServer.Dts.Runtime.Wrapper;

using System.Data.SqlClient;

using System.Data.OleDb;



[Microsoft.SqlServer.Dts.Pipeline.SSISScriptComponentEntryPointAttribute]

public class ScriptMain : UserComponent

{

IDTSConnectionManager100 connMgr;

OleDbConnection sqlConn = null;

OleDbDataReader sqlReader;



public override void AcquireConnections(object Transaction)

{

connMgr = this.Connections.MyConnection;

sqlConn = (OleDbConnection )connMgr.AcquireConnection(null);

//sqlConn = (SqlConnection)connMgr.AcquireConnection(null);

}

public override void PreExecute()

{

base.PreExecute();

/*

Add your code here for preprocessing or remove if not needed

*/

OleDbCommand cmd = new OleDbCommand("SELECT CustomerID,TerritoryID,AccountNumber,CustomerType FROM Sales.Customer", sqlConn);



sqlReader = cmd.ExecuteReader();

}

public override void PostExecute()

{

base.PostExecute();

/*

Add your code here for postprocessing or remove if not needed

You can set read/write variables here, for example:

Variables.MyIntVar = 100

*/

}

public override void CreateNewOutputRows()

{

/*

Add rows by calling the AddRow method on the member variable named "<Output Name>Buffer".

For example, call MyOutputBuffer.AddRow() if your output was named "MyOutput".

*/

System.Data.OleDb.OleDbDataAdapter oLead = new System.Data.OleDb.OleDbDataAdapter();

//SqlDataAdapter oLead = new SqlDataAdapter();

DataSet ds = new DataSet();



System.Data.DataTable dt = new System.Data.DataTable();

//DataRow row = new DataRow();

oLead.Fill(dt,this.Variables.ObjVariable);





foreach (DataRow row in dt.Rows)

{

{

Output0Buffer.AddRow();

Output0Buffer.CustomerID = (int)row["CustomerID"];

Output0Buffer.TerritoryID =(int)row["TerritoryID"];

Output0Buffer.AccountNumber = row["AccountNumber"].ToString();

Output0Buffer.CustomerType = row["CustomerType"].ToString();

}

}



}

}
the error
Script component has encountered an exception in user code
Object is not an ADODB.RecordSet or an ADODB.Record.
Parameter name: adodb
at System.Data.OleDb.OleDbDataAdapter.FillFromADODB(Object data, Object adodb, String
srcTable, Boolean multipleResults)
at System.Data.OleDb.OleDbDataAdapter.Fill(DataTable dataTable, Object ADODBRecordSet)
at ScriptMain.CreateNewOutputRows()
at UserComponent.PrimeOutput(Int32 Outputs, Int32[] OutputIDs, PipelineBuffer[] Buffers)
at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.PrimeOutput(Int32 outputs,
Int32[] outputIDs, PipelineBuffer[] buffers)

thanks
kedarnath

View 4 Replies View Related

DTS & ActiveX Can&#39;t Create Object Problem W/ SQL7

Jan 17, 2002

I've created a DTS package which exec's perfectly throught the DTS interface, but when I try to run the same package in a Job using DTSRun, I'm getting the following error...
####
DTSRun: Loading... DTSRun: Executing...
DTSRun OnStart: DTSStep_DTSActiveScriptTask_1
DTSRun OnError: DTSStep_DTSActiveScriptTask_1, Error = -2147220482 (800403FE)
Error string: Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: ActiveX component can't create object: 'CreateObject'
Error on Line 15
Error source: Microsoft Data Transformation Services (DTS) Package
Help file: sqldts.hlp
Help context: 1100

Error Detail Records:
Error: -2147220482 (800403FE); Provider Error: 0 (0)
Error string: Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: ActiveX component can't create object: 'CreateObject'
Error on Line 15
Error source: Microsoft Data Transformation Services (DTS) Package
Help file: sqldts.hlp
Help context: 1100
DTSRun OnFinish: DTSStep_DTSActiveScriptTask_1
DTSRun: Package execution complete.

####

The 1st part of the actual ActiveX script within the DTS package is...

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

Function Main()

' check to see if the capscan file exists. check for the first
' else do not proceed

'Function Main()

dim oFSO
dim x

' instantiate the Scripting Object
set oFSO = CreateObject("Scripting.FileSystemObject")

' Open the file
set x = oFSO.OpenTextFile("C:directoryfile0.txt")

x.close

Main = DTSTaskExecResult_Success

End Function

######

note: the exact same configuration works perfectly on the test server.
Both servers have same version of NT4, SQL7, VBscript, MDAC.

Anyone with any ideas???

View 1 Replies View Related

ActiveX Component Can&#39;t Create Object : CreateObject

Oct 14, 1999

HI

If I create an Active Script like this :
function Main()
Dim fso
Dim a
Set fso = CreateObject("Scripting.FileSystemObject")
Set a = fso.CreateTextFile("c:est.txt")
a.WriteLine("This is a test")
a.Close
end Function

I got an error
ErrorCOde: 0
ErrorSource : VBScriptENgineError
Error Description : ActiveX Component can't create object : CreateObject

The error is at line Set fso=CreateObject....

Any idea ?
THanks

View 1 Replies View Related

ADODB And ActiveX

Jan 19, 2000

Hi,

Am having trouble writing to a table on the SQL 7 Server database, using a DTS ActiveX script.

When I try a .ADDNEW function, the following error comes up.
"The opperation required by the application is not supported by the provider."

The line preceding the .ADDNEW are as follows.
-----
SET Conn=CreateObject("ADODB.Connection")
SET RS = CreateObject("ADODB.RecordSet")
Conn.ConnectionString = "PROVIDER=SQLOLEDB;DATABASE=DataIn;User ID=sa;Password="
Conn.Open
RS.Open sqlSites, Conn
----

Q - Whats wrong ?

View 1 Replies View Related

Unable To Cast COM Object Of Type 'ADODB.CommandClass' To Interface Type 'ADODB._Command'

Dec 20, 2006

I have an application which runs successfully on a couple of my customer's machines but fails on a third. It seems to fail when opening the database:

Unable to cast COM object of type 'ADODB.CommandClass' to interface type 'ADODB._Command'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{B08400BD-F9D1-4D02-B856-71D5DBA123E9}' failed due to the following error: No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)).
Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=false; Initial Catalog=lensdb;Data Source = SQL

Before I got this error I was getting another problem (sorry didn't make a copy of that error's text) that made me think that adodb.dll simply wasn't loaded/registered. I got rid of that error by copying my adodb.dll onto the third machine and running gacutil /i. There is now an entry in winntassemblies for adodb.

Just in case you think it could be an obvious registry problem: when I started getting the current error I thought that maybe the registry needed updating and I merged the following lines into onto the target machine (from my dev machine):

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOTInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}]
@="_Command"

[HKEY_CLASSES_ROOTInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}ProxyStubClsid]
@="{00020424-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOTInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}ProxyStubClsid32]
@="{00020424-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOTInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}TypeLib]
@="{EF53050B-882E-4776-B643-EDA472E8E3F2}"
"Version"="2.7"

[HKEY_LOCAL_MACHINESOFTWAREClassesInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}]
@="_Command"

[HKEY_LOCAL_MACHINESOFTWAREClassesInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}ProxyStubClsid]
@="{00020424-0000-0000-C000-000000000046}"

[HKEY_LOCAL_MACHINESOFTWAREClassesInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}ProxyStubClsid32]
@="{00020424-0000-0000-C000-000000000046}"

[HKEY_LOCAL_MACHINESOFTWAREClassesInterface{B08400BD-F9D1-4D02-B856-71D5DBA123E9}TypeLib]
@="{EF53050B-882E-4776-B643-EDA472E8E3F2}"
"Version"="2.7"


but, no change alas.

All three machines are running Windows 2000.

Any advice would be appreciated.

Thanks in advance,

Ross

View 1 Replies View Related

Adodb Recordset Problem

Mar 31, 2006

I am trying to access a table that I know exists and has data. But, when I create a recordset and check for RecordCount, I get a result -1 (no records). When I access the same table (using the same program), it reports (and I can view in a dbgrid) 752580 records exist.

Here's some of the code:

The table is originally copied from another database; I use the following code to be sure the previous connection is closed before proceeding.

  If Not adoRS Is Nothing Then
    If adoRS.State = adStateOpen Then adoRS.Close
    Set adoRS = Nothing
  End If
  If Not DbConn Is Nothing Then
    If DbConn.State = adStateOpen Then DbConn.Close
    Set DbConn = Nothing
  End If

Then a new connection (it works) is opened to access the database with the  copied table:

   strDbConn = "Provider=SQLNCLI;Integrated Security=SSPI;" & _
  "Persist Security Info=False;Database=" & strDbName & ";" & _
  "AttachDBFileName=" & DbPath & ";Data Source=.sqlexpress;" & _
  "User Instance=True"

Next I tried to create the recordset:

  Set adoNewRS = New ADODB.Recordset 'Set OHLC recordset
  Set adoNewRS.ActiveConnection = DestDbConn
  adoNewRS.Open TableName, DestDbConn, adOpenDynamic, adLockOptimistic

Next I try to get the RecordCount:

  NumRecords = adoNewRS.RecordCount

At this point, NumRecords (and adoNewRS.RecordCount) = -1 (even tho I know there are 752580 records in the table).

In the adoNewRS.Open statement, I also tried using the following sql statement:

sSQL = "SELECT * FROM TableName ORDER BY [DateTime];"

It also returns a recordcount = -1.

Anybody have clue?

View 1 Replies View Related

Receive Adodb.Recordset From MSMQ?

Feb 6, 2008

I've been trying different things to "READ" the recordset from the "Message Queue". I can read it but with some weird characters. I've tried

ActiveXMessageFormatter

BinaryMessageFormatter

XMLMessageFormatter


So, far I have no luck.

MessageQueue msgQ3 = new MessageQueue("SERVERNM\" + msg.Label, false);

Message msg3 = new Message();

msg3.Formatter = new ActiveXMessageFormatter();
msg3 = msgQ3.Receive(new TimeSpan(0, 0, 30));

byte[] b = new byte[msg3.BodyStream.Length];
msg3.BodyStream.Read(b, 0, (int)msg3.BodyStream.Length); System.Text.ASCIIEncoding enc = new System.Text.ASCIIEncoding();

returnVal = enc.GetString(b);



RESULTS:
I try to convert it to String and then deserialize later but I'm getting some junk.
<?xml version="1.0" encoding="utf-8" ?>

<string xmlns="http://tempuri.org/">5??m.????????#?_?XTG!???????#?_?Xg??c??????? ?<???m????_?X  |?"???????Dw=?????"I?<???m????_?X21? Reply_Code?$??5? MultiEntries?$??7?dName?.$??3? Page_Number?$??1? Number?$??3? Status_Code?$??/?_Name?.$??5? _Address?+$??/? B_City?$$??1? _State?$??-? _Zip?$??A? Bank_Telephone_Num?"$?? ??11  033000333YHONDA2nd street xavier VA 326200000(555) 555-5500</string>

View 1 Replies View Related

Read Table Description Into ADODB.Recordset.

Aug 20, 2003

How do I read the Tables description into ADODB.Recordset and then recreate the Tables+description into a new database from the ADODB.Recordset.

View 1 Replies View Related

Could I Use SQL Select Case .. When... In ADODB.Recordset().open

Jul 20, 2005

Is there any SQL Error?Or I have to use Select case in VB code to control SQL instead.Thank you for any ans.Nuno

View 4 Replies View Related

Script Task: ADODB Connection And Recordset

Jul 19, 2006

Hi,

I used adodb connection and recordset in script task. but i have an error saying adodb is not defined. how do i add it to reference? or, is adodb can run in script task or only ado.net?

cherrie

View 2 Replies View Related

Temporary Tables Adodb Recordset Error

Feb 23, 2008

Hi,

I am using the following code


I use SQLOLEDB Provider
It is not stored porcedure but program code

create new global temporary table with
CREATE TABLE ##tmp123 (...
create and open a recorsset to populate it as direct table
at the open stage I get the following error: Invalid object name '##tmp123'

How can I get it working?

View 2 Replies View Related

ADO Recordset's Object Method Open

Jul 20, 2005

Hello group!I use MS Visual C++ 6.0, ADO, MS SQL Server 2000.When I attempt to open my database I meet with a following problem:when I try to get a bookmark of the current record in a Recordsetobject a following run-time error occurs: Unhandled exception intestdb.exe(KERNEL32.DLL):0xE06D7363: Microsoft C++ Exception.I created my database by 3 SQL commands:create database testdbcreate table testtable(i int)insert into testtable values(0)The error occurs in the following code snippet:#import "D:Program FilesCommon FilesSystemADOmsado15.dll" no_namespace rename("EOF", "EndOfFile")int main(){CoInitialize(NULL);bstr_t strCnn("Provider=sqloledb;Data Source=;""Initial Catalog=testdb;Trusted_Connection=YES;");const char* tablename = "testtable";_RecordsetPtr recs;recs.CreateInstance(__uuidof(Recordset) );recs -> Open(tablename, strCnn, adOpenStatic,adLockOptimistic,adCmdTable);_variant_t bm = recs -> Bookmark; // the error occurs hererecs -> Close();CoUninitialize();}During the debugging this code I met that the error depended on a typeof locking. When I set adLockBatchOptimistic or adLockOptimisticor adLockPessimistic the error occurs but when I set adLockReadOnly oradLockUnspecified it doesn't occur. By the way this error doesn'toccur whenI open Pubs database with any type of locking. What is a cause of thiserror?Thank you.

View 1 Replies View Related

Reaading And Processing A Recordset From Com Object

Aug 31, 2007

Hi everybody.
I need help with the next topic.
From a stored procedure in sqlserver, I need to call a com+ dll, this dll connect ot another database diferent to sqlserver y return this dll must return to stored procedure a recordser for ther processing.

I tried with sp_OACreate, sp_OAMethod, sp_OAGetProperty but I did not know how to process a recordset

Thanks
Erik

View 1 Replies View Related

Shredding Recordset Object Var In ForEach Loop (problem)

Feb 14, 2006

I have a package that starts by loading a recordset into an object variable. The recordset is then enumerated with a ForEach loop. The loop sets some string variables. Within the loop container I have a Script task that uses a MsgBox to show the results for testing purposes. The package uses checkpoint restart (if that matters?).

The first time I run the package the 1st record is displayed in the MsgBox, then the 2nd, but then the loop is stuck on the 2nd record forever. I break the run, and when I rerun it the 1st record is displayed followed by each subsequent record correctly and the package completes successfully. Now, if I were to run again the same problem would occur on rec 2 and I would have to break the run, and then the next run everything would work fine.

Why does the script get caught in an infinite loop the first time it's run, but works fine when restarting from the checkpoint?

Here's my relevant code:





ForEach: Enumerator=ADO Enumerator, Enumeration Mode=Rows in first table




Public Sub Main()
Dts.Variables("User::SQL1").Value = "SELECT src.* FROM " & Trim(Dts.Variables("User::Src1Tbl").Value.ToString)
MsgBox("sql=" & Dts.Variables("User::SQL1").Value.ToString)
Dts.TaskResult = Dts.Results.Success
End Sub

View 8 Replies View Related

Multiple Reads Of User Variable (Recordset Object) Failing

Mar 1, 2007

I hope this is a simple question. I have a package-scope user variable which is populated using a Recordset Destination in a Data Flow task. I am attempting to read the variable multiple times from different Script Tasks. The first read works fine, however the second read, in the second Script Task, says that there are no rows.

Has anyone run across this before? Any thoughts would be appreciated.

Thanks





View 1 Replies View Related

VS 2005 Error 'Object Reference Not Set To An Instance Of An Object' With Integration Services Project Create Failure

May 22, 2008



Just installed VS 2005 & SQLServer 2005 clients on my workstation. When trying to create a new Integration Services Project and start work in the designer receive the MICROSOFT VISUAL STUDIO 'Object reference not set to an instance of an object.' dialog box with message "Creating project 'Integration Services project1'...project creation failed."

Previously I had SQLServer 2000 client with the little VS tool that came with it installed. Uninstalled these prior to installing the 2005 tools (VS and SQLServer).

I'm not finding any information on corrective action for this error.

Any one have this problem and found the solution?

Thanks,
CLC

View 1 Replies View Related

ActiveX Script In A SSIS Package - Calling An FSO To Create/manipulate Files

Jul 3, 2007

I have a SQL2000 DTS package that executes vbscript to loop through a recordset which:

- runs a stored procedure and populated tables

- builds a recordset from the populated tables to write records to an Excel file

- writes status to text files with either the error or success notices



I use FSO to set up the success and error files, but the scheduled job in SQL2005 which calls the SSIS package returns the following error:

"Retrieving the file name for a component failed with error code 0x0015F74C"



I can successullly run this (vbscript) in both the SSIS package via the BI Development Studio and in MS Access (exactly the same code in both) - but not as a SSIS package called in a scheduled job in SQL2005.



I am at an impasse with this ... any and ALL assistance would be GREATLY appreciated.



TIA,



Bob

View 1 Replies View Related

How To Create A Recordset That Joins 3 Temp Tables

Sep 26, 2006

I have an stp where I want to return a Recordset via a SELECT that joins 3 temp tables...

Here's what the temp tables look like (I am being brief)...

CREATE TABLE #Employees (EmpID INTEGER, EmpName NVARCHAR(40))

CREATE TABLE #PayPeriods (PayPeriodIndex INTEGER, StartDate DATETIME, EndDate DATETIME)

CREATE TABLE #Statistics (EmpID INTEGER, PayPeriodIndex INTEGER, HoursWorked REAL)

The #Employees table is populated for all employees.

The #PayPeriods table is populated for each calandar week of the year (PayPeriodIndex=0 to 51).

The #Statistics table is populated from data within another permanent table.

Some employees do not work all 52 weeks.

Some employees do not work any of the 52 weeks.

So, the #Statistics table doesn't have all possible combinations of Employees and PayPeriods.

I want to return a Recordset for all possible combinations of Employees and PayPeriods...

Here's a SELECT that I have used...

SELECT e.EmpId, e.Name, pp.PayPeriodIndex, ISNULL(s.HoursWorked,0)

FROM #Statistics s

LEFT OUTER JOIN #Employees e....

LEFT OUTER JOIN #PayPeriods pp ....

WHERE s.EmpId = e.EmpId

AND s.PayPeriodIndex = pp.PayPeriodIndex

I have had no luck with this SELECT.

Can anybody help???

TIA

View 4 Replies View Related

Create A Column In RecordSet With The Record Count...

Jan 15, 2007

Hello

I'm reading a XML file and the next operation need a column with the row count.

I don't want to know how many rows there is in the recordset, but, the row count of each record.

How can I implement this?

tkx in advance
Paulo Aboim Pinto
Odivelas - Portugal

View 1 Replies View Related

SQL Server 2005 Express - Vista - Invalid Object Name '#spdbdesc'

Apr 2, 2007

I'm running Vista Business edition on 2005 Virtual PC.Installed SQL Server 2005 Express latest download, with instance ofMSSQLSERVER and service accounts running under "NT AUTHORITYSYSTEM".Mixed mode authentication specified and sa password specified.Used server manager to create user login with sysadmin role.Login using windows authentication.Run my application and database is created and populated with defaultrecords.However, my application executes the stored procedure "sp_helpdb"which fails with "Invalid object name '#spdbdesc'" error.If I run a query in server manager to execute same procedure loggedinas the same person it runs ok and returns a table of information.All this was working ok on XP with MSDE2000A previously.I'm programming in .NET C# CLR2.0, any body know what's going wrong?

View 3 Replies View Related

Create Database Failed In Windows Vista

Apr 16, 2008

Hi All,

I have installed SQL Server 2005 Express in windows vista. I am trying to create database it is giving me error
"CREATE DATABASE Permission denied in database 'master'".

I read some article and they told, have to add an administrator account from SQL Server 2005 Surface Area Configration.
But, I cannot find any option in SQL Server 2005 Surface Area Configuration called "Add New Administrator".

What could be reason for this?

Any Idea....??

Thanks,
Narayana Ayyagari

View 6 Replies View Related

How Do I Create Dbo Ownership Of An Object

Feb 11, 2008

I have a user who has been granted db_owner rights to a database and want him to be able create new views using the dbo schema. When the user creates a view right now, the schema created is under their username. How can I change this so that when a user creates a new view, they always create it under the dbo schema.

View 3 Replies View Related

SQL Agent Job Fails-Can't Create Object

Jun 3, 2004

I have read many threads on this issue & tried multiple solutions to no avail.

Here's my environment: SQL 2000, Logged directly into server via VPN (so it should be like I am physically at the server).

I've set up a DTS Package that executes an Access procedure. The package runs fine when I execute manually. When I execute via schedule, it fails on the error "ActiveX component can't create object: 'Access.Application'. The actual statement is:

Set objDB = CreateObject("Access.Application")

I know that Scheduled jobs default back to the SQL Agent permissions. I have reset SQL Agent to use my Windows NT account login so it should have the exact same permissions, etc. that I have when I execute manually?

Any help will be GREATLY appreciated!!!

Thanks mucho,
Brian

View 11 Replies View Related

How To Grant Permission To Create A New Object

Jan 23, 2008

I am new to sql server. right now i getting used to management studio.I am trying to creata a new object / a new database but i am getting an error which says permission not granted

can any help me to move ahead

thanks

View 1 Replies View Related

Create Folders In Object Explorer - Wish...

May 4, 2007

Here's one thing that I'd like to see come out in some version of the SQL Server Management Studio...
The ability to create folders under the database node so that databases can be grouped on one server.

We have over 100 databases on our development server and these are created by a range of consultants and developers and even support staff as needed.

Being able to group the databases by product, etc would be a nice touch since we have client databases that don't fit naming conventions etc.

Multiple instances are another way around this but are expensive and resource hungry - we develop and support models, not use them for transactions too much.



Yes there are 'better' ways such as setting security correctly but we are too busy working and not maintaining.

Folders or database groups would be a nice touch.



Cheers

View 1 Replies View Related

How To Create An Object Without Being The Owner Of The Schema

Apr 6, 2006

Hi

I have a schema called Accounts owned by fred

User bob has create procedure permission as follows:

grant create procedure to bob

bob would like to create a procedure in schema Accounts.

When he issues create proc Accounts.sp_proc.... it fails with:

Msg 2760, Level 16, State 1, Procedure sp_proc, Line 3
The specified schema name "Accounts" either does not exist or you do not have permission to use it.


What permission do I need to grant bob in order to allow this?

Thanks

View 4 Replies View Related

Unable To Create Object Error In Sp_SendSMTPMail

Jul 20, 2005

Hello,I am attempting to send emails using T-SQL (in a SQLServerAgent Job)using the stored procedure sp_SendSMTPMail. I created the stored procusing the following script that I got off a post here on google.CREATE PROCEDURE sp_SendSMTPMail (@From varchar(255),@To varchar(8000),@Subject varchar(255),@Body varchar(8000),@cc varchar(8000) = NULL,@Bcc varchar(8000) = NULL)ASDECLARE @newmail intDECLARE @result int-- Create the CDONTS.Newmail objectEXEC @result = sp_OACreate 'CDONTS.NewMail', @newmail OUTIF @result <> 0BEGINPRINT 'Error creating object'EXEC sp_displayoaerrorinfo @newmail, @resultRETURNEND-- Check the Optional PropertiesIF not @cc = NULLBEGINEXEC @result = sp_OASetProperty @newmail, 'cc', @ccIF @result <> 0BEGINPRINT 'Error setting [cc] property'-- EXEC sp_displayoaerrorinfo @newmail, @resultRETURNENDENDIF not @Bcc = NULLBEGINEXEC @result = sp_OASetProperty @newmail, 'Bcc', @BccIF @result <> 0BEGINPRINT 'Error setting [Bcc] property'-- EXEC sp_displayoaerrorinfo @newmail, @resultRETURNENDEND--set the non-optional propertiesEXEC @result = sp_OASetProperty @newmail, 'From', @FromEXEC @result = sp_OASetProperty @newmail, 'To', @ToEXEC @result = sp_OASetProperty @newmail, 'Subject', @SubjectEXEC @result = sp_OASetProperty @newmail, 'Body', @Body-- Send the message...EXEC @result = sp_OAMethod @newmail, 'Send'IF @result <> 0BEGINPRINT 'Error sending message'-- EXEC sp_displayoaerrorinfo @newmail, @resultRETURNEND-- Destroy the object.EXEC @result = sp_OADestroy @newmailIF @result <> 0BEGINPRINT'Error destroying object'-- EXEC sp_displayoaerrorinfo @newmail, @resultRETURNENDGO______________________________________________This worked perfectly in testing at our office but when we shipped tothe client it produced the error 'Error creating object'. We sent theclient the script to create the sp_displayoaerrorinfo proc and got thefollowing error message.Error creating object-2147221005OLE Automation Error InformationHRESULT: 0x800401f3Source: ODSOLE Extended ProcedureDescription: Invalid class stringNow this suggested to me that the for some reason we were unable toreference the CDO library, or it wasn't installed. However they haveOutlook 2000 installed with CDO installed with it. I've had had themremove and reinstall the CDO library but that hasn't helped.Other thing I though of was a permission type problem. They are usingNT authentication for there logins into SQL server and are logged onthe server as Administrator who I would assume has all requiredpermissions.Any suggestions for either determining the cause of them problems or asolution?Thanks in advance.Bob.

View 3 Replies View Related

Cannot Create An Instance Of OLE DB Provider VFPOLEDB Object

Jan 23, 2007

Hi forum

I'm developing a report in SQL Server 2005 Reporting Services based on a query from SQL Server tables joined with Visual FoxPro free tables. I created a Linked Server with Microsoft OLE DB Provider for Visual FoxPro provider, whith VFPOLEDB.1 string provider. Everything runs ok
within a Business Intelligence Development Studio environment, but when I implement my report, at runtime an error occurs it said "Cannot create an instance of OLE DB Provider VFPOLEDB object". I swtched any combination of Linked Server security and Provider security pages without to solve the problem.

Navigating the web today, I read a similar thread posted by stephanielauym
at April 3, 2006 but I`m not clear if she passed the issue or not. In case of yes, I would like to know how she solved it. I'proved among other with "Allow inprocess" but don't.

Please, if Stephany or Cindy (that she answered) or anyone knows how to solve this error, I'll thank very much.

Arturo CarriĆ³n
artcarrion@yahoo.com.ar
at Tiempo Hard SA
Mendoza, Argentina

View 3 Replies View Related

DB Engine :: User Does Not Have Permission To Create A New Object

Aug 28, 2015

I have a new instance (SQL 2012) and I am trying to create a cube but it retrieves the error: Either the 'NameUser' user does not have permission to create a new object in 'NameServer' or the object does not exist. I am not the DBA but I got privilege as administrator in my instance. I even checked the propierties (right click on the analysis service instance) and in security there is my name as well..

View 4 Replies View Related

Create A Synonym For A Table Object On Remote Server

Apr 16, 2015

I'm using SQL Server 2008R2. I am developing a database which requires access to data from other servers. So far I have been creating views using OPENQUERY (where there's a performance benefit) to select specifically the columns I want. Generally, for my purposes, I find these OPENQUERY based views to perform better (some times significantly so) to simple SELECT <COLUMNS> FROM <SERVER>.<DATABASE>.<SCHEMA>.<TABLE> WHERE <Where clause Statements> format views. My understanding is that this is because an OPENQUERY "pushes" the query processing to the remote server and simply returns the final result set to the local server i.e. there's no cross-server join/synchronization going on.

My question is, if I were to create a Synonym for a table object on the remote server, where does the processing happen if I query from this Synonym or create a join with this synonym to a table in my local database?Essentially, I am trying to understand if there are any "hidden gotcha's" primarily from a performance perspective, to using synonyms.

View 1 Replies View Related

Cannot Create An Instance Of The XML Document Object Model. MSXML May Not Be Registered

Jan 31, 2007



I have a small VB.Net 2005 app using the Microsoft.SQLServer.ManagedDTS.dll so I can use the SSIS/DTSx functionality.

The program ran fine in the IDE.

Then when I tried to create a setup project for it I recieved a warning that all dependancies for MSXML6.DLL were not found.

I clicked ok and the setup was created.

I tried to run the setup and it failed with "....msxml6.dll failed to register. HRESULT -2147023782. ...

So I said cancel the setup and registered msxml6.dll.

I deleted my setup project and recreated it. This time I did not get the warning about msxml6.dll dependancies.

I tried the setup again and it executed without any errors however when I run the program I now get:

"Cannot create an instance of the XML Document Object Model. MSXML may not be registered."

So I went back into the IDE with the project and now it will not run either. IT gets the same error.

Does anyone have any suggestions?

View 3 Replies View Related

Keep Existing Object Unchanged Or Create Schema At Subscriber =false?

Aug 15, 2006

 Hi,

I have the same database(3GB) in 2 physical locations in usa and europe

I need to create a publisher and subscriber between these 2 database without sending any snapshot  because i have the same data in the 2 sides, is it possible ?

Thx

Jim

View 13 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved