.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Msg 102, Level 15, State 1 on view creation

Posted By:      Posted Date: September 04, 2010    Points: 0   Category :Sql Server
Hi im trying to create a view from a table having the following value for: Each of the Id linking to another table,the user should be able to search for userid based on any criteria. UserId | UserRegionID |JobTypeID | CountryID | YrOfExp ------------------------------------------------------------- 53 27|20 23|36|24 204 16 54 29|20|33 25|24 172 5 55 22 36 204 3 The YrOfExp must be compared and the appropriate id stored in the view. Create view vwUserDetails as with vwUserDetails(userId,jobsID,RegionID,YrOfExpID) as ( select UserId, convert(xml,'<Job><JobId>'+ replace([UserJobTypeIDs],'|','</JobId><JobId>')+ '</JobId></Job>') as jobsID, convert(xml,'<Region><RegionId>'+ replace(Rtrim(Ltrim([UserRegionIDs])),'|','</RegionId> <RegionId>')+</RegionId></Region>') as RegionID, YrOfExpID = case UserYearsOfExperience when UserYearsOfExperience = null then null when UserYearsOfExperience between 0 and 1 then 29 when UserYearsOfExperience between 1 and 3 then 30 when UserYearsOfExperience between 3 and 5 then 31 when UserYearsOfExperience between 5 and 7 then 32 when UserYearsOfExperience between 7 and 9 then 33 when UserYearsOfExperience > 9 then 34 en

View Complete Post

More Related Resource Links

Truly Understanding View State

This article provides a detailed understanding of the ViewState.

view state vs request parameters


If  the view state is the data entered into the form fields then they are supposed to be available in the request parameters or request body. Then why would we need view state for?


View State Encryption


Hi All,

Why is it that I see the same hash value generated when I use different algorithms for viewstate encryption. I have added below lines to the web.config file

<pages viewstateEncryptionMode="Always"

Security Briefs: View State Security


Effectively managing user state in web applications can be a tricky balancing act of performance, scalability, maintainability and security. The security consideration is especially evident when you're managing user state stored on the client. Here's what you need to know about view state security.

Bryan Sullivan

MSDN Magazine July 2010

Bugslayer: Measuring the Impact of View State


Bloated view state can be a real performance bottleneck for your Web app, but it can be difficult to diagnose. John Robbins creates a handy tool that records and reports the view state size for pages in your ASP.NET applications.

John Robbins

MSDN Magazine November 2007

C++ at Work: Persisting View State Update, Using Managed Extensions in a DLL


This month marks the 11th anniversary of my column and the inauguration of a new title: C++ At Work. We're also adding a new bimonthly column, "Pure C++," by my pal Stan Lippman, one of the great C++ Masters.

Paul DiLascia

MSDN Magazine February 2005

ASP.NET 2.0: Speed Up Your Site with the Improved View State in ASP.NET 2.0


View state is a wonderful thing. It allows the ASP.NET developer to maintain state for server-side controls that are not form elements.Used judiciously, it can improve the user experience. But in the wrong hands, it can cause your pages to grind to a halt. The release of ASP.NET 2.0 will include a variety of improvements to view state that will make it easier to use and less likely to slow performance.

Fritz Onion

MSDN Magazine October 2004

Cutting Edge: The ASP.NET View State


In ASP. NET pages, the view state represents the state of the page when it was last processed on the server. It's used to build a call context and retain values across two successive requests for the same page.

Dino Esposito

MSDN Magazine February 2003

i need clear idea and explanation about view state


can any one please explaine me about view state property, i need the basic thing, what is it actually, and why we use, wthat is the use of it. and etc etc plsssssssssssssss

Msg 50000, Level 16, State 1, Line 34



I get the following error:

Msg 50000, Level 16, State 1, Line 34
An error occurred in the Microsoft .NET Framework while trying to load assembly id 65669. The server may be running out of resources, or the assembly may not be trusted with PERMISSION_SET = EXTERNAL_ACCESS or UNSAFE. Run the query again, or check documentation to see how to solve the assembly trust issues. For more information about this error:
System.IO.FileLoadException: Could not load file or assembly 'capsqlextensions, Version=, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An error relating to security occurred. (Exception from HRESULT: 0x8013150A)
   at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
   at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
   at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
   at System.Reflection.Ass

Msg 10301, Level 16, State 1, Line 1

Hi, I am trying to register Excel that should be located at: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 in order to: CREATE ASSEMBLY Excel FROM 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Microsoft.Office.Interop.Excel.dll' But there is no: 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Microsoft.Office.Interop.Excel.dll' Where could I find that? Regards, Jos

Msg 15121, Level 16, State 10, XP_Cmdshell - A call to 'CreateProcessAsUser' failed with error cod

I have the XP_cmdshell issues for the past two days in SQL2005 SP2 environment. There is a domain account with sysadmin privilege. I have created a proxy account and gave the execute privilege for xp_cmdshell. If i try to run the following commmand EXEC master..xp_cmdshell 'dir *.txt' Msg 15121, Level 16, State 10, Procedure xp_cmdshell, Line 1 An error occurred during the execution of xp_cmdshell. A call to 'CreateProcessAsUser' failed with error code: '1314'. But if i give sysadmin priv and then i try to execute. It worked. I cant give sysadmin priv so i m using a proxy account. Whether any one have solution for it.

mult level tree view

I have a dataset with 3 related tables. I can create a two tiered treeview but I don't know how to get the third level in? <TreeView Height="325" HorizontalAlignment="Left" Margin="12,8,0,0" Name="plTree" VerticalAlignment="Top" Width="380" Grid.ColumnSpan="2"> <TreeView.ItemTemplate> <HierarchicalDataTemplate ItemsSource="{Binding Path=ServiceLines}"> <TextBlock Text="{Binding Path=Service}" Padding="2" AllowDrop="True" /> <HierarchicalDataTemplate.ItemTemplate > <DataTemplate > <TextBlock Text="{Binding Path=ServiceLine}" Padding="2" AllowDrop="True"/> </DataTemplate> </HierarchicalDataTemplate.ItemTemplate> </HierarchicalDataTemplate> </TreeView.ItemTemplate> </TreeView>

Msg 8624, Level 16, State 13 - Internal SQL Server error.

Hi, I have a weird T-SQL 80 query full of nested subqueries full of aggregations tha thas been embedded in a view. if I do select * from the view I get: Server: Msg 8624, Level 16, State 13 Internal SQL Error.  If I run the same block of code from the query analyzer it runs fine. Also if I wrap exactly the same code in a SP it runs fine. I'm running this on a SQL Server 2000 Standard Edition SP4 8.00.2282. + I turned on the following Trace Flags: 3614, 9052, 9054, 9056, 9057, 9185, 9256. If I restore the same DB on a SQL Server 2005 and do the same select * it runs fine. So I'm getting the Error 8624 only on my SQL 2000 Standard edition  SP4 8.00.2282. Another thing I dont understand is also: why I can compile the view but if I try to visualize even the query plan I get the same error?!? Any suggestion will be appreciated. Thank you. Regards, Marco    

state machine workflow project creation error

Hi,   I have a dev environment which i had sharepoint 2007 and now i upgraded it to sharepoint 2010. Now when i try to create a state machine workflow project it gives me an error Object Reference not set to an object. I uninstalled Sharepoint extensions 1.3 (as i 64bit win2008 vm) and when i am trying to install it. In one of the installation screens where it asks for the port no  and the select the app pool it only shows the sharepoint central v3 app pool . i was expecting to have sharepoint 2010 product app pool in the drop down. I know that there should be a app pool on port 80. Since i upgraded sharepoint to 2010. I want sharepoint visual studio extensions 1.3 to point to sharepoint 80 app pool . Please can you tell me how i can do it.    

Server: MSg 17, Level 16, State 1 [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not e

Hi All, When we try to connect to a sql server 2000 using SQL server authentication, we are facing the below mentioned error msg. "Server: MSg 17, Level 16, State 1 [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist or access denied" But, once we connect to server using Windows NT login from the client machine, i.e., execute the below command in the run prompt and provide the credentials for windows login, we are able to connect to the server using sql server authentication(user name: sa) \\server_ipaddress\c$ When we went though some of the msdn links, found that windows firewall was the major cause. But, in the server 1. Windows Firewall is turned off 2. TCP/IP and NamedPipes are enabled 3. Default Port Number is 1433 Any user, who wants to connect to the SQL Server using SSMS, first have to perform a Windows NT login and then connect using SQL authentication.  Due to the above error, the DTS packages which are executing in a different server are getting failed. NOTE: Even after connecting to the server using Remote Desktop connection in a local machine, SQL authentication fails. Its manadatory to run the command \\server_ipaddress\c$ in each of the local machine. Any suggestion to resolve the above error is very much appreciated.   Thanks in advance, Raksha Hegde       
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend