Re: renaming a table
- From: "Rob C" <RobC@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 17 Aug 2005 15:21:02 -0700
Thanks Darren & Joao for your responses.
I ended up doing what Darren had suggested. I create a temp table, check
for data and then replace the main table if it succeeded.
regards,
-Rob
"Darren Shaffer" wrote:
> or, rather than renaming tables, create an inbox table each time, RDA pull
> to that,
> if it succeeds, truncate all rows in your target rable, copy the inbox rows
> to the target, and drop the inbox. if RDA pull fails, drop the inbox and
> try again.
> --
> Darren Shaffer
> ..NET Compact Framework MVP
> Principal Architect
> Connected Innovation
> www.connectedinnovation.com
>
> "Rob C" <RobC@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
> news:4FCF93DD-C131-4DB1-AE10-5D11EB199584@xxxxxxxxxxxxxxxx
> >I am using RDA to download a table of staff records from a SQL Server Db to
> > my SQL CE database. My problem is that you have to drop the existing
> > table
> > first. If I do that and the download fails for some reason, i have lost
> > the
> > table that was there. i could first check for a valid connection before
> > dropping the CE table but there is still a chance it could fail for other
> > reasons.
> >
> > i was thinking that i would rename the local CE table and then drop it if
> > the download succeeded or name it back to its original name if the
> > download
> > fails.
> >
> > I wasn't sure of the best way to do this (couldn't find anything in ALTER
> > TABLE).
> >
> > Also, I was curious how other people might have solved this problem.
> >
> > Thanks,
> >
> > -Rob
> >
>
>
>
.
- References:
- renaming a table
- From: Rob C
- Re: renaming a table
- From: Darren Shaffer
- renaming a table
- Prev by Date: Re: INSERT and UPDATE
- Next by Date: nvarchar limit on CREATE TABLE?
- Previous by thread: Re: renaming a table
- Next by thread: INSERT and UPDATE
- Index(es):
Relevant Pages
|