Wednesday, March 28, 2012
Memory
I have a server with 3 CPUS and 4 GB RAM and I would like to allocate a dynamic memory that the min server memory is 2gb and the max server memory is 3 GB, But i see in the error log from sql server the following message "unable to allocate 'min server memory 2000" in the task manager the memory value is 1.732.504, Does anybody know what is happening ! I must set in the boot.ini from the machine with the option /3g or the SQL should allow me to set the memory to 2 GB ?
Please Help me !To access more than 2GB, you need to be running SQL Enterprise or Developer
edition and your operating system needs to support > 2GB. See the link
below for details on how to configure.
http://support.microsoft.com/default.aspx?scid=kb;en-us;274750&Product=sql
--
Hope this helps.
Dan Guzman
SQL Server MVP
"Carrasco" <roberto_carrasco@.msn.com> wrote in message
news:5919CF87-67F3-45DE-8918-470C3F120493@.microsoft.com...
> Hi,
> I have a server with 3 CPUS and 4 GB RAM and I would like to allocate a
dynamic memory that the min server memory is 2gb and the max server memory
is 3 GB, But i see in the error log from sql server the following message
"unable to allocate 'min server memory 2000" in the task manager the memory
value is 1.732.504, Does anybody know what is happening ! I must set in the
boot.ini from the machine with the option /3g or the SQL should allow me to
set the memory to 2 GB ?
> Please Help me !sql
Memory
I have a server with 3 CPUS and 4 GB RAM and I would like to allocate a dyna
mic memory that the min server memory is 2gb and the max server memory is 3
GB, But i see in the error log from sql server the following message "unable
to allocate 'min server me
mory 2000" in the task manager the memory value is 1.732.504, Does anybody k
now what is happening ! I must set in the boot.ini from the machine with the
option /3g or the SQL should allow me to set the memory to 2 GB ?
Please Help me !To access more than 2GB, you need to be running SQL Enterprise or Developer
edition and your operating system needs to support > 2GB. See the link
below for details on how to configure.
http://support.microsoft.com/defaul...750&Product=sql
Hope this helps.
Dan Guzman
SQL Server MVP
"Carrasco" <roberto_carrasco@.msn.com> wrote in message
news:5919CF87-67F3-45DE-8918-470C3F120493@.microsoft.com...
> Hi,
> I have a server with 3 CPUS and 4 GB RAM and I would like to allocate a
dynamic memory that the min server memory is 2gb and the max server memory
is 3 GB, But i see in the error log from sql server the following message
"unable to allocate 'min server memory 2000" in the task manager the memory
value is 1.732.504, Does anybody know what is happening ! I must set in the
boot.ini from the machine with the option /3g or the SQL should allow me to
set the memory to 2 GB ?
> Please Help me !sql
Monday, March 26, 2012
Memo Data Type
data type. I tried using NVarChar(MAX), it will let me enter 254
characters. Then it gives me an error that the field is too small - it
won't even accept the 254. Is there another data type in SQL that I
can use that would be similar to the memo data type?
-doodleHi
"doodle" wrote:
> I am transferring my access backend to sql 2005. access has a memo
> data type. I tried using NVarChar(MAX), it will let me enter 254
> characters. Then it gives me an error that the field is too small - it
> won't even accept the 254. Is there another data type in SQL that I
> can use that would be similar to the memo data type?
> -doodle
>
nvarchar(max) can hold 2^31 -1 bytes see
http://msdn2.microsoft.com/en-gb/library/ms130896.aspx. It is most likely a
limit of the application that you are using that restricts imput/output to
254 bytes, for instance the tools/options menus in Query Analyser or SQL
Server Management Studio can be configure to set how many characters are
displayed.
John|||John,
I checked it in SQL, it is currently set to 2147483647 bytes. What do
I need to change it to?
-doodle|||"doodle" <ADraughn@.mazakcorp.com> wrote in message
news:1172510102.622413.4400@.k78g2000cwa.googlegroups.com...
> John,
> I checked it in SQL, it is currently set to 2147483647 bytes. What do
> I need to change it to?
> -doodle
>
I don't believe you can. If you need to store more than 2 gigs in a memo,
you may want to rethink your datastructure.
(perhaps a pointer to a file on a disk or something.)
Greg Moore
SQL Server DBA Consulting
sql (at) greenms.com http://www.greenms.com|||Hi
"doodle" wrote:
> John,
> I checked it in SQL, it is currently set to 2147483647 bytes. What do
> I need to change it to?
> -doodle
>
You do not say how you are updating this value a statement such as
UPDATE MyTable
SET MyMemoColumn = 'A very long memo text that is much longer than this'
Will work fine.
To see what size this value is use the query
SELECT LEN(MyMemoColumn)
FROM MyTable
Query Analyser will not allow you to set a the number of output characters
to a value as large as 2147483647 neither will SSMS which has a maximum
display value of 8192. How did you obtain this figure?
John|||It's being updated by forms in access 97.
-doodle|||Hi
"doodle" wrote:
> It's being updated by forms in access 97.
> -doodle
>
Did you run the query from my last reply to see how big the data is?
John
Memo Data Type
data type. I tried using NVarChar(MAX), it will let me enter 254
characters. Then it gives me an error that the field is too small - it
won't even accept the 254. Is there another data type in SQL that I
can use that would be similar to the memo data type?
-doodleWhere are you trying to enter data, what is the exact error message
you are getting, and what application is generating the error?
-- Steve Kass
-- Drew University
-- http://www.stevekass.com
doodle wrote:
>I am transferring my access backend to sql 2005. access has a memo
>data type. I tried using NVarChar(MAX), it will let me enter 254
>characters. Then it gives me an error that the field is too small - it
>won't even accept the 254. Is there another data type in SQL that I
>can use that would be similar to the memo data type?
>-doodle
>
>
Memo Data Type
data type. I tried using NVarChar(MAX), it will let me enter 254
characters. Then it gives me an error that the field is too small - it
won't even accept the 254. Is there another data type in SQL that I
can use that would be similar to the memo data type?
-doodleWhere are you trying to enter data, what is the exact error message
you are getting, and what application is generating the error?
-- Steve Kass
-- Drew University
-- http://www.stevekass.com
doodle wrote:
>I am transferring my access backend to sql 2005. access has a memo
>data type. I tried using NVarChar(MAX), it will let me enter 254
>characters. Then it gives me an error that the field is too small - it
>won't even accept the 254. Is there another data type in SQL that I
>can use that would be similar to the memo data type?
>-doodle
>
>
Memo Data Type
data type. I tried using NVarChar(MAX), it will let me enter 254
characters. Then it gives me an error that the field is too small - it
won't even accept the 254. Is there another data type in SQL that I
can use that would be similar to the memo data type?
-doodleHi
"doodle" wrote:
> I am transferring my access backend to sql 2005. access has a memo
> data type. I tried using NVarChar(MAX), it will let me enter 254
> characters. Then it gives me an error that the field is too small - it
> won't even accept the 254. Is there another data type in SQL that I
> can use that would be similar to the memo data type?
> -doodle
>
nvarchar(max) can hold 2^31 -1 bytes see
http://msdn2.microsoft.com/en-gb/library/ms130896.aspx. It is most likely a
limit of the application that you are using that restricts imput/output to
254 bytes, for instance the tools/options menus in Query Analyser or SQL
Server Management Studio can be configure to set how many characters are
displayed.
John|||John,
I checked it in SQL, it is currently set to 2147483647 bytes. What do
I need to change it to?
-doodle|||"doodle" <ADraughn@.mazakcorp.com> wrote in message
news:1172510102.622413.4400@.k78g2000cwa.googlegroups.com...
> John,
> I checked it in SQL, it is currently set to 2147483647 bytes. What do
> I need to change it to?
> -doodle
>
I don't believe you can. If you need to store more than 2 gigs in a memo,
you may want to rethink your datastructure.
(perhaps a pointer to a file on a disk or something.)
Greg Moore
SQL Server DBA Consulting
sql (at) greenms.com http://www.greenms.com|||Hi
"doodle" wrote:
> John,
> I checked it in SQL, it is currently set to 2147483647 bytes. What do
> I need to change it to?
> -doodle
>
You do not say how you are updating this value a statement such as
UPDATE MyTable
SET MyMemoColumn = 'A very long memo text that is much longer than this'
Will work fine.
To see what size this value is use the query
SELECT LEN(MyMemoColumn)
FROM MyTable
Query Analyser will not allow you to set a the number of output characters
to a value as large as 2147483647 neither will SSMS which has a maximum
display value of 8192. How did you obtain this figure?
John|||It's being updated by forms in access 97.
-doodle|||Hi
"doodle" wrote:
> It's being updated by forms in access 97.
> -doodle
>
Did you run the query from my last reply to see how big the data is?
John
Memo Data Type
"doodle" wrote:
> I am transferring my access backend to sql 2005. access has a memo
> data type. I tried using NVarChar(MAX), it will let me enter 254
> characters. Then it gives me an error that the field is too small - it
> won't even accept the 254. Is there another data type in SQL that I
> can use that would be similar to the memo data type?
> -doodle
>
nvarchar(max) can hold 2^31 -1 bytes see
http://msdn2.microsoft.com/en-gb/library/ms130896.aspx. It is most likely a
limit of the application that you are using that restricts imput/output to
254 bytes, for instance the tools/options menus in Query Analyser or SQL
Server Management Studio can be configure to set how many characters are
displayed.
John
"doodle" <ADraughn@.mazakcorp.com> wrote in message
news:1172510102.622413.4400@.k78g2000cwa.googlegrou ps.com...
> John,
> I checked it in SQL, it is currently set to 2147483647 bytes. What do
> I need to change it to?
> -doodle
>
I don't believe you can. If you need to store more than 2 gigs in a memo,
you may want to rethink your datastructure.
(perhaps a pointer to a file on a disk or something.)
Greg Moore
SQL Server DBA Consulting
sql (at) greenms.com http://www.greenms.com
|||Hi
"doodle" wrote:
> John,
> I checked it in SQL, it is currently set to 2147483647 bytes. What do
> I need to change it to?
> -doodle
>
You do not say how you are updating this value a statement such as
UPDATE MyTable
SET MyMemoColumn = 'A very long memo text that is much longer than this'
Will work fine.
To see what size this value is use the query
SELECT LEN(MyMemoColumn)
FROM MyTable
Query Analyser will not allow you to set a the number of output characters
to a value as large as 2147483647 neither will SSMS which has a maximum
display value of 8192. How did you obtain this figure?
John
|||Hi
"doodle" wrote:
> It's being updated by forms in access 97.
> -doodle
>
Did you run the query from my last reply to see how big the data is?
John
sql
Memery Usage
I have an SQL Server 2005 with limited resources therefore I have limited
the max memory usage for SQL Server to 768 Mb however doesnt seem to make any
difference. SQL Server is marrily taking 844,000 Kb of memory which then
becomes an issue due to the lack of memory on that box.
Im using SQL Server 2005 fully patched.
Any ideas as to how to limit SQL Server to the actual 768Mb' (Yes I have
restarted - it doesnt help)
Thanks
Regards
Jonasthe overhead come from the application himself.
so to limit to 768Mb reduce the max memory to around 640mb
"Jonas Larsen" <JonasLarsen@.discussions.microsoft.com> wrote in message
news:D2269A45-7B92-4961-89D3-B067784403BF@.microsoft.com...
> Hello
> I have an SQL Server 2005 with limited resources therefore I have limited
> the max memory usage for SQL Server to 768 Mb however doesnt seem to make
> any
> difference. SQL Server is marrily taking 844,000 Kb of memory which then
> becomes an issue due to the lack of memory on that box.
> Im using SQL Server 2005 fully patched.
> Any ideas as to how to limit SQL Server to the actual 768Mb' (Yes I have
> restarted - it doesnt help)
>
> Thanks
> Regards
> Jonas
>
>|||There is a section of memory formally called the MemToLeave area that by
default can be as high as 386KB that gets allocated right off the top. The
MAX memory setting deals only with the buffer pool which does not include
the MemToLeave memory. So subtract 386 from the value you want to limit it
to and set the Max memory to that. You may find some minor play in those
numbers but that will ensure it doesn't use more than what you want.
--
Andrew J. Kelly SQL MVP
Solid Quality Mentors
"Jonas Larsen" <JonasLarsen@.discussions.microsoft.com> wrote in message
news:D2269A45-7B92-4961-89D3-B067784403BF@.microsoft.com...
> Hello
> I have an SQL Server 2005 with limited resources therefore I have limited
> the max memory usage for SQL Server to 768 Mb however doesnt seem to make
> any
> difference. SQL Server is marrily taking 844,000 Kb of memory which then
> becomes an issue due to the lack of memory on that box.
> Im using SQL Server 2005 fully patched.
> Any ideas as to how to limit SQL Server to the actual 768Mb' (Yes I have
> restarted - it doesnt help)
>
> Thanks
> Regards
> Jonas
>
>|||> default can be as high as 386KB that gets allocated right off the top. The
You meant MB instead of KB?
Linchi
"Andrew J. Kelly" wrote:
> There is a section of memory formally called the MemToLeave area that by
> default can be as high as 386KB that gets allocated right off the top. The
> MAX memory setting deals only with the buffer pool which does not include
> the MemToLeave memory. So subtract 386 from the value you want to limit it
> to and set the Max memory to that. You may find some minor play in those
> numbers but that will ensure it doesn't use more than what you want.
> --
> Andrew J. Kelly SQL MVP
> Solid Quality Mentors
>
> "Jonas Larsen" <JonasLarsen@.discussions.microsoft.com> wrote in message
> news:D2269A45-7B92-4961-89D3-B067784403BF@.microsoft.com...
> > Hello
> >
> > I have an SQL Server 2005 with limited resources therefore I have limited
> > the max memory usage for SQL Server to 768 Mb however doesnt seem to make
> > any
> > difference. SQL Server is marrily taking 844,000 Kb of memory which then
> > becomes an issue due to the lack of memory on that box.
> >
> > Im using SQL Server 2005 fully patched.
> >
> > Any ideas as to how to limit SQL Server to the actual 768Mb' (Yes I have
> > restarted - it doesnt help)
> >
> >
> > Thanks
> >
> > Regards
> > Jonas
> >
> >
> >
>|||Yes for sure. Thanks Linchi.
--
Andrew J. Kelly SQL MVP
Solid Quality Mentors
"Linchi Shea" <LinchiShea@.discussions.microsoft.com> wrote in message
news:DD4CDC0C-FC08-4507-9FBD-3A97024E70F4@.microsoft.com...
>> default can be as high as 386KB that gets allocated right off the top.
>> The
> You meant MB instead of KB?
> Linchi
> "Andrew J. Kelly" wrote:
>> There is a section of memory formally called the MemToLeave area that by
>> default can be as high as 386KB that gets allocated right off the top.
>> The
>> MAX memory setting deals only with the buffer pool which does not include
>> the MemToLeave memory. So subtract 386 from the value you want to limit
>> it
>> to and set the Max memory to that. You may find some minor play in those
>> numbers but that will ensure it doesn't use more than what you want.
>> --
>> Andrew J. Kelly SQL MVP
>> Solid Quality Mentors
>>
>> "Jonas Larsen" <JonasLarsen@.discussions.microsoft.com> wrote in message
>> news:D2269A45-7B92-4961-89D3-B067784403BF@.microsoft.com...
>> > Hello
>> >
>> > I have an SQL Server 2005 with limited resources therefore I have
>> > limited
>> > the max memory usage for SQL Server to 768 Mb however doesnt seem to
>> > make
>> > any
>> > difference. SQL Server is marrily taking 844,000 Kb of memory which
>> > then
>> > becomes an issue due to the lack of memory on that box.
>> >
>> > Im using SQL Server 2005 fully patched.
>> >
>> > Any ideas as to how to limit SQL Server to the actual 768Mb' (Yes I
>> > have
>> > restarted - it doesnt help)
>> >
>> >
>> > Thanks
>> >
>> > Regards
>> > Jonas
>> >
>> >
>> >
>>
Friday, March 23, 2012
Media question
I have a question i want's to make a website where people can upload media
files like movies short movies of a minut or 3 max. Can i store those media
files like mp3, mpg etc.. for instance in a sql-server database, or is this
not wise to do?
Thanx in advance.."mike" <me2u@.writeme.com> wrote in message
news:40c2e759$0$5167$3a628fcd@.reader1.nntp.hccnet. nl...
> Hi Folks..
> I have a question i want's to make a website where people can upload media
> files like movies short movies of a minut or 3 max. Can i store those
media
> files like mp3, mpg etc.. for instance in a sql-server database, or is
this
> not wise to do?
You're probably better of saving them as files with a link to them stored in
the db.
> Thanx in advance..
Monday, February 20, 2012
MDX Max function - can I retrieve information about the max number
I am trying to write a report for SSRS using an SSAS cube. I need to get the maximum number of received product at any one day by receival site. And, I also need to get the date the maximum occurred. At the moment I can get the maximum in any one day by site using the following:
with member [Measures].[Max Rec Tonnes] as Max(descendants([Calendar].[Fiscal Current by Week].currentmember,[Calendar].[Fiscal Current by Week].[Fiscal Day],self),[Measures].[Receival Tonnes])
select {[Measures].[Max Rec Tonnes]} on columns,
{descendants([Site Storage].[Active Sites].[Active Flag].&[True],[Site Storage].[Active Sites].[Site ID],self)} on rows
from [cube]
where [Calendar].[Fiscal Current by Week].[Fiscal Year].&[1]
Any ideas how I can get the date that the max occurred?
This would probably accomplish what you want (since I understand you want the day for each site with the max value of Receival Tonnes.
Select
{[Measures].[Max Rec Tonnes]} on columns,
Generate(
[Site Storage].[Active Sites].[Site ID].Members as [SiteSet],
TopCount(
([SiteSet].CurrentMember, [Calendar].[Fiscal Current by Week].[Fiscal Day].Members), 1,
[Measures].[Receival Tonnes]
)
)
on rows
from [cube]
where [Calendar].[Fiscal Current by Week].[Fiscal Year].&[1]
|||Thanks! That works really well. Now I just have to go back through my mdx books and try to understand what generate means!!