Re: SQL CE basics

Tech-Archive recommends: Speed Up your PC by fixing your registry



Yes that's correct.


"Oliver Schenk" <oliver.schenk@xxxxxx> wrote in message
news:OxO5FGgLJHA.6000@xxxxxxxxxxxxxxxxxxxxxxx
To make the sample code compile with v3.5 compact edition I had to do the
following:


1. Use VS2008 instead of VS2005.
2. Include C:\Program Files\Microsoft SQL Server Compact
Edition\v3.5\Include in includes path.
3. Change include reference ssceoledb30.h to sqlce_oledb.h.
4. Change CLSID_SQLSERVERCE_3_0 to CLSID_SQLSERVERCE_3_5.


Does that sound correct for using SQL CE 3.5? I believe that I was unable
to select v3.5 when using VS2005 so I'm using VS2008.


Regards,

Oliver


Oliver Schenk wrote:
Thanks for that.

I found the Norwind database under:

C:\Program Files\Microsoft SQL Server Compact Edition\v3.5\Samples

But I don't see any code samples anywhere... were you just refering to
the database or code as well. Or do you mean the code that is within the
Online Books?

Thanks,

Oliver


Laxmi Narsimha Rao Oruganti wrote:
Also I suggest you to looking at Northwind OLEDB sample to get kick
started. Header files are not generally in class path so you have to
explicitly add to list of include directories to look out for compiler
to check.

Thanks,
Laxmi

"Ginny Caughey MVP" <ginny.caughey.online@xxxxxxxxxxxxxx> wrote in
message news:eyymqeTLJHA.5648@xxxxxxxxxxxxxxxxxxxxxxx
Oliver,

You can just copy the sdf file, or you can create one on the fly - it's
your choice. I agree that SQL CE is a good choice when you have 10000
rows to manage, and it supports access my multiple concurrent processes
as long as they are all on the same machine.

Here's a good source of info for native code developers:
http://nativemobile.blogspot.com/feeds/posts/default?alt=rss

Also check out Books Online:
http://www.microsoft.com/sql/editions/compact/downloads.mspx

--

Ginny Caughey
Device Application Development MVP


"Oliver Schenk" <oliver.schenk@xxxxxx> wrote in message
news:OIIt6vSLJHA.3808@xxxxxxxxxxxxxxxxxxxxxxx
Hi All,

I am not new to SQL and using SQL queries, however I am new to Windows
CE and using SQLCE 3.5. I have so far managed to install it and I can
add it to my operating system using platform builder and the component
catalog.

I have read a few things in the online books but nothing really
provides any clear examples with native win32 code. I'm struggling to
find sources that explain:

1. Can I just copy an .sdf file to the device? Or is it .mdf? Or do I
create one on the fly from my program.
2. Opening/closing a database.
3. Reading/writing queries to the database.

I tried including:

#include <sqlce_oledb.h>
#include <sqlce_err.h>

but compile complains that it cannot find sqlce_oledb.h. Not sure what
I have to do to get the compiler to find the .h file.


Basically I'm just looking for a "getting started" guide for SQL CE
3.5 and native Win32 programming.

I actually intend to access the database from real-time programs, but
I need around 10000 data points so someone suggested using SQL CE
instead of CEDB or EDB. Does that sound suitable or not?

All I really need to store is 10000 booleans and 10000 ints, maybe I
should just use an array? But the problem is it may be accessed by
multiple processes at the same time...and it needs to survive a power
cycle. I guess I could routinely write everything to a simple txt
file.

I'm very new to Windows native so bit of a steep learning curve there.
Not sure what the "preferred" way of doing things is.


Thanks



.



Relevant Pages

  • Re: CREATE AGGREGATE failed because type Concatenate does not conform to UDAGG specification due to
    ... Go to the Database tab and click on the browse button next to the connection string. ... In the New Database Reference dialog, enter the details for the database where you want to deploy the assembly and create the user defined aggregate. ... I'm trying to do some CLR integration with sql server 2005. ...
    (microsoft.public.sqlserver.programming)
  • CREATE AGGREGATE failed because type Concatenate does not conform to UDAGG specification due to meth
    ... Now register the assembly and the aggregate in the SQL Server database you want ... I'm trying to do some CLR integration with sql server 2005. ...
    (microsoft.public.sqlserver.programming)
  • Re: dbdebunk Quote of Week comment
    ... > a lot of really bad SQL programmers. ... But SQL does not have a pointer data type or the ... > being told to design a database. ... But why is little Cindy Lou Who employee ...
    (comp.databases.theory)
  • Re: DBMS and lisp, etc.
    ... Naively implemented with SQL, again for 10 ... (1 query for the initial orders, 1 query for each order for its ... soon as you upgrade to the SQL database. ... (eq (order-customer orderA) ...
    (comp.lang.lisp)
  • Re: dbdebunk Quote of Week comment
    ... > a lot of really bad SQL programmers. ... a surrogate key should support the primary key. ... But SQL does not have a pointer data type or the ... > being told to design a database. ...
    (comp.databases.theory)