SQL 2000 View Has Column Binding Errors

Feb 11, 2008


Hi all,

I'm trying to use a SQL 2000 view in one of my sources. The view isnt anything special --- just three tables that have been unioned together. All these three tables have the EXACT same datatypes as well as column names. There are no constraints on these tables (yet). There is an identity seed on the first ID column. However, when I try to access this view, it generates the following error:

Server: Msg 4502, Level 16, State 1, Procedure MyView, Line 5
View or function 'MyView' has more column names specified than columns defined.
Server: Msg 4413, Level 16, State 1, Line 1
Could not use view or function 'MyView' because of binding errors.

Does anybody have any experience with this?

View 3 Replies


ADVERTISEMENT

Creating Schema Binding View

Jan 18, 2008

Dear All,
we are using one view which is having around 30000 rows.
it is taking too much time to retrieve data. that's why i've decided to create an indexed view.

now i'm getting this error.
Cannot schema bind view 'view1' because name 'Table19' is invalid for schema binding. Names must be in two-part format and an object cannot reference itself.

what is the solution for this error?


Vinod
Even you learn 1%, Learn it with 100% confidence.

View 7 Replies View Related

DB Design :: Schema Binding A View In Management Studio

Oct 13, 2015

I'm using SQL Server 2008 R2 Management Studio. I have a view that I'd like to index. Obviously, that requires that the view be schema bound to the underlying table. I have found myriad explanations for how to programmatically create a schema bound view, but I've never created a view like that before, and since I'm more a mechanical engineer than a database manager, I'd like to be able to do it the 'easy' way, by just creating the view in Management Studio by going to the database, right clicking on 'Views', clicking on 'New View...' and then, hopefully, checking some box somewhere that schema binds the table to the view.

View 2 Replies View Related

Problem Binding Lisbox Value With The Database Column?

Jan 30, 2008

 Hello Friends..I m using vwd 2005 express along with sql express.I have a web form with different server controls like textboxes, labels, radiobuttons, listboxes etc.lets focus on listbox. 1..For example lets say,ListBox contains 5 email addresses of the user.  
