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


Top 5 Contributors of the Month
Jean Paul
satyapriyanayak
SP
Ashutosh Jha
Simon Robert VoIP
Post New Web Links

Access Database through WCF REST

Posted By:      Posted Date: October 11, 2010    Points: 0   Category :ASP.Net
 
 


hi,

i created a service like this

  [OperationContract (Name = "GetAllCustomer")]
        [WebInvoke(ResponseFormat = WebMessageFormat.Json,
            BodyStyle = WebMessageBodyStyle.Wrapped,
            UriTemplate="/View/Data?format={fr}",
            Method="GET"
            )]
        Customer[] GetAllCustomer();


 public class Customer
    {
        [DataMember]
        public int CNo { get; set; }
        [DataMember]
        public string CName { get; set; }
      }


  and access my db in service.svc.cs

 List<Customer> lstEmp = new List<Customer>();

            

 String connString = ConfigurationManager.ConnectionStrings["connWebOrdering"].ConnectionString;
            SqlConnection sqlConn = new SqlConnection(connString);
            sqlConn.Open();

           SqlDataAdapter da = new SqlDataAdapter("Select [cid], [cname] from [CustomerDB].[dbo].[contact] ", sqlConn);
            DataSet ds = new DataSet();
       &


View Complete Post


More Related Resource Links

Database Access Using SOAP and REST Web services

  
Hi Guys, Can anyone post the links regarding DATABASE ACCESS USING BOTH WEB SERVICES. How to query the database using the web service. Suppose i have SQL statement like " Select empID,empName,CName from employee,company where empID=CID;".  How to  send this sql query to database server using REST and SOAP web Services?  Thank You

Store and Display Images from MS Access Database Using C#

  
There is only the difference of coding syntax to stream the binary data of image content type to upload it into MS Access Database using C#/VB in ASP.Net 2.0

Namespaces required:-
using System.Data.OleDb;

OleDb is used to connect the web site forms with MS Access Database using Microsoft.Jet.OLEDB.4.0

ASP.Net Upload Image to MS Access Database

  
As you learnt from the previous articles to upload image to the SQL Database in ASP.Net 2.0 and stream that image into the memory to retrieve it from the database and display it on the web page. In this article you will learn how to upload images to the MS Access database in ASP.Net 2.0

First of all create an Access Database and place it in the App_Data folder of ASP.Net web site project. Then create a table "tblImg" with the following fields:

How to access a new database ( which i created ) in isqlplus ?

  

Hi.,

I created a new database with the help of Database Configuration Assistant !

I created with the scott account

Now i'm not able to connect to the database with the connect identifier with the scott account

The error i get is.,

ERROR - ORA-12154: TNS:could not resolve the connect identifier specified.

Plz help !



Under the Table: How Data Access Code Affects Database Performance

  

In this article, the author delves into some commonly used ways of writing data access code and looks at the effect they can have on performance.

Bob Beauchemin

MSDN Magazine August 2009


SQL and Outlook: Enable Database Access and Updates Through Exchange and Any E-mail Client

  

Using Microsoft technologies, you can insert, edit, query, and delete database entries using any e-mail client such as Hotmail, Outlook, Yahoo, or even WAP phone. While e-mail is certainly a powerful and widely used tool, it is usually not integrated with an application for performing any tasks other than sending reminders. The application scenario described here, an e-mail-based SQL update program, uses a simple data model; however, this solution will apply to any data model that you are working with. It will also eliminate the need for complex n-tier Internet applications and serves as a low maintenance solution for providing data access.

Alok Mehta and Daniel Williams

MSDN Magazine January 2002


Upsize Your Database: Convert Your Microsoft Access Application to Take Advantage of SQL Server 7.0

  

What if you need to convert an existing Microsoft Access 97 database application into a true client-server application that is based on a SQL Server back end? If you know a little about Visual Basic and SQL Server, it's easy to make your app take advantage of the power and scalability provided by SQL Server 7.0. Using some concrete code examples, this article takes you step by step through converting the native Jet queries in your Access application into stored procedures and pass-through queries that SQL Server can use. You'll also learn how to pass on parameters when your client-server app calls these SQL Server stored procedures and queries.

Michael McManus

MSDN Magazine June 2000


