Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Using RDO Connection

Connection String

Set RdoVisPay = rdoVISENV.OpenConnection("VISA", 1, False, "DSN=VISA;UID=sa;PWD=sa;APP=Visual Basic;WSID=" & ServerName & ";DATABASE=" & Database1)

Showing error as "heterogeneous queries require the ansi_nulls and ansi_warnings options to be set for the connection"

How to add the ansi_nulls and ansi_warning Connection in the connection string.

Need Suggestion and Help.

share|improve this question

migrated from stackoverflow.com Feb 6 '12 at 13:16

This question came from our site for professional and enthusiast programmers.

You can't. They are set per connection, but not in the connection string. So run some SQL after creating the connections

SET ANSI_NULLS, ANSI_WARNINGS ON;

Note though, the error you have is caused by a linked server call from your SQL Server. Depending on how you set this up (say via a stored procedure) you may need to change the stored proc or view, or set the values in the code. Hard to say as it stands.

share|improve this answer
    
How can i add this line in insert query...? – user1157846 Feb 6 '12 at 9:46
    
@user1157846; no idea. Not enough information – gbn Feb 6 '12 at 9:51

This is a confirmed bug of sql2000.

Check the info about it HERE.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.