.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

How to store more than 4k bytes of data in SQL CE 4?

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net

I need to store more than 4k of bytes in my SQLCE 4 database. How can I do that with the ASP.NET Web Pages 1.0?

1: The Microsoft.Data provider fails when I try to populate a parameter with more than 4k bytes.
2: Referencing SqlServerCe assembly and using SqlCeConnection/SqlCeCommand/SqlCeParameter throws exception:  SQL Server Compact is not intended for ASP.NET development.

How can I somehow map the generic DbType, which does not have NText as an option, to the ntext column in my database? (SqlCeParameter supports DbSqlType, which has ntext, but see problem #2)

View Complete Post

More Related Resource Links

Spider in .NET: Crawl Web Sites and Catalog Info to Any Data Store with ADO.NET and Visual Basic .NE


Visual Basic .NET comes loaded with features not available in previous versions, including a new threading model, custom class creation, and data streaming. Learn how to take advantage of these features with an application that is designed to extract information from Web pages for indexing purposes. This article also discusses basic database access, file I/O, extending classes for objects, and the use of opacity and transparency in forms.

Mark Gerlach

MSDN Magazine October 2002

SQL Server CE: New Version Lets You Store and Update Data on Handheld Devices


Handheld device users need to be able to synchronize with a main data store when it's convenient and, preferably, when the back-end database server isn't busy. SQL Server 2000 Windows CE Edition allows you to build a traveling data store that can be displayed and run on a variety of devices. SQL Server CE supports a subset of the full SQL Server package, and can be used as a standalone server or in tandem with SWL Server and IIS. The architecture of SQL Server CE, along with data manipulation, synchronization, and connectivity issues, are discussed in this article. Topics such as making your data public, choosing the right type of replication, and handling errors are also covered.

Paul Yao and David Durant

MSDN Magazine June 2001

Store Null Data In image datatype in sql server 2005



i wanted to store image in sqlserver database image field and i did. But now in some cases i want to store null value in that image field please let me know how to do this using file uploader.please give complete sample code.


How to store binary data as nvarchar(max)?

I’m trying to store a blob of binary data as nvarchar(max) and it gets truncated after just a few bytes. I wonder why and how can I prevent it. I don’t use varbinary(max) because I’m trying to keep existing DB schema intact. Current DB contains a huge chunks of text in nvarchar(max) column and I’m trying to compress (zip) this text and store it back to the same field to reduce DB size.   DB is accessed using Sync Framework (and Entity Framework) on the client side, so actual DB engine is SQL Server Compact 3.5 SP2   Thank you! KonstantinThank you! Konstantin

Unable to store combo box value to data grid view control

Hello,         I am using fw 3.5 SP1 with VS2008. I have bind my object collection with data grid view. I can see different values in combo box inside data grid view. But when I select any one value from combo box the selected value is changed to first value of combo box as soos as user leave the cell of the gird. Can anyone tell me where should I look for this problem so that my selected value remains same as user did select it.   Nilkanth Desai  

How do I get a filtered collection of MembershipUsers from a data store using custom profile propert

A portion of my web.config file:   <profile enabled="true" defaultProvider="AspNetSqlProfileProvider">      <properties>        <add name="FirstName" type="System.String" />        <add name="LastName" type="System.String" />        <add name="Age" type="System.Byte" />        <add name="Weight" type="System.Byte" />        <add name="City" type="System.String" />        <add name="State" type="System.Byte" />        <add name="RelationshipStatus" type="System.Byte" />        <add name="PostalCode" type="System.String" allowAnonymous="true" />        <add name="FavoriteURLs" type="System.Collections.Specialized.StringCollection" allowAnonymous="true" />        <add name="ProfilePhotoFullPath" type="System.S

SharePoint Designer 2010: Business data connectivity metadata store is unavailable

Running SharePoint Server 2010 RTM. Fresh install in production not via the wizard but a vanilla install and bringing services up one by one. Just brought up the Business Data Connectivity Service. Other services currently up are Managed Metadata Service and User Profile Service. Two web applications with services deployed to both web applications. The scenario below holds true when connecting to a site on either web application. 1) Open a site, i.e., root portal site, in SharePoint Designer 2010 2) Click External Content Types. Error returned: "The Business Data Connectivity Metadata Store is currently unavailable" is returned. 3) Click Ok then click New | External Content Type. Error returned "THe server was unable to process the request due to an internal error. For more information about the error, either turn on IncludeExceptionDetailInFaults...". The Business Data Connectivity Service status in Central Administration is Started. Any ideas?

MOSS 2007 : Data store missing in the middle of process