access Oracle database

  

Pre- .Net Framework 4.0 supported using Oracle.DataAccess.Client, using Oracle.DataAccess.Types, System.Data.OracleClient, OracleDataReader, OracleConnection. What are the equivalents in .Net Framework 4.0? Does it require any download?

Thank you.


How to get access to content database after server hardware failure

  

Sharepoint server 2007 and remote sql 2000 SP4 database, after ShraPoint server crash only content databases are available and intact. Trying to restore from backup fail, stsadm -o restore says that not valid backup is available on path. How to get access to available content database using a new installation with same server name, ip address and partitions configuration. How to recover site with content databases information.

Regards, thanks for help.


Victor Naranjo MCSE + Security MCSA + Security MCSE + Messaging MCSA + Messaging ITIL Certified Comptia Security+

How to check if record is added in access database

  

Hi,

I'm trying to put a registration page together in Visual Web Designer.

I would like to send a confirmation Email after someone is leaving his registration data and pressing the INSERT button.

The key fields in my database are: Email, Name, Surname, Address

Before I send the confirmation Email I would like to check if the email value entered in the form is realy added to the database.

Please for help in this matter. I was copy past already some C code in my page, therefore it will be fine if the code can be in C.

Again, I need help to:

- checking if record is realy added to database after pressing INSERT button

- setup the confirmation Email


Thank you in advance.

Frenkie


Errors in the back-end database access module. OLE DB reported an overflow of the data type for colu

  
Getting an error when processing a dimension, Errors in the back-end database access module. OLE DB reported an overflow of the data type for column 0. Errors in the OLAP storage engine: An error occurred while the 'xxxxxx' attribute of the 'Dim XXXXXX' dimension from the 'XXXXXXX' database was being processed. Content of this dimension is very similar to one that is processing no problem. The content of the dimension is one field only of type date.  The original content was imported through SSIS from a DB2 database on an iseries machine.  Thought a first the issue was because of the data contains some null values but the dimension the process OK also has some null  values.  The dimension that processes ok is also a single field of type date. Any help greatly appreciated, Roscoe

Access to database

  
i have a unique requirement where the windows login or SQL login to have permission to the database satisfying following conditions.   1) Should not be able to alter the existing tables under DBO schema. 2) Should be able to INS / UPD / DEL / SEL data in all tables ( DBO Schema or TMP schema ) 3) Should be able to create tables using TMP schema only. ( New schema name is TMP ) 4) Should be able to create stored procedures, functions, views using DBO and TMP schema.   Appreciate if anyone can come up with a solution using schema's and roles.   Thank You So much. aroon

Remote Data Access encountered problems when opening the database.

  
Hello,   I have some toubles with SQLCERemoteDataAccess   The exceptions are thrown on rda.Pull("Article", "Select * from Article", _ rdaOleDbConnectString, _ RdaTrackOption.TrackingOnWithIndexes, _ "ErrorTable")   with follow parameters : rdaOleDbConnectString = "Data Source=MyServeur;Initial Catalog=BddClient;User Id=admin;Password=admin;" InternetURLString = "http://112.86.96.120/Sync/sqlcesa35.dll"; LocalConnectString = "\\BACKUP\\AppliClient\\Bdd.sdf"     And the followinf error : Error Code: 80004005 Message : SQL Server Compact encountered problems when opening the database. [Internal Error Number =0, Internal Error String = ] Minor Err.:28559 Source :Microsoft SQL Server Compact   Error Code: 80004005 Message : Minor Err.:0 Source :Microsoft SQL Server OLE DB Provider My CE database file Bdd.sdf exist on pocket pc, and I access to the sqlcesa35.dll with IE. The server is a Windows Server 2003 SP2 using SQL Server 2005.   Thank you in advance

access the SqlCE database from desktop pc

  
Hello,   I want to access the SqlCE database from the stand alone desktop application. DB is exist in the windows mobile. when i  connect the device to PC then i want to open the database and copy all the records to my desktop application database (access or sql server). Please suggest is it possible ? Thanks~Khatri Mitesh khatrimitesh@hotmail.com Software Developer Rajasthan-India http://www.youtube.com/watch?v=-oJaaPCrk3Q
Categories: 
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