Setting Up Code Library To Run Either SQL Server Express Or Compact 3.5
Feb 21, 2008
I am not sure if this should go here it is a bit of a mixed bag, sorry if it's in the wrong spot.
I am interested to know what ideas people might have in relation to the best way to structure/setup up an app that can connect to either an SQL Server Express DB or a Compact 3.5 DB. I have a small app that can be networked but a lot of people wont want a networkable version so I dont want them downloading an app that is 4mb but requires a 35mb SQL Express install just to get it to attach to what amounts to a local DB.
Both the System.Data.SQLClient and System.Data.sqlce namespaces include classes that share at least some (I haven't checked them all) classes that inherit from the same base class i.e. SQLConnection and SQLCeConnection both inherit DBConnection from System.Data.Common. so I am wondering if there is a tricky way that I can reduce my overall code overhead (mainly things like if statements to check which DB connection we want) by up casting both connections and managing them as DBConnections but at this stage I cant come up with one.
An in important point with this is that I intend to write SQL statements that are compatable with both SQL Express and SQL Compact, my DV structure is sufficiently simple enough that I can put up with the odd "wordy" SQL statement in favour of trying to use stored procedures and views in Express and then not being able to use them in Compact.
Cheers
Rob
View 1 Replies
ADVERTISEMENT
Oct 18, 2007
Hi!
I have a problem changing the language setting to swedish on sql server 2005 compact edition. The thing is that I'm using a language dependent format: '1998-02-28 14:23:05' (Numeric) when saving and I rather don't want to change this format, because it's a lot of work. (The default setting on the database seems to be us-english, which has the format month-day-year and there by gets wrong for me).
As I understand, this is detemined by the language settings on login. So I set this by using the 'locale identifier' (sv-SE) in the connection string to the CE database, but when I try to save the data, the datum is still interpreted as us-english format.
(The application I'm running have been upgraded from sql compacte edition 2.0 where this worked just fine, though without specifing any language settings in the connection string.)
Appreciate any help!
View 2 Replies
View Related
Sep 22, 2015
I have a SSRS report that uses a custom library. The custom library returns a string values, and I have tested this with a windows application.In the SSRS report. I have set the expression value for a text box as  =CodeReportingLibrary.CodeReportingFunctions.GetImage(1232)
However, when i preview the report the text box value shows as #ERROR. I checked the error list and I get a warning message : Warning 1 [rsRuntime ErrorIn Expression] The Value expression for the textrun ‘Textbox5.Paragraphs[0].TextRuns[0]’ contains an error: Attempt by security transparent method 'CodeReportingLibrary.CodeReportingFunctions.GetReferenceImage(Int32)' to access security critical method 'Microsoft. TeamFoundation. Client. TfsTeamProjectCollection..ctor(System.Uri)' failed.  Assembly 'CodeReportingLibrary, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' is partially trusted, which causes the CLR to make it entirely security transparent regardless of any transparency annotations in the assembly itself.  In order to access security critical code, this assembly must be fully trusted.
I have updated the rssrvpolicy.config in ReportServer folder, to include my custom dll.
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust"
Name="CoDeMagSample"
Description="CoDe Magazine Sample. ">
[code]....
View 4 Replies
View Related
Aug 20, 1999
Check out www.sql-server.co.uk.
This site offers a growing code library; tutorials & the full FAQ from Neil Pike SQL Server MVP in an easily readable search/review format.
Also a possible UK user group is being formed, initially information for this will be passed through this site - register there.
View 1 Replies
View Related
May 12, 2006
In SSIS can one create €œuser defined functions€? €œsubroutines€? and put them in the SSIS designer for other developers to use?
TIA,
Bill
View 12 Replies
View Related
Feb 27, 2008
I get the error above when I do the following.
Using VS 2008 I got a Windows Smart Device project targeting WM6 Standard and using .NET CF 3.5.
I add a new database file = creating an empty Compact 3.5 database (creates an sdf-file in my project).
Then create an empty dataset in the wizard (creates an xsd-file in my project).
Then I add a couple of tables in the database.
After that I want to use my earlier created dataset.
I mark the xsd-file and looks in Poperties.
I get the error when I try to change Custom Tool value from 'MSDataSetGenerator' to 'MSResultSetGenerator'.
Why????
View 1 Replies
View Related
Jun 11, 2015
I have a requirement in which i have to create a custom .net class library for Ex:-I retrieve password(s) from a thrid party component. Below is what i am doing.
(1) Created a custom class library which reads a custom .xml file from a drive Ex:- "D:MyAppMYAppCofig.xml" and sets to my properties of my custom class library and inside it i created an instance of third party component's class and passed these values. Since i need to use this .net custom class library both in web and ssis/database side i am using this custom .xml file.
(2) After validating passed data (properties set in custom .net class library) the thrid party component instance object created in my custom .net class libraty returs a password to me own custom .net class libray.
(3) This password I use in my web app for connecting to database. This code is working fine.
(4) My question is how to execute a custom .net class library code through ssis and to use the my same custom .net class library and pass the password to my SSIS component / taks so that that code block also uses the returned password to connect and do any needed tasks? In other words how to use custom .net class library from SSIS.
My Environment is as follows:-
SQL Server is : 2008 R2
VS.NET 2013
View 5 Replies
View Related
Mar 3, 2007
Every time I modify my SQL Server database, it grows by about 1 MB. I haven't added any data, in fact have reduced column sizes. Is there a utility that will compact the database and return it to a more manageable size?
View 2 Replies
View Related
Apr 25, 2008
Well, what I want is to be able to do some tooling on a database (.sdf) on my WM5 device using C# Express 2008.
The problem is that when I select the "Tools/Connect to database" option, I choose my data source to be "Sql Server Compact 3.5" in the next screen, and when I press Continue, I am taken to the next screen, and here I cannot select the "ActiveSync connected device" in the "Data Source" section...it is disabled. The only option is selecting "My computer"...but I do not need that.
Is there something I need to install in order to activate that option?
Thanks,
Adrian
View 4 Replies
View Related
Jul 26, 2007
Hello,
I just installed SQL Server Compact Edition, since I am considering using it instead of SQL Server Express for a local database in my application. The documentation mentioned that I could use SQL Server Management Studio Express to connect to the Compact Edition and create and manipulate databases.
To try to connect, I run Management Studio and bring up the "Connect to Server" dialog. Unfortunately, the pull-down list of "Server name"s does not include the SQL Server Compact Edition server. I do not know how to type in the server name manually, so I cannot connect.
To install Compact Edition, I downloaded it and ran "SQLServerCE31-EN.msi". This installed, and I assume registered, a number of DLLs in "C:Program FilesMicrosoft SQL Server Compact Editionv3.1".
Is there perhaps an additional step that I left out to complete the installation?
Might I need an upgrade to some other components? My Management Studio Version is:
- Microsoft SQL Server Management Studio Express 9.00.2047.00
I would appreciate any help you can provide.
Thank you,
WTW
View 7 Replies
View Related
May 7, 2008
Hi all
Which tool can I use for structure editing of SQL Server Compact 3.5 databases? I'm installed SQL Server Compact 3.5. I have SQL Server Management Studio Express which was installed with SQL Server 2005 Express. Unfortunately this SSMS can create and open only 3.1 databases.
View 5 Replies
View Related
Feb 13, 2007
Hi,
I am very new to SQL Compact. I am trying to create one database which can work on the desktop application and also on a pda application. I want to create the database but I am unable to start without Management Studio. Can you guide me to the right tools so that I can create database, view it and manage it use something like Management Studio Express.
Also one more question is if my database needs to be at both places on the desktop and on pda how can i synchronise them. PDA will take using c# application data from RFID scans and then i need to sync that database on the desktop so that reports and other info can be generated from the desktop c# application. How to do this?
Please can you guide me to any webcasts or labs so i can clarify my doubts about the design.
Regards
Trushar
View 5 Replies
View Related
Jan 18, 2007
Hello,
i don't know if it was mentioned before, but i solved the issue that Microsoft SQL Server Management Studio Express won't show the option to create/modify a sql compact database by installing not this Version:
Microsoft SQL Server Management Studio Express
Date: 19.04.2006
http://www.microsoft.com/downloads/details.aspx?FamilyID=c243a5ae-4bd1-4e3d-94b8-5a0f62bf7796&DisplayLang=en
but this one:
SQL Server Management Studio Express Service Pack 2 €“ CTP-Version
Date: 19.12.2006
http://www.microsoft.com/downloads/details.aspx?FamilyID=ccbda432-8ecf-4c82-bdef-b575eaf07f55&DisplayLang=en
hope this helps.
Nihat
P.S. i'm curious if anybody else had the same issue, caused of using the wrong Version of SSMSe?
View 1 Replies
View Related
Apr 8, 2008
Hello,
I am a SQL novice and I installed SQL Server Compact 3.5 and wanted SQL Server 2005 Express instead. I uninstalled the Compact version, but when I try to install Express, it still just installs the regular SQL Server 2005 Configuration tools. I have went so far as to uninstall all my Visual Studio Express apps and SDKs and even the .NET 3.5 framework, but it WILL NOT install the SQL Server 2005 Express. I am running 32-bit Windows Vista Home edition.
Please help.
Thanks.
View 1 Replies
View Related
Jan 16, 2007
Hello ,
Is possible to specify reationships between tables on SQL Server Compact Edition database in Management Studio Express ?
I can connect to database file , add tables, add data , but I dont't found the right methot to specify reationships as with SQL Server Express.
Any ideas?
View 5 Replies
View Related
Jan 9, 2006
I am currently working in VB.NET with SQL Mobile 2005. I am trying to compact a database, .sdf, using the SqlCeEngine Object compact(connectionstring). When I use this code to compact a small database, only about 300KB, it returns okay however when I try to compact a larger database, about 9MB, it returns with a SQL Error Code: 0, "The operation completed successfully" however with no compacted database. The code works however it only seems to work for smaller databases. Does anyone have any ideas on how to correct this error or tell me why it returns with that type of error.
Snuggs
View 8 Replies
View Related
Aug 16, 2007
How do I find out what port my server is listening on? I'm trying to connect to my database locally to install Vignette Portal. And no matter what I try, nothing works. I think it is listening on port 1433. But there is no way to be sure. Should something come up if I hit localhost:1433 in my browser? Because, when I do that, nothing comes up.
Please help.
View 1 Replies
View Related
Nov 3, 2007
Hello,
I'm trying to follow a sample from microsoft for Using SQLXML Bulk Load in the .NET Environment
In the sample c# console app. it says to select add reference then In the COM tab, select Microsoft SQLXML Bulkload 4.0 Type Library (xblkld4.dll) and click OK.
The problem I have is I cannot find the library or the xblkd4.dll file on my pc.
Does anyone have any suggestions? Any help would be much appreicated.
Thanks
Karl
View 5 Replies
View Related
Nov 29, 2005
Hi,I had the SQL Server Express installed on my desktop and it was working just fine. Now, I upgraded to .Net 2.0 and I had some problems with the SQL Server Express just like in post http://forums.asp.net/1070169/ShowPost.aspx.These problems were solved by using a cleanup tool but now when i try so setup the SQL Server Express 2005 i get the error:SQL Server Component Update will install the following components for SQL Server Setup:- (ok) Microsoft SQL Native Client- (error) Microsoft SQL Server 2005 Setup Support FilesErrors occurred during the installation:Error 1603 installing Microsoft SQL Server 2005 Setup Support Files.See log file for more detailed information.Fatal error during installation.The log file as lots of information such as:Product : Microsoft SQL Server Setup Support Files (English) Product Version : 9.00.1399.06 Install : Failed Log File : C:Program FilesMicrosoft SQL Server90Setup BootstrapLOGFilesSQLSetup0010_WS10170_Support.log Last Action : InstallFinalize Error String : The installer has encountered an unexpected error. The error code is 2908. Could not register component {1F3316BE-825B-4390-A9D2-AF3EECCAE9F6}. Error Number : 2908 -------------------------------------------------------------------------------- WS10170 : There was an unexpected failure during the setup wizard. You may review the setup logs and/or click the help button for more information. Can someone please help me on trying to avoid format the desktop.Thanks,Stromberg
View 2 Replies
View Related
Apr 19, 2007
I am having a nightmare of a time with my Sql Server 2005 Express. My computer crashed on Friday the 13th - of course. I saved all my files onto another drive and wiped out C: I brought everything back in but I started a new file for my Visual Basic projects. After asking questions I found this was a major no-no So I brought my original folder back in. This solved some of my problems I was having with Visual Studio and Visual Web, but I am continuing to have problems with Sql Server. I will explain these two problem they may be related, I don't know. When I run my Visual Website on a server I get this message:
An attempt to attach an auto-named database for file(then my file name)failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.
And my second problem is when I attempt to run Sql Server Management Studio Express I get this error message:
There is no editor available for (then my file name) .mdf
Make sure the application for file type(.mdf)is installed.
View 4 Replies
View Related
Mar 21, 2007
During an install of SQL Server 2005 Express setting the sa password does not work consistently. The install is being run as administrator and I am using an .ini file to pass the settings,
SECURITYMODE=SQL
ADDLOCAL=ALL
SQLBROWSERAUTOSTART=1
SQLAUTOSTART=1
INSTANCENAME=DBSERVER
SAPWD=Westtech#1
and while most times it works correctly, occasionally, maybe 4 out of 10 times it fails to set the password and I have been unable to find any warnings or errors in the logs it generates.
We are coming up on release and this is causing us some real problems. Does anyone have any ideas, something I could look at?
Thank you,
Kathy Mook
Westbrook Technologies, Inc.
View 6 Replies
View Related
Nov 19, 2007
I am working to develop an application using dotnet framework 2.0 that requires loading tab delimited text file (generated on each user action) in to table of SQL Express database. I am thinking to use SSIS library (Managed DTS) to call my SSIS package from within my application to load this data on each user transaction. This should be noted that I am not hosting my packages in to SQL Express.
Microsoft allows redistribution of SQL Express for free. Do I need any SQL Server or any other type of license for using SSIS library from my application?
-Faisal
View 5 Replies
View Related
Mar 21, 2007
When installing SQL Server 2005 Express and using an .ini file that looks like this,
SECURITYMODE=SQL
ADDLOCAL=ALL
SQLBROWSERAUTOSTART=1
SQLAUTOSTART=1
INSTANCENAME=DBSERVER
SAPWD=Westtech#1
sometimes the sa password is set correctly, while other times it is not. There does not appear to be any particular environment or system setting when it fails vs. when it works.
We are coming up on a release date and this is causing us a serious problem. Can anyone help?
Thank you,
Kathy Mook
Westbrook Technologies, Inc.
View 1 Replies
View Related
Aug 3, 2004
Hey everyone. I'm trying to set up the free microsoft sql 2000 server desktop engine so I can create databases in visual basic using ADO. I would like to do this locally, not over the network or anything. I'm on windows 98. the steps I took are:
1. I downloaded the ms 2000 server desktop engine (msde2000a.exe)
2. Downloaded the .net framework and installed that (version 1.1)
3. Extracted the desktop engine setup to a directory
4. browsed to that directory in DOS prompt and typed 'setup SAPWD="AStrongSAPwd" ... and then it installed
5. opened ODBC Data sources in the control panel
6. in the user DSN tab i highlighted "MQIS" and then pressed 'configure'
7. Pressed 'next' with the default values for all the fields: (name=MQIS, Description=SQL Server' Server=(local) )
8. with the radio button "with sql server authentication.." selected i click on 'client configuration'
9. after i click on that a box comes up saying 'add network library configuration'.
so.. i'm confused on this part.. What should i put for 'server alias' and 'server name'? I want to do this locally. I tried putting my local IP address and the word (local) but after i press 'OK' and then 'Next' (in that previous window that displays the client configuration button) i get an error that says:
Connection failed:
SQLState: '01000'
SQL Server Error: 10061
[Microsoft][ODBC SQL Server Driver][Shared Memory]ConnectionOpen (Connect())
Connection failed:
SQLState: '08001'
SQL Server Error: 17
[Microsoft][ODBC SQL Server Driver][Shared Memory]SQL Server does not exist or access denied
So.. how do I set up my computer to be able to use the engine locally? I have the vbcode I want to work. It consists of creating a database using the "provider=SQLOLEDB..." line. I can submit the code if anyone wants to see. Any help would be greatly appreciated. Thanks!
View 2 Replies
View Related
Mar 26, 2008
Ola,
I'm creating a report that contains 3 groups. The thing I want to find out is how can I change the toggleitem of a group, based on a value? Here is an example:
Invoice
regNumber
task
details
details
details
What I want is to switch the toglleitem of details to regnumber if task.value = 0
can it be done?
thx in advance
View 1 Replies
View Related
Sep 12, 2007
Hi
We are checking VB 9 (Orcas).
we connected to database created under with sql server 7. with this code
Public cn As New ADODB.Connection
Public Sub OpenDB()
cn.Open("Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial catalog=Reservation;Data Source=.")
End Sub
this code worked well.
we know sql7 is not compatiable with vista. please tell us how to connect it wiith sql2005 . we downloaded orcas express edition beta. we created a database also. please let u know how to connect with Microsoft SQL Server Compact 3.5 (.NET Framework Data Provider for Microsoft SQL Server Compact 3.5).
Rgds
Pramod
View 7 Replies
View Related
May 5, 2008
Hello,
we've got a SQL Server 2005 which replicates with an SQL Server Compact 3.5. Every 10 to 20 synchronisations we're getting the error mentioned above. A Soft reset of the device helps to make the synchronization working again.
Why is this error happening and how can we resolve this?
BTW, we've also running system that replicates with an SQL Server Compact 3.0 without having this problems.
Thanks,
Markus
View 1 Replies
View Related
May 29, 2007
Hi all,
I have a database name MyDatabase (SQL Server Express Dabase File). Is there anyway that I could convert it to SQL Server Compact Edition File?
By the way does anyone here got any problem with programming in SQL Server Compact Edition? It troubles me.
Thanks,
bombie
View 6 Replies
View Related
Nov 28, 2007
I've been reading some forums and I'm not able to get this to work. Basically I'm using an Oracle DB source and trying to import data into SQL server 2005. I guess the best connections to use are OLE DB.
Here are my current connections:
Source: Native OLE DBOracle Provide for OLE DB
Destination: Native OLE DBSQL Native Client
I'm running SP2 of SQL 2005.
Now, the issue is I'm not getting the code page stuff correct. In the data flow I'm just doing a OLE DB Source to SQl Server Destination. I'm not doing any transformations (I'm hoping to avoid doing that).
I'm getting an error:
[OLE DB Source [1]] Warning: Cannot retrieve the column code page info from the OLE DB provider. If the component supports the "DefaultCodePage" property, the code page from that property will be used. Change the value of the property if the current string code page values are incorrect. If the component does not support the property, the code page from the component's locale ID will be used.
I'm looking at how to set the DefaultCodePage property in various forums, but nowhere does it say exactly how to do this. I've tried changing the "Extended Properties" and added AlwaysUseDefaultCodePage=TRUE in there, but that doesn't work. I've tried changing the Locale Identifier to 1252 that doesn't work. I've tried a combination of the two, doesn't work. Can somebody tell me two things:
1. what's the best/fastest/industry used method to get data from Oracle into SQL server via SSIS (please include the type of connections).
2. How the hell do you set the DefaultCodePage property. I would love a screenshot on this one as well.
Thanks,
Phil
View 3 Replies
View Related
Apr 29, 2008
How to you create a database and set it size usings code?
I know CREATE DATABASE SUPPLIES but how do I set it to a max of 100 mb with no autogrowth using code?
View 7 Replies
View Related
Mar 7, 2007
Hi all,
I'm a newbie to Reporting Services so please forgive my ignorance...
I've recently installed SQL Server Express 2005 with Reporting Services on my Vista Business Notebook (with no network connections) and have installed VS C# Express as well as the Business Intelligence Studio to create reports.
My C# application can connect to SQL Server fine, however, the reports I created with Business Studio refuses to deploy to the server due to the following reason:
"The permissions granted to user 'localhostJenny' are insufficient for
performing this operation".
I find this odd as I've been able to deploy reports on my other Windows XP machine (with SQL Server Express) no probs at all. Additionally, I cannot see the 'Site settings' link within Report Manager (Web) that I'd normally get with an admin account (i.e. on my Win. XP machine). Various sources indicate that my account has insufficient access rights to view this.
Having browsed through seemingly endless blogs and forums, I suspect that my local account has not been configured to access the Report Manager web client to publish, manage and administer the site.
I have tried the surface area tool for SQL Server, but I suspect that this is relevant only to SQL Server DB access and management. Adding an administrator here does nothing.
The question is, how can I grant access to myself (local account) to allow me to publish reports via business studio, and at the same time - administer Report Manager Site Settings - on my vista notebook??
I would be extremely grateful for any help on this matter - I've tried ceaseless reinstallations, but to no avail!
Many thanks in advance,
Jenny
View 5 Replies
View Related
Apr 18, 2006
Hi,
I was wondering if anybody could advise on source code control for SQL Server express, for the table schema and stored procedures?
I currently use Sourcesafe V6 to work with visual studio 6 and 2003 (although it isn't integrated in 2003), and wondered if that can be used?
Any suggestions would be greatly appreciated, as I see this as a disaster waiting to happen!
Thanks in advance.
Mark
View 4 Replies
View Related
Feb 11, 2007
Hi,
I have an application where I need a desktop Application to manage the data and I have PDA application which talks to RFID and gathers the data. I am a bit confused if i can have only one database which can work both on PDA and Desktop. Can you please help me decide if i should use compact or express for this purpose. Also I might have to use both compact and Express but is there a way to have common database for both where they can be replication and easily synchronised.
Help is much appreciated.
Regards
Trushar
View 3 Replies
View Related