Dear Expert, My user always report that some data that have been key-in by them (sharepoint web form) was missing during the WF is routing to (verifier & approval). FYI the verifier & approval only have a permission as a "View" anybody here have a same experience with me?? Isit the issue is because of sharepoint itself or human (i've try to create dummy record but work fine) ??

Urgent: The business data connectivity metadata store is currently unavailable SP designer

Hi,   I am getting the following error when runnind SP designer and referencing external content types.   The BDC service is running on the server, however if I click the link to configure the service I get:   The server did not provide a meaningful reply; this might be caused by a contract mismatch, a premature session shutdown or an internal server error. and in the event log: The BDC Service application BDCTest is not accessible. The full exception text is: The server did not provide a meaningful reply; this might be caused by a contract mismatch, a premature session shutdown or an internal server error. An exception occurred when trying to issue security token: The server did not provide a meaningful reply; this might be caused by a contract mismatch, a premature session shutdown or an internal server error.   Can anyone please help?        

What's the best way to store Data from DataBase like XmlNode... Application vs Cache


 Hello, i am building an N-tier application now i want to store Data(like XmlNode) that is common to all users ..

now i thought using Application to hold the data but my data lays in the BLL tier which is an Class Library project and i can't store any datain there for example :

HttpApplication MyApp=new HttpApplication();



My question is what is the best way to store Data (not small data like user name etc..) is it Application? orCache?

i would like a small example within a ClassLibrary project...


Variable to Store temporary page data


I'm working on a web page that is going to be used to enter data into a database. The page is going to be dynamic in that the user has the ability to add a row to the table with the same fields, ie lname1, fname1, mi1 then lname2, fname2, mi2

I'm wanting to use a variable to keep track of how many lines there are so that when I generate the added line I am creating a new field with the ID of lname+# . Whats the best way to do this, a global variable, session variable? As side note, first time programming in .Net or C# so I apologize for my lack of knowledge.

share data in two table using store procedure


i want to update one table columns using 2nd table value like this:

ALTER procedure [dbo].[INS_Profile_intotempfrommaster_delete ]
@UserID int

select @OrgnisationLink=OrgnisationLink,@F_Name=F_Name,@L_Name=L_Name,@EmailID=EmailID,@EncryptedEmailID=EncryptedEmailID,@Address=Address,@City=City,@State=State,@Pincode=Pincode,@Designation=Designation,@P_Number=P_Number,@M_Number=M_Number,@OrgnisationProfile=OrgnisationProfile
from t_usermaster where UserID=@UserID

update t_usermaster_mirror
set OrgnisationLink=@OrgnisationLink,F_Name=@F_Name,L_Name=@L_Name,EmailID=@EmailID,EncryptedEmailID=@EncryptedEmailID,Address=@Address,City=@City,State=@State,Pincode=@Pincode,Designation=@Designation,P_Number=@P_Number,M_Number=@M_Number,OrgnisationProfile=@OrgnisationProfile


but i am getting error

Exception Details: System.Data.SqlClient.SqlException: Procedure or Function 'INS_Profile_intotempfrommaster_delete ' expects parameter '@OrgnisationLink', which was not supplied.

plz reply me how can i do this

How To Store Data in Mobile


Hello all,

I am Developing a mobile Application by using .Net 

the Application having forms which are having different options like textfields and radio buttons.date,...etc

Now, After filling the data into those forms then, I want to Store that data into Mobile internal or external Memory

Later when the GPRS connection is available then, I want to retrive that data and want to send it to a server by using http connection or something else

Any body knows Help me in this

Thanks in Advance

Error converting data type nvarchar to numeric in Store Procedure execution



When I execute a Store Procedure via 'EXEC sp_XXX @p1, @p2' I'm getting this error 'Error converting data type nvarchar to numeric'.

After diggin into the TSQL code I have found that there's a field (type: nvarchar(200)) breaking the execution and resulting on the error.

If I query the table and the specified field with the same parameters as the Store Procedure the results are ok! If I execute the same code as the Store Procedure with the same parameters values the results are ok. The error only happens when executing the Store Procedure.

Any idea ?

Thanks in advance,

Gustavo Brian


If I cast the field to a smaller size value, as nvarchar(80), it works, but of course with data truncation.


What new in XML Data Type if we can store data into separate columns?


Being new to XML Data Type I want to know what is the need to store our data in XML format if we can save it into separate Columns?

1. Is this practice being widely using in creating databases and maintaining information more efficiently?

2. Does this process follows Normalization rules?

3. What are the pros & cons?


how to store rich text box data in sql 2005




i am using rich text box controal please tel me how to store rich text data in sql 2005




How to store arabic data in sqlserver?


Hello Experts,

i am trying to store the arabic data which is entered by user in textboxes in sqlserver (2000 as well as 2005).

i wrote the insert command as

"insert into Tbl_arabic (valA, valB, valC) values (N'" + textBox1.Text + "',N'" + textBox2.Text + "',N'" + textBox3.Text + "')";

but data is storing all ??????? only.

i tried by changing the column collation to 'Arabic_CI_AS' but problem not solved.

any help would be really appreciated.



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