Showing posts with label message. Show all posts
Showing posts with label message. Show all posts

Thursday, March 29, 2012

database in simple mode yet txn log file can be out of diskspace ?

Hi ,

I have set up my database to be using "Simple" mode. This will not log any
txns ?

I have got the err message saying the log file is full and i need to do a
txn log backup

i do not understand why , could anyone kindly advise ?

tks & rdgs

--
Message posted via SQLMonster.com
http://www.sqlmonster.com/Uwe/Forum...eneral/200510/1Having you database in SIMPLE recovery mode does NOT mean that
transactions are not logged. All it means is that all committed
transactions are removed from the T-log when a checkpoint occurs. So if
you run lot's of and especially longrunning transactions, it still can
happen that your T-log grows out of space.

M

Database Idea

Good morning

In messages system i have table to store messages and another table to contain the links which the message is posted through

Now i want to delete a link but i don't want to delete the message sent through this link

The problem:

When displaying the message sent what will be fount in the link field (i.e for the deleted link)

I tried to move the deleted link data to separate table (EX: deletedLink) but if the user added new link with the same name as the deleted link?The problem mainly in when displaying the message sent i will have the same link twice one for the deleted and the other for the added one.

If any one has a good idea for doing that please reply to me

I don’t want the sql code

I want just the idea

Thanks

kind regards

Mohammed Al Maghraby

Hey,

I posted in your other forum post.

Wednesday, March 21, 2012

Database Error during backup

We are currently using SQL 2000 SP4. When I try to backup any of our
Databases I receive the error message below, any suggestions that would fix
this problem for me. I would also like to make note that I viewed the Error
Log and could not identify any possible causes to this error, I have also
checked the Event Log and nothing logged there either.
--
Microsoft SQL-DMO (ODBC SQLState: 01000)
--
Error 926: Database 'msdb' cannot be opened. It has been marked SUSPECT by
recovery. See the SQL Server errorlog for more information.
--
OK
--
Regards,
JohnCheck BOL for DBCC CHECKDB
"John" <John@.discussions.microsoft.com> wrote in message
news:10ECD5A7-3C9A-427C-BD9B-F0DAA3F1FBD9@.microsoft.com...
> We are currently using SQL 2000 SP4. When I try to backup any of our
> Databases I receive the error message below, any suggestions that would
> fix
> this problem for me. I would also like to make note that I viewed the
> Error
> Log and could not identify any possible causes to this error, I have also
> checked the Event Log and nothing logged there either.
> --
> Microsoft SQL-DMO (ODBC SQLState: 01000)
> --
> Error 926: Database 'msdb' cannot be opened. It has been marked SUSPECT by
> recovery. See the SQL Server errorlog for more information.
> --
> OK
> --
> Regards,
> John
>|||... and be prepared for the worst: to restore your msdb database from a clean backup.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Jay" <spam@.nospam.org> wrote in message news:u46ACdaEIHA.2004@.TK2MSFTNGP06.phx.gbl...
> Check BOL for DBCC CHECKDB
> "John" <John@.discussions.microsoft.com> wrote in message
> news:10ECD5A7-3C9A-427C-BD9B-F0DAA3F1FBD9@.microsoft.com...
>> We are currently using SQL 2000 SP4. When I try to backup any of our
>> Databases I receive the error message below, any suggestions that would
>> fix
>> this problem for me. I would also like to make note that I viewed the
>> Error
>> Log and could not identify any possible causes to this error, I have also
>> checked the Event Log and nothing logged there either.
>> --
>> Microsoft SQL-DMO (ODBC SQLState: 01000)
>> --
>> Error 926: Database 'msdb' cannot be opened. It has been marked SUSPECT by
>> recovery. See the SQL Server errorlog for more information.
>> --
>> OK
>> --
>> Regards,
>> John
>|||IIRC on sql2000 you can directly modify system tables. perhaps you can try
updating sysdatabases to clear the suspect flag (there may even be advice on
this in BOL) after you exhaust all other attempts and just before you
restore/rebuild your msdb.
You can also consider calling Microsoft for support.
--
Kevin G. Boles
TheSQLGuru
Indicium Resources, Inc.
"John" <John@.discussions.microsoft.com> wrote in message
news:10ECD5A7-3C9A-427C-BD9B-F0DAA3F1FBD9@.microsoft.com...
> We are currently using SQL 2000 SP4. When I try to backup any of our
> Databases I receive the error message below, any suggestions that would
> fix
> this problem for me. I would also like to make note that I viewed the
> Error
> Log and could not identify any possible causes to this error, I have also
> checked the Event Log and nothing logged there either.
> --
> Microsoft SQL-DMO (ODBC SQLState: 01000)
> --
> Error 926: Database 'msdb' cannot be opened. It has been marked SUSPECT by
> recovery. See the SQL Server errorlog for more information.
> --
> OK
> --
> Regards,
> John
>