Now my main problem is when i submit my webform,all my data from
textboxes, radiobuttons etc gets stored into the sqldatabase.   But the data from my ListBox doesnot get stored into the database.   But when i manually select a single email address from the listbox the email address in this case gets saved in the database.  
But as soon as i choose multiple email address then in this case only
the first email address only gets saved but not the rest.   How to over come this problem? I have a  column named "email" in my table in the database.   Can some one explain me this with the code(C#)..  2..And my 2nd question is i dont want to manually select the data from the listbox so that it gets saved into the database.    I want all the email address in the Listbox gets automatically selected as soon as i click on the save button at     the end of my web form.   
   Any idea on how to approach this,friends?   Thanks..  
  Jack.

View 6 Replies View Related

Using Stored Procedures To Set The Default Value Or Binding Of A Table Column

Nov 24, 2007

I want to be able to have an authorized person set or change the default values of a table column in a SQL Database. I have a stored procedure that sets the default which works fine: ALTER PROCEDURE [dbo].[addMyConst]ASBEGINALTER TABLE [dbo].[tbl1]ADD DEFAULT 70 FOR [Auto_ourlim]END(I still need to put parameters in so that I can run the stored procedure from a form, but for now....)
 To change it I know that I have to drop the constraint first like this:
ALTER PROCEDURE [dbo].[dropmyValue]ASALTER TABLE [dbo].[tbl1] DROP CONSTRAINT [Auto_ourlim] 
The problem is that when I execute the procedure I get the error that "Auto_ourlim" is not a constraint so it does not drop the Default Value. When I go over to SQL Server Management Studio Express I can see why:
If I open up the table and open up the Constraints the constraint is "DF__tbl1__Auto_ourli__5FB337D6". I could change the DROP CONSTRAINT to this, and that works, but it changes every time I add the new DEFAULT VALUE.  I don't know how to get around it. Is there a way to put wildcards around "Auto_our" in DROP CONSTRAINT [Auto_ourlim}? Any suggestions would be welcome...even if there's a totally different way to do it.
What I'm trying to ultimately accomplish is this: Column1 (AutoLimits) would be user insert to the database and then in the database it would MINUS Column2 (Auto_ourlim - set with the default value) = Column3 (Difference - a computed field in the database)
Steve

View 2 Replies View Related

Binding A DataSource Table Column To A Form Object (RadioButtons)

Oct 25, 2006

Hi,

  I have a little question.  I have an application which interfaces with a SQL Express Database.   On a form, I want to bind a control which is made of several Radio buttons to a table column which is in fact a varchar(1).  This is the picture:

        Table column:  OptVisualRpt  varchar(1)

        Screen control:  2 radio buttons

                                    rb_VisRPTbImp_O    for "yes"

                                    rb_VisRPTbImp_N    for "no"

 

  I'm really scratching my head as how I can bind a single table column to my radio buttons controls.   I think that I just can't this way but rather have to use an intermediate variable or control. 

Solution 1?

 I thought of using a local variable that I would set to "y" or "n" following "CheckedChanged" events fired from radio buttons but I don't know how to bind this variable to my table column.                 

Solution 2?

  I thought of placing a hidden text control into my form, which one would be binded to my table column, that I would also set to "y" or "n" following "CheckedChanged" events fired from radio buttons.

Any of these solutions which would be feasible or any more neat way to do it?

Many thanks in advance,

Stéphane

View 1 Replies View Related

Errors Exporting A View

Mar 2, 2000

I am trying to export a view defined as follows (to cleanse data):

Create View Cleanse_View as
SELECT Primary_Key, Name, Value,
SUBSTRING(Name, 1, len(Nam) - len(Value)) AS Test_Method
FROM My_Table


THE FOLLOWING ERROR IS GENERATED WHEN EXPORTING (USING SELECT, etc):

Server: Msg 536, Level 16, State 3, Line 1
Invalid length parameter passed to the substring function.
The statement has been terminated.

Any ideas of what's causing this because the view works fine?

Thanks
Ziggy

View 2 Replies View Related

View Creation Errors --Urgent -- Please Help

Apr 11, 2000

I am creating a view consisting of 278 to 300 columns. ( I want to use this view for data entry). The columns are of varchar(30) datatype. I am able to successfully create the view but upon opening the view in Enterprise Manager or Access I get the following error:

Too many columns defined in rowset.

Is this a bug? Please advise.

Thanks

Ziggy

View 1 Replies View Related

Create View Errors In SQL 2005

Oct 24, 2007

We have a script that drops the views on all the database tables and then creates them as part of version update of the database. For instance:

if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[SPONSOR_SYSTEM_TD]') and OBJECTPROPERTY(id, N'IsView') = 1)

drop view [dbo].[SPONSOR_SYSTEM_TD]

GO

CREATE VIEW dbo.SPONSOR_SYSTEM_TD AS SELECT sponsor_installation_type_code,install_directory,sponsor_version,data_directory,system_install_text,record_status_code,mod_date_time,mod_login_id,create_date_time,create_login_id,replicate_to_server_flag,Sponsor_ID FROM SPONSOR_SYSTEM

GO


This above code is done for all 120 tables and has worked fine until now. All our clients have been using SQL 2000. Now we are getting clients with SQL 2005.

The problem is that for these clients using SQL 2005 on 20 of the tables we get the error:

Could not resolve expression for schemabound object or constraint.

And the View is not made for these tables. I saw where this could because the server and database collation is differemt but in this case it's the same for both. I can't see any differences so far between the tables that a View was successfully made for and the ones that it wasn't.

What else should I be looking for that would give this error?
Thanks

View 5 Replies View Related

Cannot See The Colums In The Design View Of Queries SQL 2000 And MSAccess 2000(adp)

Nov 21, 2006

Cannot see the Colums in the "design view" of Queries. All i see when i want to design a new query is *columns

This happens in only one database, in other databases using same server i can see the colums and can tick them to view then in the query.

In enterprise manager i see all the columns.

Using SQL 2000 and MSAccess 2000

View 1 Replies View Related

Create Multi Column View From Single Column Data

Jan 9, 2008

I have two tables, one a data table, the other a product table. I want to perform a join on the two tables with values distributed into columns based on the value in the month field.

data_table
product_code month value
350 1 10
350 2 20
350 3 30

product_table
product_code profit_center
350 4520

result_view

product_code profit_center mon1 mon2 mon3
350 4520 10 20 30

My current query gives the following result
result_view

product_code profit_center mon1 mon2 mon3
350 4520 10 0 0
350 4520 0 20 0
350 4520 0 0 30

Any direction toward a solution would be appreciated. Am using SS2005.

View 5 Replies View Related

'Cannot Find Column' Errors

Oct 11, 2007

Greetings!I have a project that has been in production for a couple years now. It's a v1.1 ASP.NET web farm hitting a SQL database. The last couple weeks, the website has been erroring out on  various pages for about 1-2 hours at a time twice a week. While the error messages are occurring, I cannot reproduce the errors myself.  Here are some of the error messages I recieve:Cannot find column [ColumnName][ColumnName] is neither a DataColumn nor a DataRelation for table RESULT.[ColumnName] (This is a wierd one. The error message returned is just a column name)No record foundColumn '[ColumnName]' does not belong to table RESULT.I come to a dead end when I follow the Stack Trace to find a programmatic error.  I'm able to hit the same page with all the same form fields at the error occured on and I cannot reproduce. The only consistentcy in these errors is that they come all at once and they are database related. Anyone have an issue like this before?  

View 8 Replies View Related

Plz Help Me Consistency Errors In MSSQL 2000

Feb 28, 2007

I’ve got a big problem with my Database,
Whenever I runs my query I’ve got error on the half way.
I’m using MSSQL 2000.
So I run DBCC CHECKDB and the follow errors result shown.
I don’t know how to solve that problem.

Plz help me plz help me
If that database crush I’m gonna be fu*ked up by my boss.
:...( plz


DBCC results for 'Table_1'.
Server: Msg 8928, Level 16, State 2, Line 1
Object ID 795149878, index ID 0: Page (1:352679) could not be processed. See other errors for details.
Server: Msg 8944, Level 16, State 1, Line 1
Table error: Object ID 795149878, index ID 0, page (1:352679), row 44. Test (!(hdr->r_tagA & (VERSION_MASK | RECTAG_RESV_A | RECTAG_RESV_B))) failed. Values are 157 and 193.
Server: Msg 8944, Level 16, State 1, Line 1
Table error: Object ID 795149878, index ID 0, page (1:352679), row 44. Test (ColumnOffsets <= (nextRec - pRec)) failed. Values are 18754 and 3160.

There are 0 rows in 1 pages for object 'Total_Profit_Loss'.
Server: Msg 2511, Level 16, State 2, Line 1
Table error: Object ID 1211151360, Index ID 0. Keys out of order on page (1:161199), slots 25 and 26.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 1211151360, Index ID 0. Keys out of order on page (1:173791), slots 4 and 5.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1211151360, index ID 0: Page (1:206443) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 1211151360, index ID 0, page (1:206443). Test (m_freeCnt == freeCnt) failed. Values are 660 and 692.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 1211151360, Index ID 0. Keys out of order on page (1:217603), slots 18 and 19.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 1211151360, Index ID 0. Keys out of order on page (1:266945), slots 26 and 27.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 1211151360, Index ID 0. Keys out of order on page (1:268051), slots 28 and 29.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1211151360, index ID 0: Page (1:277634) could not be processed. See other errors for details.

DBCC results for 'Pin'.
Server: Msg 8939, Level 16, State 106, Line 1
Table error: Object ID 1211151360, index ID 0, page (1:277634). Test (m_freeCnt == freeCnt) failed. Values are 2168 and 2164.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1211151360, index ID 0: Page (1:299697) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 1211151360, index ID 0, page (1:299697). Test (m_freeCnt == freeCnt) failed. Values are 3435 and 3431.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1211151360, index ID 0: Page (1:302290) could not be processed. See other errors for details.
Server: Msg 8944, Level 16, State 1, Line 1
Table error: Object ID 1211151360, index ID 0, page (1:302290), row 12. Test (((UNALIGNED DataRecHdr*) m_pRec)->r_tagB == 0) failed. Values are 4 and 0.
Server: Msg 2511, Level 16, State 1, Line 1
Table error: Object ID 1211151360, Index ID 0. Keys out of order on page (1:900223), slots 2 and 3.
There are 5940869 rows in 210312 pages for object 'Pin'.
CHECKDB found 0 allocation errors and 14 consistency errors in table 'Pin' (object ID 1211151360).

CHECKDB found 0 allocation errors and 23 consistency errors in database 'MY_SQL_DB'.
repair_allow_data_loss is the minimum repair level for the errors found by DBCC CHECKDB (MY_SQL_DB ).
DBCC execution completed. If DBCC printed error messages, contact your system administrator.

View 1 Replies View Related

SQL 2000 Server Backup Errors

Aug 20, 2004

I am experiencing the following problem when running a backup. This process was working really fine for 3 months.

BACKUP DATABASE [DBLIVE] TO DISK = N'C:BACKUPSdblive' WITH INIT , NOUNLOAD , NAME = N'DBLIVE backup C', NOSKIP , STATS = 10, NOFORMAT

Database size 10G
Recovery Mode : Simple
Daily Backup

Error message:

Executed as user: ACC33Administrator. 10 percent backed up. [SQLSTATE 01000] (Message 3211) 20 percent backed up. [SQLSTATE 01000] (Message 3211) 30 percent backed up. [SQLSTATE 01000] (Message 3211) 40 percent backed up. [SQLSTATE 01000] (Message 3211) 50 percent backed up. [SQLSTATE 01000] (Message 3211) 60 percent backed up. [SQLSTATE 01000] (Message 3211) Nonrecoverable I/O error occurred on file 'D:sqldbDBLIVE_Data.MDF'. [SQLSTATE 42000] (Error 3271) BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013). The step failed.

Thank You.

View 9 Replies View Related

SQL Server 2000 SP3 Transaction Log Errors

May 31, 2008

Hi!

We have a Microsoft SQL Server 2000 SP3 running database for Microsoft
Navision 3.7

From time we encounter problems, especially when running heavy query
procedures from Navision, with the transaction log. It's actually setup as
folows:

File properties:
File growth By percent (10)
Restrict file growth (MB) 10000

OPTIONS:
Recovery model: simple
Settings: Autoupdate statistics, Auto create statistics, Autoshrink

We get the following errors (once every 2-3 months so far):

The log file for database 'ME_Prod' is full. Back up the transaction log for
the database to free up some log space..


in between numerous abovementioned messages I have the following:
Configuration option 'show advanced options' changed from 1 to 1. Run the
RECONFIGURE statement to install..

Could not write a CHECKPOINT record in database ID 9 because the log is out
of space.

Automatic checkpointing is disabled in database 'ME_Prod' because the log is
out of space. It will continue when the database owner successfully
checkpoints the database. Free up some space or extend the database and then
run the CHECKPOINT statement.

View 10 Replies View Related

URGENT: Sp_repldropcolumn Errors (SQL-2000)

Mar 27, 2006

Environment:


- Publisher: SQL 2000 (SP4)


- Distributor/Subscriber: SQL 2000 (SP4)


- Replication: Transactional/Continual updates





Issue: Calls to sp_repldropcolumn are generating the following error:





Server: Msg 4932, Level 16, State 1, Line 1


ALTER TABLE DROP COLUMN failed because '_column_' is currently replicated.





The column in question is a text-blob, so I am unsure if the data type is at


fault.





I'd prefer to use sp_repldropcolumn versus drop subscription->drop


article->drop column->add article->add subscription method.





Any help appreciated.

View 1 Replies View Related

Numeric Comparison Errors On SQL 2000

Feb 4, 2008



I have several SQL 2000 servers that are running SQL 8.002162. Most are Windows 2003. Because of a note I saw in a non MS forum, I was testing these servers for the numeric comparison issue in MS article 899976, "FIX: A query that involves data that is the numeric data type may return incorrect results in SQL Server 2000 SP3 and in earlier SQL Server 2000 service packs". All the servers act as expected (fixed) since they are running post SP4 and patches. But, one server fails the comparison test scripts in the KB. All these servers are running the same version of SQL. The server that still fails is windows 2003 SP1.

Why does one server reporting to be version 8.002162 fail a test that should be patched and does it mean that although the server is reporting it is version 8.00.2162 it has failed some updates and might be upatched for other issues?

View 1 Replies View Related

Ignore Errors In SqlServer 2000 (try/catch)

Jul 7, 2006

Is there any way to emulate the try/catch mechanism that SqlServer2005 provides using SqlServer2000?
Or more simply,
Is there any kind of IGNORE_ERROR or CONTINUE_ON_ERROR setting for SqlServer 2000?

Thanks

- John

View 2 Replies View Related

Errors After Installing Server 2000 DTS Designer Components

Jan 30, 2007

Hello,

After Having installed the SQL Server 2000 DTS Designer Components necessary
to edit legacy DTS packages on 2005 server, I keep getting the following message when trying to open SQL Server 200 Enterprise Manager:

"The procedure entry point
?ProcessExecute@@YAXPAUHWND_@@PBG1@Z could not be located in teh dynamic link library SEMSFC.dll."


Is there a way to fix so that I can open Enterprise manager?

Thanks!



View 9 Replies View Related

Getting ODBC Connection Errors With SQL Server 2000 On Windows XP

Apr 21, 2008

Hi all-

I setup a new ODBC connection to MS SQL Server 2000 on Windows XP and keep getting the following errors when I try to
either register a new SQL Server 2000 group within Enterprise Manager or test the new ODBC connection:

Current configuration

- MS SQL Server 2000
-Windows XP
-ODBC 3.85.1117


Errors:

I. Within SQL Server 2000 Enterprise Manager

Error: SQL Server connection open

II. When I test the ODBC connection:

Microsoft SQL Server ODBC Driver Version 03.85.1117

Running connectivity tests...

Attempting connection
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]Specified SQL server not found.

TESTS FAILED!

Now here is what has me totally confused:

I can use the command line ISQL to access the database on the server and IP is all correct and port is available.

Any tips how to get this ODBC working?

Thanks
Ben Prusinski

View 1 Replies View Related

Corrupted Table In SQL 2000, DBCC CheckDB Found No Errors

Jan 21, 2008

Hello,

I am facing an issue with a table in my database.

1) When I run a query Select * from MY_Table the query never completes. If I press cancel in Query Analyzer after 1 second or 2 minutes, it always shows the same 174 records. The total table size is 800 KB with 3148 rows .. according to TaskPad

2) No queries, even queries that would return only 1 record complete execution against that table

3) I am unable to rename the table, if I try to rename the table Enterprise Manager becomes unresponsive and has to be closed.

4) If I try to browse the rows through Enterprise manager by scrolling through the records, it allows me to go down through a number of rows and then Enterprise manager gives me a timeout expired error.

5) I ran a DBCC CheckDB command ran for 1 hr and 7 minutes. It says there are 0 allocation errors and 0 consistency errors in the database.

6) The other database tables seem to be OK and the Database is operational except for calls involving the 1 Table

7) I am unable to Drop the Table

8) DBCC CheckAlloc finds 0 allocation errors and 0 consistency errors.

9) DBCC CheckTable on MY_Table returns with: There are 3148 rows in 33 pages for object 'MY_Table' .. no errors are printed.


