Showing posts with label restored. Show all posts
Showing posts with label restored. Show all posts

Wednesday, March 28, 2012

HELP! Users Cannot login

DB has not been recently restored from backup
Is there a reindex function that I need to perform on a regular basis? I
thought SQL 2000 did this type of maint automatically?
"Narayana Vyas Kondreddi" <answer_me@.hotmail.com> wrote in message
news:enqaoGr4DHA.2136@.TK2MSFTNGP12.phx.gbl...
quote:

> What is the error when trying to login?
> Has that database been recently restored from a backup?
> In case of orphan users problem, see:
> http://vyaskn.tripod.com/troublesho...rphan_users.htm
> --
> HTH,
> Vyas, MVP (SQL Server)
> http://vyaskn.tripod.com/
> Is .NET important for a database professional?
> http://vyaskn.tripod.com/poll.htm
>
>
> "Kevin Evans" <kevin@.convenientcomputing.com> wrote in message
> news:eGKDayq4DHA.488@.TK2MSFTNGP12.phx.gbl...
> I have a database and the users suddenly cannot login. All are using

Windows
quote:

> Auth. I'm not a DBA but need to fix the prob ASAP. Where can I find a

quick
quote:

> resource for login issues? Can someone list some standard checks.
>
>
Enable auditing for successful & failed logins.
Verify the account that is unable to login to the server.
(login as that account and test with Query Analyser)
Verify that the account is a valid account on the server, and that the
recent database restore didn't change the users permissions.
Thanks,
Kevin McDonnell
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.|||There's no reindexing required in the context of 'ability to log into SQL
Server'
--
HTH,
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
Is .NET important for a database professional?
http://vyaskn.tripod.com/poll.htm
"Kevin Evans" <kevin@.convenientcomputing.com> wrote in message
news:ezTUP5w4DHA.2412@.TK2MSFTNGP09.phx.gbl...
DB has not been recently restored from backup
Is there a reindex function that I need to perform on a regular basis? I
thought SQL 2000 did this type of maint automatically?
"Narayana Vyas Kondreddi" <answer_me@.hotmail.com> wrote in message
news:enqaoGr4DHA.2136@.TK2MSFTNGP12.phx.gbl...
quote:

> What is the error when trying to login?
> Has that database been recently restored from a backup?
> In case of orphan users problem, see:
> http://vyaskn.tripod.com/troublesho...rphan_users.htm
> --
> HTH,
> Vyas, MVP (SQL Server)
> http://vyaskn.tripod.com/
> Is .NET important for a database professional?
> http://vyaskn.tripod.com/poll.htm
>
>
> "Kevin Evans" <kevin@.convenientcomputing.com> wrote in message
> news:eGKDayq4DHA.488@.TK2MSFTNGP12.phx.gbl...
> I have a database and the users suddenly cannot login. All are using

Windows
quote:

> Auth. I'm not a DBA but need to fix the prob ASAP. Where can I find a

quick
quote:

> resource for login issues? Can someone list some standard checks.
>
>

Monday, March 26, 2012

Help! SQLExpress2005 date formats