database engine giving problems

i installed sql server 2005 but i am unable to connect to the database engine. An error message appears saying :

===================================

Cannot connect to mssqlserver.

===================================

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (.Net SqlClient Data Provider)


For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&EvtSrc=MSSQLServer&EvtID=53&LinkId=20476


Error Number: 53
Severity: 20
State: 0

Program Location:

at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
at System.Data.SqlClient.TdsParser.Connect(Boolean& useFailoverPartner, Boolean& failoverDemandDone, String host, String failoverPartner, String protocol, SqlInternalConnectionTds connHandler, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject, Boolean aliasLookup)
at System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance)
at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.SqlClient.SqlConnection.Open()
at Microsoft.SqlServer.Management.UI.VSIntegration.ObjectExplorer.ObjectExplorer.ValidateConnection(UIConnectionInfo ci, IServerType server)
at Microsoft.SqlServer.Management.UI.ConnectionDlg.Connector.ConnectionThreadUser()

I am using win xp x64 edition

Hi,

sounds like the old proble, you either have a typo in your connectionstring / server name (and eventually port or instance name) or you have to enable remote connections to access your server.

http://www.sqlserver2005.de/SharedFiles/remoteconnection.jpg

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

Sunday, March 11, 2012

Database Diagrams tool

When I use the sql 2005 "Database Diagrams" tool for the first time I always get the message: "The Database does not have one or more of the support objects required to use database diagramming. Do you wish to create them?"

1. Does anyone know what the " support objects" referred to are?

2. Why SQL doesn't automatically create these support objects for me? (e.g. do they require a lot of hard disk space so they shouldn't routinely be created?)

3. Is there any way to make Sql automatically create them?

If you can address any of these points I'd appreciate it.

TIA,

barkingdog


The support objects are the following objects that will be created during the action:

sp_helpdiagramdefinition
sp_creatediagram
sp_renamediagram
sp_alterdiagram
sp_dropdiagram
fn_diagramobjects
sp_upgraddiagrams
sysdiagrams
PK__sysdiagrams__ID
UK_principal_name
sp_helpdiagrams

I don′t know why they are not created at creation time of the database, but you can influence this design by creating the definitions once in the model database. As the model database is the template for new database, once theay are created here, they will exists in every new database.


HTH, Jens SUessmeyer.


http://www.sqlserver2005.de

|||

I create all my databases from a script, and I can't always guarantee the model database design.

Is there a single system sproc that can be called to generate all those bits?

Otherwise - what's the best way to get all those bits into the model database? You can't add a diagram to the model database..

Thanks...

|||


As noone prevents you from scripting the stored procedures and related objects, just script them and put them in your custom script you are executing.

HTH, Jens SUessmeyer.


http://www.sqlserver2005.de

Thursday, March 8, 2012

Database diagram in SQL Server 2005