Can one of the SQL Gurus on this forum please recommend a course of action.

Thanks in advance.

View 1 Replies View Related

SQL 2012 :: Ignored Column In SSIS Package Throws Conversion Errors?

Dec 12, 2013

I have a data flow task in which I have a ADO NET source and OLE DB Destination. I have in the ADO NET source a sql command which pulls all the columns in a table. My requirement is to ignore a particular column,say column99. I opened advanced editor and deleted the mapping between the external and output columns for column99. I had also set the Error and Truncation to "Ignore Failure" for column99. I had also mapped the destination column to <Ignore> in OLD DB destination.

But this still throws the error-

Description: The ADO NET Source was unable to process the data. Field table-column99 missing an escape character for a quote.Unable to update PK WHERE clause.Error processing data batch.

How do I solve this?

View 9 Replies View Related

RS 2000 - Can't Start Report Manager / Permission Errors / Need To Update Data Source

Jul 5, 2007

We are going insane trying to start Report Manager on a SQL Reporting Services 2000 installation. The programmer/admin who originally set this up for us is gone.



We recently upgraded a database/application server to a new server, causing the data source being used by reports in reporting services to no longer be valid. Unfortunately, we do not have access to the original report project to 're-deploy' with the corrected data source.



We desperately need to get the reports that are installed to retrieve their data from the new database location/machine. We understand this can be done by specifying a new data source in Report Manager. (To clarify, we have NOT moved the report servier installation or database, these remain in place - it's just the deployed reports that no longer point to the correct data source.)



For some reason, our Report Manager will no longer run - when we try to launch it, we get a windows login dialog - nothing will work here. We've tried both local and domain admins and constantly get ACCESS IS DENIED 401.3 error messages that we do not have permission/problems with ACL's.



We've gone so far as to allow EVERYONE read/write access to the ReportManager and ReportServer folders and the RS virtual directories, but nothing seems to help.



Can anyone help with this? Ideas on how to change our data source, or how to get back into Report Manager?



Since we are somewhat technical, but not experts, and don't have much more time to waste, we are willing to pay $500 for this project to someone willing to access the server and fix the problem so that the reports point to the correct database and restore access to Report Manager.



Thanks in advance for any help.

View 1 Replies View Related

SQL 2000 View

Dec 24, 2007

The table I want to query contains data structure like so

tblText
-------
VisitId(int)CodeId(int) ChrText VarChar()
1 2 'Text Code2'
1 3 'Text Code3'
2 1 'Text Code1'
3 3 '*TextCode3*'
4 1 'Text Code1'
4 4 'Text COde4'

What I want is for my View to Look Like this

VisitId Code1 Code2 Code3 Code4
1 N/A Text Code2 Text Code3 N/A
2 Text Code1 N/A N/A N/A
3 n/a n/a *TextCode3* n/a
4 Text Code1 n/a n/a Text COde4

I am sure I Group by VisitId, but do not know the correct function to construct the rest of the Select Query

Create View vw_tblText
As
Select VisitId,
Case(intCodeId=1 Then chrText Else 'N/A' End) As Code1
Case(intCodeId=2 Then chrText Else 'N/A' End) As Code2
etc..
From tblText
Group by intVisit

Any Ideas much appreciated

View 7 Replies View Related

View Permision Sql 2000

Jan 10, 2006

I created a new user (Joe_Reader) and gave this user the db_datareader Role.I then went and specified what tables and queries would this user see. Thisworks fine. I however keep on creating tables and views on the database andautomatically these objects are viewable by the user. I have to manually goand deny the access for each object I create. Is there a way that I canonly let Jo_Reader see the tables that I originally assigned and that noneof the other queries or views are viewable by himThanks

View 1 Replies View Related

Indexed View In Microsoft SQL 2000

Nov 19, 2004

Just wonder how many of you are using or had used indexed view in SQL 2000? Please, share any details/info.

We are currently using in and having problems as we are getting Errors 644, 'Couldn't find index...' every time we try to update the underlying tables.

View 2 Replies View Related

Create A View In MSSQL 2000

Oct 12, 2005

I have created a view in MS SQL2000 as followed:

Select order_NO, shiptoname, Shiptoaddress, Shiptocity,shiptostate, shiptozip,
EMAILaddress
FROM orders;

my question is: If the email exist in the EMAILaddress column then I need to have a Y show in another column called EMAILflag, if the EMAILaddress does not exist then I would need the EMAILflag to be a N.

Any HELP would be GREAT.
Thank You!!

View 3 Replies View Related

SQL Server 2000 Hangs On A View

Feb 18, 2007

I am working in Powerbuilder and SQL Server 2000. Within the application I dynamically Drop then recreate a view named view_selection_list. When another user accesses any screen using view_selection_list the screen will hang on the statement "If Exists (SELECT name FROM sysobjects WHERE name = 'view_selection_list' AND type = 'V') DROP VIEW view_selection_list".
I also went directly onto the database ran select * from view_selection_list from Query Analyzer. It hangs when the original user creating the view is still active. I know that the issue is locking. I don't know how to fix it.

For example ;
String ls_sql
ls_sql="If Exists ( SELECT name FROM sysobjects WHERE name = 'view_selection_list' AND type = 'V') DROP VIEW view_selection_list "
Execute Immediate :ls_sql;

ls_sql="Create View view_selection_list as "
Case 'State'
ls_sql+=" Select distinct proj_id,'State - '+proj_state title from project where proj_state='"+is_data+"'"

Case 'Project'
ls_sql+=" Select distinct proj_id,'Project - '+proj_nam title from project where proj_id='"+is_data+"'"

Case 'All Active Projects'
ls_sql+=" Select proj_id,'Project -' +proj_nam title from project where proj_status = 4 and signed_acq_agmt = 'Y' "

End Choose

Execute Immediate :ls_sql;

The SQL Server connection in the application is:
SQLCA.DBMS = "OLE DB"
SQLCA.ServerName="acq"
SQLCA.LogPass ="*******"
SQLCA.LogId = "acq"
SQLCA.Lock = "RU"
SQLCA.AutoCommit = False
SQLCA.DBParm = "PROVIDER='SQLOLEDB',DATASOURCE='FSRFIN103'"

Thank You
Stanley

View 11 Replies View Related

Materialized View In Sql Server 2000

Mar 12, 2008

Can some one please help to find out that how can i implement the materialized view in sql server 2000? thanx for consideration.

Rahul Arora
07 Batch
NCCE Israna,


######################
IMPOSSIBLE = I+M+POSSIBLE

View 2 Replies View Related

Is It Possible To Export A View To Excel In MS SQL 2000 ?

Jul 23, 2005

Hi all,In MS SQL Management Console I can right-click on any Table and I havethe option All Tasks > Export Data where I can export the table toExcel. In a View however this isn't there. I have many views I wantto simply export to Excel, but the only way I've found to do it iscreating an ODBC connection to the MS SQL database from MS Access,linking the Views to Access Tables, and exporting from Access. surelythere's someway to export a View to Excel within MS SQL easily likeexporting a table...Thanks ---Alex

View 1 Replies View Related

View Not Working SQLSERVER 2000

Jul 20, 2005

Hi allWe have some tables with a couple of layers of very simple views built ontop. In the table are maybe 6 columns and about 15000 records. The firstview cobines the data in the table with some other data from a lookuptable. The second view does some sorting on the first view using certaindates . They have worked fine for well over a year now.Until this morning that is... the views stopped returning the full set ofresults- even the very simple one that sits just above the table. The viewreturned the core of the data from the main table, but nothing from thelookup table.In order to get them to work we had to delete each view (using access frontend to do this), and then recreate it with exactly the same SQL text. I amguessing this causes SQL Server to recompile it. As soon as view 1 had beenrecreated it worked, but view 2 still failed, again rebuilding view 2 itstarted working.The only thing I can think of is that this morning I added 2 new fields tothe base table, but I'm sure I've done this before without any (noticable)problems.any thoughts as to why it happened would be welcome, I am a bit nervousnow...thanksAndy

View 5 Replies View Related

SQL 2000 Taskpad View/access

Feb 22, 2006

Hi there,

Not sure if this is possible but anyways. Need to restrict access on systems for users

and at the moment they are limited to being server and process administrators only.

This gives them enough room to do what they need to do, however the taskpad view in Enterprise manager only shows them the Log space used, not the datafiles.

The only way to get the TaskPad view to show the datafiles is to add them to the database creators role, which already gives them more permissions than they need.

So, just a shot in the dark but is there someway to get Taskpad view to show all the info there about the database?

View 3 Replies View Related

How To Add An Identity PK Column To A View

Nov 16, 2007

For an ASP.net project, I have had a DropDownList with a static ArrayList.The ArrayList will be defined from a View, where there is no Identity PK. 
I also have used cbxDropDownListName.SelectedIndex to add new data toa table, where an Indetity PK is used to reference the ArrayList. 
 I am wondering how can I add an identity PK to my view?
TIA,Jeffrey

View 1 Replies View Related







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