Showing posts with label column. Show all posts
Showing posts with label column. Show all posts

Friday, March 23, 2012

MSDE publisher and subscriber with duplicated Identity column issues

I am new to SQL replication and I have an issue with the identity
column not properly synchronizing between two MSDE databases. I have
turned on the (not for replication) switch and changed the identity
seed and identity increment to be different on the subscriber, but as
soon as I pull the subscription it changes the seed back to the
original so both database are the same again. As both subscriber and
publisher are creating records, the identities are duplicated. I do
have Enterprise Manager installed to help configure the publishing,
but MSDE does not seem to allow the same control over the identity
range in replication as SQL 2000 does. How do I have a MSDE publisher
and a MSDE subscriber create records in different identity seeds
and/or increment?
What I am trying to accomplish:
Publisher -- seed 1, increment 2
Subscriber -- seed 2, increment 2
Or a similar function.
Thanks,
Daniel
Are you using replication's auto identity management feature. In SQL
identitites once a table is created you cannot change the identity increment
or the original seed. The only thing you can do is reseed to a value and SQL
with start inserting from that value onwards.
Thanks.
"Daniel" <dmaynes@.roinc.com> wrote in message
news:5ab2240f.0410061403.3923ef4a@.posting.google.c om...
> I am new to SQL replication and I have an issue with the identity
> column not properly synchronizing between two MSDE databases. I have
> turned on the (not for replication) switch and changed the identity
> seed and identity increment to be different on the subscriber, but as
> soon as I pull the subscription it changes the seed back to the
> original so both database are the same again. As both subscriber and
> publisher are creating records, the identities are duplicated. I do
> have Enterprise Manager installed to help configure the publishing,
> but MSDE does not seem to allow the same control over the identity
> range in replication as SQL 2000 does. How do I have a MSDE publisher
> and a MSDE subscriber create records in different identity seeds
> and/or increment?
> What I am trying to accomplish:
> Publisher -- seed 1, increment 2
> Subscriber -- seed 2, increment 2
> Or a similar function.
> Thanks,
> Daniel
|||I guess this is a newbi question, but how and when do I turn that on?
*** Sent via Developersdex http://www.codecomments.com ***
Don't just participate in USENET...get rewarded for it!
|||Daniel,
when you create the publication, on the article properties (the elipsis
button) there is a series of tabs, one called 'identity range'. The checkbox
at the top allows for automatic range management. Some people don't use it
and prefer to roll their own, using formulas like odds on the publisher and
evens on the subscriber.
HTH,
Paul Ibison
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
|||Right, I found that. I guess the trick is that it has to be checked as
you build the publication, and can be modified, but not added
afterwards. Thank you very much.
*** Sent via Developersdex http://www.codecomments.com ***
Don't just participate in USENET...get rewarded for it!

Monday, March 19, 2012

MSDE max field size?

Hi,
I have MSDE installed on my computer and I'm usingWeb Data Administrator to manage my databses. The problem is that whenever I add a column with a length of more than 8000, I get the following error:
Length must be between 0 and 8000
If I create the column programmatically then i get this error:
The following error occured while executing the query:
Server: Msg 131, Level 15, State 2, Line 2
The size (8005) given to the column 'Article' exceeds the maximum allowed for any data type (8000).
I need several columns that can hold around32,000 characters. What's the deal? Is this a limit with MSDE, or am Imissing something?
ThanksSmile [:)]

::Is this a limit with MSDE, or am I missing something?

Yoou miss reading the documentation.

ROWS in SQL Server - not just MSDE - are limited to 8000 bytes. This means the whole row, not a single field.

For longer data there are special datatypes (like text or ntext) that do not store the data in the row, but use separate tables. They are limited (no indexing and some other limitations).They work wonderfully with up to 2gb per field.

This is properly documented in the documentation for SQL Server, which I suggest you ahve a look at. It is also available online at Microsoft.


|||

The documentation to which thona is referring (but for which he never provides a link) is calledSQL Server 2000 Books Online. It is a free reference from Microsoft and is one which I personally refer to many times a day. It is a large download but well worth the time.

The same content is available at the MSDN site:Getting Started with SQL Server Books Online.

|||What Sql Server datatype would give me the equivalent of the "Memo" type in Access?
ThanksYes [Y]
|||That would be text (or ntext if you need to support international characters).
|||I'm sorry, but I should have asked this in my previous post...
What length should I specify?
Like... text(16), or text(32)?
Am I correct in assuming that (16) would give me 32768 characters?
ThanxSmile [:)]
|||

stevesimon wrote:

I'm sorry, but I should have asked this in my previous post...
What length should I specify?
Like... text(16), or text(32)?
Am I correct in assuming that (16) would give me 32768 characters?
ThanxSmile [:)]


I wouldn't specify a length at all -- it is not needed for the text data type.
As suggested, Books Online and MSDN are excellent references and youcould easily find this information yourself. According tontext, text, and image the text data type can store 2,147,483,647 characters.
|||

Just a qwuestion -why are you so reluctant to even LOOK into the online documentation ONCE?

Btw, tehe equivalent of Access "Memo" is NOT text - it is ntext. Access has no notion of non-unicode strings.

|||I did look at the documentation, but could not find the answer to my specific question.
|||Try using OLE(Object Linking and Embedding) in Access to store them asWord and import them into MSDE as image files and most of your problemswill go away. Hope this helps.
Kind regards,
Gift Peddie

Monday, March 12, 2012

MSDE Issue

Hi,
I have a strange issue. We have a DataTable in MSDE with
800 columns. The column name strings are very long.. about
200 characters or more.
When we try to do BULK INSERT into this table, MSDE
results in a General Network error.
We use SQLDataAdapter.
I am working against a very extreme scenario.
Any help?
Regards
Sundari.
It is impossible to have column in a table with its name being longer than
128 characters. SQL Server/MSDE does not allow column name longer than 128
characters.
"Sundari" <sundari_t@.hotmail.com> wrote in message
news:12d101c4ba7f$b1198870$a301280a@.phx.gbl...
> Hi,
> I have a strange issue. We have a DataTable in MSDE with
> 800 columns. The column name strings are very long.. about
> 200 characters or more.
> When we try to do BULK INSERT into this table, MSDE
> results in a General Network error.
> We use SQLDataAdapter.
> I am working against a very extreme scenario.
> Any help?
> Regards
> Sundari.