I installed SQLExpress2005 and restored some old MSSQL7 databases. This
seemed to work at first glance, but there is at least one problem. These
databases contained datetime values.
And we are in Germany where dates are written like this: 25.12.2005
(christmas, for example).
My ColdFusion application contains queries like this:
SELECT Datum, Kurztext, Feiertag, Brauchtumstag, Tagestyp, Freianteil,
Notiz
FROM tblBetriebskalender
WHEREdatum between '01.12.2005' and '31.12.2005'
ORDER BYDatum
this used to work without problems.
Now the same queries don't work because for a date such as '31.12.2005',
SQLServer thinks 12 is the day and 31 is the month.
What can I do? Is there a central switch somewhere that changes the data
formats? Unfortunately I don't know what it was set to in the old system.
(The database properties option tab shows that collation is now set to
SQL_Latin1_General_CP1_CI_AS, and the compatibility level is SQLServer 7.0.)
-Michael
hi Michael,
Michael Peters wrote:
> I installed SQLExpress2005 and restored some old MSSQL7 databases.
> This seemed to work at first glance, but there is at least one
> problem. These databases contained datetime values.
> And we are in Germany where dates are written like this: 25.12.2005
> (christmas, for example).
> My ColdFusion application contains queries like this:
> SELECT Datum, Kurztext, Feiertag, Brauchtumstag, Tagestyp, Freianteil,
> Notiz
> FROM tblBetriebskalender
> WHERE datum between '01.12.2005' and '31.12.2005'
> ORDER BY Datum
> this used to work without problems.
> Now the same queries don't work because for a date such as
> '31.12.2005', SQLServer thinks 12 is the day and 31 is the month.
> What can I do? Is there a central switch somewhere that changes the
> data formats? Unfortunately I don't know what it was set to in the
> old system.
> (The database properties option tab shows that collation is now set to
> SQL_Latin1_General_CP1_CI_AS, and the compatibility level is
> SQLServer 7.0.)
> -Michael
Dates should be handled in ISO format YYYY-MM-DD or YYYYMMDD in order to
avoid this kind of problem as the dateformat is language specific and each
login has na associated language default.. probably you had german setting
for your login on the old server and englis setting on the new one...
you can change the login's language
ALTER LOGIN login_name
DEFAULT_LANGUAGE = new_language
http://msdn2.microsoft.com/en-us/library/ms189828.aspx
or, at connection level, using the SET DATEFORMAT
http://msdn.microsoft.com/library/de...-set_052s.asp,
but I strongly urge you to modify your language management to standard
ISO/ODBC format..
an unvaluable article by Notre Dame SQL Server Kalen Delaney about "dates"
is available at
http://www.windowsitpro.com/SQLServe...147/9147.html, but
only for subscriber...
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz/DbaMgr.shtmhttp://italy.mvps.org
DbaMgr2k ver 0.16.0 - DbaMgr ver 0.61.0
(my vb6+sql-dmo little try to provide MS MSDE 1.0 and MSDE 2000 a visual
interface)
-- remove DMO to reply
|||thanks very much Andrea.
-Michael

Friday, March 23, 2012

HELP! Non-Replicated DB thinks its a Publisher

I hosed myself, please help me somebody.

We have a development server (SQL7) where the database is a restored copy of
production (where we use replication, but not in the development
environment).

While we rebuild the server recently (so we could move off of NT onto 2000),
everything looked to be working fine.

But I recently, messed up and did a massive update filling the transaction
log of the development server. Now I can't update data in development.

I tried to do my usual:

BACKUP LOG LAMS WITH Truncate_only

only to get a message:

The log was not truncated because records at the beginning of the log are
pending replication. Ensure the Log Reader Agent is running or use
sp_repldone to mark transactions as distributed.

Did a little research into BOL and tried to call the following two procs:

exec sp_repldone
@.xactid = null ,
@.xact_seqno = null ,
@.reset = 1

exec sp_repltrans

Both of which gave me an error of :
The database is not published.

Which it isn't as we don't run replication in the development environment.

I stopped and restarted the SQL Service (as that has cleared issues in the
past), but didn't reboot the server.

How can I make the database not think It's replicated (or that its caught
up?).

I was thinking, would I be even be able to do another restore of a more
recent copy of Production?

Sincerely ...
Depressed in DelawareNever Mind, I restored development from a more recent copy of production.

Is there a command to fix a SQL 7 DB when it gets confused about
replication?

"David Rawheiser" <rawhide58@.hotmail.com> wrote in message
news:DD3Bd.1194718$Gx4.69619@.bgtnsc04-news.ops.worldnet.att.net...
>I hosed myself, please help me somebody.
> We have a development server (SQL7) where the database is a restored copy
> of production (where we use replication, but not in the development
> environment).
> While we rebuild the server recently (so we could move off of NT onto
> 2000), everything looked to be working fine.
> But I recently, messed up and did a massive update filling the transaction
> log of the development server. Now I can't update data in development.
> I tried to do my usual:
> BACKUP LOG LAMS WITH Truncate_only
> only to get a message:
> The log was not truncated because records at the beginning of the log are
> pending replication. Ensure the Log Reader Agent is running or use
> sp_repldone to mark transactions as distributed.
> Did a little research into BOL and tried to call the following two procs:
> exec sp_repldone
> @.xactid = null ,
> @.xact_seqno = null ,
> @.reset = 1
> exec sp_repltrans
> Both of which gave me an error of :
> The database is not published.
> Which it isn't as we don't run replication in the development environment.
> I stopped and restarted the SQL Service (as that has cleared issues in the
> past), but didn't reboot the server.
> How can I make the database not think It's replicated (or that its caught
> up?).
> I was thinking, would I be even be able to do another restore of a more
> recent copy of Production?
> Sincerely ...
> Depressed in Delaware