I cannot create a database diagram in SQL Server 2005.
When I try to create a diagram I receive the message that the database does
not have a valid owner. I changed the database owner to sa and yet the
message persists.
I get this invalid owner messsage when I try to create a new database
diagram or install support for diagrams.
Has anyone else experienced this problem?Dave
Did you upgrade the database to SQL Server 2005 or it was initialy created
?
"Dave" <davefrick@.newsgroup.nospam> wrote in message
news:uChrIOS9GHA.1012@.TK2MSFTNGP05.phx.gbl...
>I cannot create a database diagram in SQL Server 2005.
> When I try to create a diagram I receive the message that the database
> does not have a valid owner. I changed the database owner to sa and yet
> the message persists.
> I get this invalid owner messsage when I try to create a new database
> diagram or install support for diagrams.
> Has anyone else experienced this problem?
>|||What is the compatibility mode of the database?
You can check with:
select compatibility_level
from sys.databases
where name = 'YourDatabase'
It needs to be at 90 to use the diagrams. You can change it
to 90 with:
EXEC sp_dbcmptlevel YourDatabase, 90
I think this was fixed in the service pack so the other
alternative is to apply SP1.
-Sue
On Sat, 21 Oct 2006 09:03:22 -0700, "Dave"
<davefrick@.newsgroup.nospam> wrote:
>I cannot create a database diagram in SQL Server 2005.
>When I try to create a diagram I receive the message that the database does
>not have a valid owner. I changed the database owner to sa and yet the
>message persists.
>I get this invalid owner messsage when I try to create a new database
>diagram or install support for diagrams.
>Has anyone else experienced this problem?
>|||Hi,
My understanding of your issue is that:
You cannot create a database diagram on your database due to the invalid
owner error:
Database diagram support objects cannot be installed because this database
does not have a valid owner. To continue, first use the Files page of the
Database Properties dialog box or the ALTER AUTHORIZATION statement to set
the database owner to a valid login, then add the database diagram support
objects.
If I have misunderstood, please let me know.
This issue is caused by the database compatibility. If the database is not
in 90 compatibility level, the error will occcur.
Please run the following statements to resolve this issue:
USE master
GO
EXEC sp_dbcmptlevel 'your_database_name', '90';
ALTER AUTHORIZATION ON DATABASE::your_database_name TO [your_login_name]
GO
For more information, please refer to:
Understanding Database Diagram Ownership (Visual Database Tools)
http://msdn2.microsoft.com/en-us/library/ms186345.aspx
If you have any other questions or concerns, please feel free to let me
know. It's my pleasure to be of assistance.
Charles Wang
Microsoft Online Community Support
======================================================When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from this issue.
======================================================This posting is provided "AS IS" with no warranties, and confers no rights.
======================================================|||Hi,
I am interested in this issue. Would you mind letting me know the result of
the suggestions? If you need further assistance, feel free to let me know.
I will be more than happy to be of assistance.
Have a great day!
Charles Wang
Microsoft Online Community Support|||I have this same issue at the moment, and I am on compatibility level 90. I
have other databases on the same server for which I am able to use database
diagramming.
"Charles Wang[MSFT]" wrote:
> Hi,
> I am interested in this issue. Would you mind letting me know the result of
> the suggestions? If you need further assistance, feel free to let me know.
> I will be more than happy to be of assistance.
> Have a great day!
> Charles Wang
> Microsoft Online Community Support
>|||I have the same issue. My database is set with compatibility level 90. I
have other databases in the same instance of SQL server for which I can use
database diagrams.
"Charles Wang[MSFT]" wrote:
> Hi,
> I am interested in this issue. Would you mind letting me know the result of
> the suggestions? If you need further assistance, feel free to let me know.
> I will be more than happy to be of assistance.
> Have a great day!
> Charles Wang
> Microsoft Online Community Support
>|||what i did to fix this was go to database your working with, go to
properties, click on FILES and then add the SA account to the owner... done!
"lund0529" wrote:
> I have the same issue. My database is set with compatibility level 90. I
> have other databases in the same instance of SQL server for which I can use
> database diagrams.
> "Charles Wang[MSFT]" wrote:
> > Hi,
> >
> > I am interested in this issue. Would you mind letting me know the result of
> > the suggestions? If you need further assistance, feel free to let me know.
> > I will be more than happy to be of assistance.
> >
> > Have a great day!
> >
> > Charles Wang
> > Microsoft Online Community Support
> >
> >|||Thanks Charles.
Setting the compatibility level to 90 solved my problem.
Dave
"Charles Wang[MSFT]" <changliw@.online.microsoft.com> wrote in message
news:PJRiU9N%23GHA.4432@.TK2MSFTNGXA01.phx.gbl...
> Hi,
> I am interested in this issue. Would you mind letting me know the result
> of
> the suggestions? If you need further assistance, feel free to let me know.
> I will be more than happy to be of assistance.
> Have a great day!
> Charles Wang
> Microsoft Online Community Support
>|||Hi Dave,
Appreciate your update and response. I am glad to hear that the problem has
been fixed. If you have any other questions or concerns, please do not
hesitate to contact us. It is always our pleasure to be of assistance.
Have a nice day!
Charles Wang
Microsoft Online Community Support
======================================================When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from this issue.
======================================================This posting is provided "AS IS" with no warranties, and confers no rights.
======================================================

Database diagram in SQL Server 2005

I cannot create a database diagram in SQL Server 2005.
When I try to create a diagram I receive the message that the database does
not have a valid owner. I changed the database owner to sa and yet the
message persists.
I get this invalid owner messsage when I try to create a new database
diagram or install support for diagrams.
Has anyone else experienced this problem?Hi,
I am interested in this issue. Would you mind letting me know the result of
the suggestions? If you need further assistance, feel free to let me know.
I will be more than happy to be of assistance.
Have a great day!
Charles Wang
Microsoft Online Community Support|||I have this same issue at the moment, and I am on compatibility level 90. I
have other databases on the same server for which I am able to use database
diagramming.
"Charles Wang[MSFT]" wrote:

> Hi,
> I am interested in this issue. Would you mind letting me know the result o
f
> the suggestions? If you need further assistance, feel free to let me know.
> I will be more than happy to be of assistance.
> Have a great day!
> Charles Wang
> Microsoft Online Community Support
>|||I have the same issue. My database is set with compatibility level 90. I
have other databases in the same instance of SQL server for which I can use
database diagrams.
"Charles Wang[MSFT]" wrote:

> Hi,
> I am interested in this issue. Would you mind letting me know the result o
f
> the suggestions? If you need further assistance, feel free to let me know.
> I will be more than happy to be of assistance.
> Have a great day!
> Charles Wang
> Microsoft Online Community Support
>|||what i did to fix this was go to database your working with, go to
properties, click on FILES and then add the SA account to the owner... done!
"lund0529" wrote:
[vbcol=seagreen]
> I have the same issue. My database is set with compatibility level 90. I
> have other databases in the same instance of SQL server for which I can us
e
> database diagrams.
> "Charles Wang[MSFT]" wrote:
>|||Thanks Charles.
Setting the compatibility level to 90 solved my problem.
Dave
"Charles Wang[MSFT]" <changliw@.online.microsoft.com> wrote in message
news:PJRiU9N%23GHA.4432@.TK2MSFTNGXA01.phx.gbl...
> Hi,
> I am interested in this issue. Would you mind letting me know the result
> of
> the suggestions? If you need further assistance, feel free to let me know.
> I will be more than happy to be of assistance.
> Have a great day!
> Charles Wang
> Microsoft Online Community Support
>|||Hi Dave,
Appreciate your update and response. I am glad to hear that the problem has
been fixed. If you have any other questions or concerns, please do not
hesitate to contact us. It is always our pleasure to be of assistance.
Have a nice day!
Charles Wang
Microsoft Online Community Support
========================================
==============
When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from this issue.
========================================
==============
This posting is provided "AS IS" with no warranties, and confers no rights.
========================================
==============|||Charles,
I am having a same problem where I could not create database diagrams.
I have update the database compatibility mode to 90 and also ran ALTER
AUTHORIZATION ON DATABASE command but no success.
Do you have any other idea of how to fix it?
Thanks.
Bader Cheema
*** Sent via Developersdex http://www.codecomments.com ***

Friday, February 24, 2012

database Design Idea

Good morning
In messages system i have table to store messages and another table to contain the links which the message is posted through
Now i want to delete a link but i don't want to delete the message sent through this link
The problem:
When displaying the message sent what will be found in the link field (i.e. for the deleted link)

If any one has a good idea for doing that please reply to me
I dont want the sql code
I want just the idea
Thanks

kind regards
mohammed Al MaghrabyIs this a one-to-one relationship? one message for one link? Or, could one link refer to many messages? Or vice-versa.|||it is one to many relationship
one link can be used for many massages|||one link can be used for many messages

therefore the message has a foreign key to the link

now you delete the link, and you want the message to remain

and you're asking what will be found in the link

the answer: whatever you defined in the foreign key's ON DELETE option

in sql server 2000, the ON DELETE options are CASCADE (which you don't want) and NO ACTION (which would prevent the delete), so in sql server 2000, you can't do what you want with a foreign key!!

in sql server 2005, the ON DELETE options are NO ACTION, CASCADE, SET NULL, and SET DEFAULT (more in line with the various options defined by the sql standard)

helps?|||First Thanks for interest

There is misunderstanding in the problem
I have to enable the user to add a link with the same name because the original link supposed to be deleted
I.e. it doesn't appear in the forms of the application
So the user thinks that the link was deleted
Again

i want to delete the link because it became useless for me but at the same time there are messages in the message table which are related to that link
And I don't want to delete them
Also at the same time after deleting the link the user wants to view a report about the messages which contain information about the link used for sending these messages
, after deleting the link where could I get the link information?...because the message link data is very importatnt to me to know ......... that is the problem

I hope the situation is clear

Again thanks for interest


Kind regards

Mohammed Al Maghraby|||It sounds like you might want a sort of archive or history table. Just have a "deleted_links" table. The messages can remain in the messages table, they will just relate to the link you move to the deleted_links table. Or you could add a "current" field to the links table. Instead of deleting the link, you would set current to false.
Is that what you mean?|||I have to enable the user to add a link with the same name because the original link supposed to be deleted

Is "LinkName" (or equivalent) your primary key?