Showing posts with label moved. Show all posts
Showing posts with label moved. Show all posts

Friday, March 9, 2012

Diagram Editor

Hello,

i just moved over from MS Access to MSSQL.

when trying to save a relation in the Diagram editor
between 2 tables i get this error:

'abbrev' table saved successfully
'companies' table
- Unable to create relationship 'FK_companies_abbrev'.
ODBC error: [Microsoft][ODBC SQL Server Driver][SQL Server]ALTER TABLE statement conflicted with COLUMN FOREIGN KEY constraint 'FK_companies_abbrev'. The conflict occurred in database 'intranet', table 'abbrev', column 'id'.

relation is between companies.id <-> abbrev.company

both are 4 byte INTs.

it works fine with the other 4 tables but not for this last one.

any ideas/clues about what could be wrong?
and is it usefull to use that diagram or should i redo all the relations just in the query editor everytime it's needed?

thanks in advance.

SorexAre they also both "identity" columns?

Make sure that you have set the following properties for these columns in their respective tables...

Identity: YES
Identity Seed: 1
Identity Increment: 1

Also, I would set both of these columns as PRIMARY KEYS in their respective tables, so that they can be relate to each other as FKs.|||>Are they also both "identity" columns?

no, the link is between companies.id & abbrev.company (not abbrev.id)

>Make sure that you have set the following properties for these
> columns in their respective tables...
>Identity: YES
>Identity Seed: 1
>Identity Increment: 1

done this for both ID's of the tables.

i've put a screenshot online to look at what it actually is

should be on http://users.skynet.be/sky81117/sql.gif|||what's the use of the diagram anyway?

when i reopen the things i did yesterday i see the relations but they dissapear when the table content appears.

so it's a waste of time to use this feature or not?|||Originally posted by sorex
what's the use of the diagram anyway?

when i reopen the things i did yesterday i see the relations but they dissapear when the table content appears.

so it's a waste of time to use this feature or not?

The major purpose of the Diagram Editor is providing a visual tool to identify referential integrity within your database. It is the exact same tool as "Relationships" in Access. Yes, you can identify FK constraints by using the "Manage Index" tool for each table, however, I find the Diagram Editor to be quite useful and easy to establish FK constraints and show referential integrity between tables within my database systems.

The major problem with what you have done so far is within your database schema design. When I said that you should have primary key IDs in your tables, I meant that you needed to specify a current column within the tables and make that the PK, not necessary adding another field. Also, your columns are not normalized across the two tables.

Why do you have duplicate Company and contact information columns within each table?

What is the purpose of the abbrev and company tables? How are they supposed to relate to one another?

Wednesday, March 7, 2012

Device Activation Error

Hi,

I have set of stored procedures in SQL 7.0. They are all encrypted. I moved the whole set to SQL 2K. I took a backup of the SQL 7.0 version and put it in SQL 2K. Now, when I run the stored procedure in SQL 2K, I am getting an error as "Device Activation Error". This is happening when I run a stored procedure which is creating a new database and I am giving the MDF and LDF names as parameters. I have not met with any success in SQL Books. Please enlighten...

Thanks,
SrinidhiOriginally posted by srinidhiv
Hi,

I have set of stored procedures in SQL 7.0. They are all encrypted. I moved the whole set to SQL 2K. I took a backup of the SQL 7.0 version and put it in SQL 2K. Now, when I run the stored procedure in SQL 2K, I am getting an error as "Device Activation Error". This is happening when I run a stored procedure which is creating a new database and I am giving the MDF and LDF names as parameters. I have not met with any success in SQL Books. Please enlighten...

Thanks,
Srinidhi

what do you mean by encrypted stored procedures ?
if you could post the code ,it could be more helpful.|||Does the stored procedure works fine in SQLServer7.0 ?|||So your SP is encrypted. It is written with incompatible MSSQL7 syntax.
You can simply decrypt it. MSSQL2K encryption is weak.
Get permitions to rewrite SP from developer and look at I-net.

Sunday, February 19, 2012

Developer Edition

We are looking at putting Developer Edition on a server to allow us to test and develop databases/applications which will then be moved to one of our live standard licensed servers. I have a couple of questions as the licencing is confusing
1. Is the licence per developer? Our developers often work together, so can we licence each developer so they can all access one test server
2. Some documentation refers to a maximum of 5 connections. Is this in total or concurrently
2. Can users with existing CAL's access the server for the purpose of testing and evaluation
ThnakLicencing is per developer if bought standalone. If you are getting
Developer edition via MSDN subscription or similar, it is governed by the
EULA for MSDN.
Lots of info here;
http://www.microsoft.com/sql/howtobuy/development.asp
Cheers
Ken
"El" <anonymous@.discussions.microsoft.com> wrote in message
news:2B485FC0-48B8-4668-B8AB-67B1D890814F@.microsoft.com...
: We are looking at putting Developer Edition on a server to allow us to
test and develop databases/applications which will then be moved to one of
our live standard licensed servers. I have a couple of questions as the
licencing is confusing.
:
: 1. Is the licence per developer? Our developers often work together, so
can we licence each developer so they can all access one test server?
: 2. Some documentation refers to a maximum of 5 connections. Is this in
total or concurrently?
: 2. Can users with existing CAL's access the server for the purpose of
testing and evaluation?
:
: Thnaks
: