Wednesday, March 28, 2012
Problem with Large SQL Log file
It appear by itself in the C: root directory and its filesize keep increasing while the SQL server is running even when I just open/ shutdown the SQL server. It had so far go up to 4GB in just a day.
I had actually keep log files of the SQL Server in another folder, so the SQL file is not created by me nor for any purpose. It keep coming back even when I remove it. Anyone can tell me what's the problem? Is it a virus or whatever?
Hi,
SQL file in C drive is not used by SQL Server. THis file is created by ODBC.
When ever we click the ODBC trace option, this SQL file will be updated and
have all the tracing information.
How to delete or move the file to a alternate location:-
1. Go to COntrol panel--Admin tools- Data sources (ODBC)
2. Double click on ODBC , CLick the Tracing Tab (In the top)
3. If it is Stop tracing then actually Tracing is going on.
4. In that case click "Stop Tracing"
5. Go to C drive root and delete the file or move the file to a diffrent
folder
6. When ever you require you can enable the tracing.
Thanks
Hari
MCDBA
"Kian" <anonymous@.discussions.microsoft.com> wrote in message
news:430A0105-2E68-4999-AEA7-B6D475828E33@.microsoft.com...
> I'm having a problem with this file SQL log file
> It appear by itself in the C: root directory and its filesize keep
increasing while the SQL server is running even when I just open/ shutdown
the SQL server. It had so far go up to 4GB in just a day.
> I had actually keep log files of the SQL Server in another folder, so the
SQL file is not created by me nor for any purpose. It keep coming back even
when I remove it. Anyone can tell me what's the problem? Is it a virus or
whatever?
Problem with Large SQL Log file
It appear by itself in the C: root directory and its filesize keep increasin
g while the SQL server is running even when I just open/ shutdown the SQL se
rver. It had so far go up to 4GB in just a day.
I had actually keep log files of the SQL Server in another folder, so the SQ
L file is not created by me nor for any purpose. It keep coming back even wh
en I remove it. Anyone can tell me what's the problem? Is it a virus or what
ever?Hi,
SQL file in C drive is not used by SQL Server. THis file is created by ODBC.
When ever we click the ODBC trace option, this SQL file will be updated and
have all the tracing information.
How to delete or move the file to a alternate location:-
1. Go to COntrol panel--Admin tools- Data sources (ODBC)
2. Double click on ODBC , CLick the Tracing Tab (In the top)
3. If it is Stop tracing then actually Tracing is going on.
4. In that case click "Stop Tracing"
5. Go to C drive root and delete the file or move the file to a diffrent
folder
6. When ever you require you can enable the tracing.
Thanks
Hari
MCDBA
"Kian" <anonymous@.discussions.microsoft.com> wrote in message
news:430A0105-2E68-4999-AEA7-B6D475828E33@.microsoft.com...
> I'm having a problem with this file SQL log file
> It appear by itself in the C: root directory and its filesize keep
increasing while the SQL server is running even when I just open/ shutdown
the SQL server. It had so far go up to 4GB in just a day.
> I had actually keep log files of the SQL Server in another folder, so the
SQL file is not created by me nor for any purpose. It keep coming back even
when I remove it. Anyone can tell me what's the problem? Is it a virus or
whatever?sql
Problem with Large SQL Log file
It appear by itself in the C: root directory and its filesize keep increasing while the SQL server is running even when I just open/ shutdown the SQL server. It had so far go up to 4GB in just a day
I had actually keep log files of the SQL Server in another folder, so the SQL file is not created by me nor for any purpose. It keep coming back even when I remove it. Anyone can tell me what's the problem? Is it a virus or whatever?Hi,
SQL file in C drive is not used by SQL Server. THis file is created by ODBC.
When ever we click the ODBC trace option, this SQL file will be updated and
have all the tracing information.
How to delete or move the file to a alternate location:-
1. Go to COntrol panel--Admin tools- Data sources (ODBC)
2. Double click on ODBC , CLick the Tracing Tab (In the top)
3. If it is Stop tracing then actually Tracing is going on.
4. In that case click "Stop Tracing"
5. Go to C drive root and delete the file or move the file to a diffrent
folder
6. When ever you require you can enable the tracing.
Thanks
Hari
MCDBA
"Kian" <anonymous@.discussions.microsoft.com> wrote in message
news:430A0105-2E68-4999-AEA7-B6D475828E33@.microsoft.com...
> I'm having a problem with this file SQL log file
> It appear by itself in the C: root directory and its filesize keep
increasing while the SQL server is running even when I just open/ shutdown
the SQL server. It had so far go up to 4GB in just a day.
> I had actually keep log files of the SQL Server in another folder, so the
SQL file is not created by me nor for any purpose. It keep coming back even
when I remove it. Anyone can tell me what's the problem? Is it a virus or
whatever?
Monday, March 26, 2012
Problem with insert Time to database
I have insert the time to my database but it appear also the date by default.
This is my code in C# :
DateTime date = DateTime.Now;
int hour = date.Hour;
int minute = date.Minute;
int second = date.Second;
string requestedTime = hour+":"+minute+":"+second;
string query = "INSERT INTO workorder([timeRequest]) VALUES("'"+requestTime+"'");
in my database , the column timeRequest appear :1/1/1900 11:59:05 AM
I dont want the date by default to appear, i want only the time like : 11:59:05 AM in my database,
Anyone can help me?
Best Regards,
Moniphal
Use parameterized command to insert data to database. By example:
SqlCommand cmd = conn.CreateCommand();
cmd.CommandText = "INSERT INTO workorder(timeRequest) VALUES (@.TimeRequest)";
cmd.CommandType = CommandType.Text
cmd.Parameters.Add(new SqlParameter("@.TimeRequest",myDateTime));
cmd.ExecuteNonQuery();
Friday, March 23, 2012
Problem with IF
It is a procedure that does the paging on the friends table, the variable @.PageWay is the ordering that the return table have to appear, ASC or DESC.
Why it's accusing error on if clause? "if(@.PageWay= 1)"
createProcedure teste2
@.user_idint,
@.PageIndexint,
@.PageSizeint,
@.PageOrdervarchar(10),
@.PageWaybit
As
Begin
Declare @.FirstRowint,
@.LastRowint,
@.Recordsint,
@.Paginasfloat,
@.Pagesint
Select @.FirstRow=( @.PageIndex- 1)* @.PageSize+ 1,
@.LastRow= @.PageSize+(@.PageIndex- 1)* @.PageSize;
With invitationas
(
Select*,
Row_Number()over(orderby friend_idasc)as RowNumber
from friendswhere [user_id]=(@.user_id)and invited=(1)
)
if(@.PageWay= 1)
Begin
Select*from invitationwhere RowNumberbetween @.FirstRowand @.LastRoworderby
casewhen @.PageOrder='creation'then creationendasc,
casewhen @.PageOrder='e_mail'then e_mailendasc
End
else
Begin
Select*from invitationwhere RowNumberbetween @.FirstRowand @.LastRoworderby
casewhen @.PageOrder='creation'then creationenddesc,
casewhen @.PageOrder='e_mail'then e_mailenddesc
End
Set @.Records=(SelectCount(*)as'amigos'From friendswhere [user_id]=(@.user_id)and invited=(1))
Set @.Paginas=(Convert(Float,@.Records)/Convert(Float,@.PageSize))
Set @.Pages=Ceiling(@.Paginas)
return @.Pages
End
Go
Thank you very much.
I think as you must put a semicolon before you start WITH statement, you must put something after.I discovered the error. After you define CTE you must use it in the next statement, otherwise you will got a message error. So I just put the following query before the If statement "Select Count(*) from invitation", and worked just fine.
There is the message when you put a Select query that not use the CTE,
Msg 422, Level 16, State 4, Procedure teste2, Line 30
Common table expression defined but not used.
Thank you very much, for had seemed my post.
Monday, March 12, 2012
Problem with enterprise manager ( image attached )
I have been having a problem for a couple of weeks, for some reason the
"Create Date" column of both the tables and SP views appear with weird
characters (as shown in the attached image) , This happen both on a local
server as well as on a remote server.
When I connect to the remote server using TS and see the same view the
"Create Date" column appear normally.
What could have happen? and even it's not a big issue I would like to know
how to solve it.
Thanks,
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
Did you by chance install YUKON Beta on the same box ?
"Ignacio Machin ( .NET/ C# MVP )" wrote:
> Hi,
> I have been having a problem for a couple of weeks, for some reason the
> "Create Date" column of both the tables and SP views appear with weird
> characters (as shown in the attached image) , This happen both on a local
> server as well as on a remote server.
> When I connect to the remote server using TS and see the same view the
> "Create Date" column appear normally.
> What could have happen? and even it's not a big issue I would like to know
> how to solve it.
>
> Thanks,
> --
> Ignacio Machin,
> ignacio.machin AT dot.state.fl.us
> Florida Department Of Transportation
>
>
|||Nop,
I haven't installed it, I have VS.NET 2005 installed , though.
Cheers,
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Umut Nazlica" <UmutNazlica@.discussions.microsoft.com> wrote in message
news:F4BA581B-F664-469D-8C7B-301E72D72292@.microsoft.com...[vbcol=seagreen]
> Did you by chance install YUKON Beta on the same box ?
>
> "Ignacio Machin ( .NET/ C# MVP )" wrote:
local[vbcol=seagreen]
know[vbcol=seagreen]
|||Probably that is the problem..
"Ignacio Machin ( .NET/ C# MVP )" wrote:
> Hi,
> I have been having a problem for a couple of weeks, for some reason the
> "Create Date" column of both the tables and SP views appear with weird
> characters (as shown in the attached image) , This happen both on a local
> server as well as on a remote server.
> When I connect to the remote server using TS and see the same view the
> "Create Date" column appear normally.
> What could have happen? and even it's not a big issue I would like to know
> how to solve it.
>
> Thanks,
> --
> Ignacio Machin,
> ignacio.machin AT dot.state.fl.us
> Florida Department Of Transportation
>
>
Problem with enterprise manager ( image attached )
I have been having a problem for a couple of weeks, for some reason the
"Create Date" column of both the tables and SP views appear with weird
characters (as shown in the attached image) , This happen both on a local
server as well as on a remote server.
When I connect to the remote server using TS and see the same view the
"Create Date" column appear normally.
What could have happen? and even it's not a big issue I would like to know
how to solve it.
Thanks,
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of TransportationDid you by chance install YUKON Beta on the same box ?
"Ignacio Machin ( .NET/ C# MVP )" wrote:
> Hi,
> I have been having a problem for a couple of weeks, for some reason the
> "Create Date" column of both the tables and SP views appear with weird
> characters (as shown in the attached image) , This happen both on a local
> server as well as on a remote server.
> When I connect to the remote server using TS and see the same view the
> "Create Date" column appear normally.
> What could have happen? and even it's not a big issue I would like to kno
w
> how to solve it.
>
> Thanks,
> --
> Ignacio Machin,
> ignacio.machin AT dot.state.fl.us
> Florida Department Of Transportation
>
>|||Nop,
I haven't installed it, I have VS.NET 2005 installed , though.
Cheers,
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Umut Nazlica" <UmutNazlica@.discussions.microsoft.com> wrote in message
news:F4BA581B-F664-469D-8C7B-301E72D72292@.microsoft.com...[vbcol=seagreen]
> Did you by chance install YUKON Beta on the same box ?
>
> "Ignacio Machin ( .NET/ C# MVP )" wrote:
>
local[vbcol=seagreen]
know[vbcol=seagreen]|||Probably that is the problem..
"Ignacio Machin ( .NET/ C# MVP )" wrote:
> Hi,
> I have been having a problem for a couple of weeks, for some reason the
> "Create Date" column of both the tables and SP views appear with weird
> characters (as shown in the attached image) , This happen both on a local
> server as well as on a remote server.
> When I connect to the remote server using TS and see the same view the
> "Create Date" column appear normally.
> What could have happen? and even it's not a big issue I would like to kno
w
> how to solve it.
>
> Thanks,
> --
> Ignacio Machin,
> ignacio.machin AT dot.state.fl.us
> Florida Department Of Transportation
>
>
Friday, March 9, 2012
Problem with enterprise manager ( image attached )
I have been having a problem for a couple of weeks, for some reason the
"Create Date" column of both the tables and SP views appear with weird
characters (as shown in the attached image) , This happen both on a local
server as well as on a remote server.
When I connect to the remote server using TS and see the same view the
"Create Date" column appear normally.
What could have happen? and even it's not a big issue I would like to know
how to solve it.
Thanks,
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of TransportationNop,
I haven't installed it, I have VS.NET 2005 installed , though.
Cheers,
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Umut Nazlica" <UmutNazlica@.discussions.microsoft.com> wrote in message
news:F4BA581B-F664-469D-8C7B-301E72D72292@.microsoft.com...
> Did you by chance install YUKON Beta on the same box ?
>
> "Ignacio Machin ( .NET/ C# MVP )" wrote:
> > Hi,
> >
> > I have been having a problem for a couple of weeks, for some reason the
> > "Create Date" column of both the tables and SP views appear with weird
> > characters (as shown in the attached image) , This happen both on a
local
> > server as well as on a remote server.
> > When I connect to the remote server using TS and see the same view the
> > "Create Date" column appear normally.
> >
> > What could have happen? and even it's not a big issue I would like to
know
> > how to solve it.
> >
> >
> > Thanks,
> >
> > --
> > Ignacio Machin,
> > ignacio.machin AT dot.state.fl.us
> > Florida Department Of Transportation
> >
> >
> >