Friday, March 30, 2012
Help on string sorting
I have a customer table created in the mssql server 2000, in this table i am
using
customerid as "CUST_0001" and so on..
When i say order by on customerid column, the IDs are not sorted in a proper
way
Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
order by customerid puts "CUST_0010" in the second row. but it supposed to
in the 10thr row.
Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting on
this
column. but nothing helped.
Please advise me on this and what way it can be achived. I am not going to
change the format of the ID which i am storing. that confirmed. but i need
that to be sorted
in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are changed.
http://support.microsoft.com/default.aspx?scid=kb;en-us;322112
the above link where i looked to setting up the COLLATION.
Hope to receive your advice as soon. Its urgent.
--
With Regards,
Raghavendra MudugalPlease post a repro script.
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinpub.com
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
Hello
I have a customer table created in the mssql server 2000, in this table i am
using
customerid as "CUST_0001" and so on..
When i say order by on customerid column, the IDs are not sorted in a proper
way
Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
order by customerid puts "CUST_0010" in the second row. but it supposed to
in the 10thr row.
Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting on
this
column. but nothing helped.
Please advise me on this and what way it can be achived. I am not going to
change the format of the ID which i am storing. that confirmed. but i need
that to be sorted
in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are changed.
http://support.microsoft.com/default.aspx?scid=kb;en-us;322112
the above link where i looked to setting up the COLLATION.
Hope to receive your advice as soon. Its urgent.
--
With Regards,
Raghavendra Mudugal|||Hi
This does sounds like you have a binary collation and mixed case data. You
may want to change the collation to something more intuitive or use
something like:
SELECT customerid
FROM MyTable
ORDER BY customerid COLLATE Latin1_General_CI_AS
See http://www.aspfaq.com/etiquette.asp?id=5006 on how to post DDL and
sample data.
John
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
> Hello
> I have a customer table created in the mssql server 2000, in this table i
> am
> using
> customerid as "CUST_0001" and so on..
> When i say order by on customerid column, the IDs are not sorted in a
> proper
> way
> Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
> order by customerid puts "CUST_0010" in the second row. but it supposed to
> in the 10thr row.
> Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting
> on
> this
> column. but nothing helped.
> Please advise me on this and what way it can be achived. I am not going to
> change the format of the ID which i am storing. that confirmed. but i need
> that to be sorted
> in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are
> changed.
> http://support.microsoft.com/default.aspx?scid=kb;en-us;322112
> the above link where i looked to setting up the COLLATION.
> Hope to receive your advice as soon. Its urgent.
> --
> With Regards,
> Raghavendra Mudugal|||Hello John Bell,
Thanks for your reply.
I tried your suggetion,, but its not helping me in any way.
I looked in the "SQL Collation Name" list in SQL books on-line and tried
all names giving with that "customerid" column, but all resulted the same,
no difference at all. and its still showing the "CUST_0010" customer id
in the 2nd place.
please help.
--
With Regards,
Raghavendra Mudugal
"John Bell" wrote:
> Hi
> This does sounds like you have a binary collation and mixed case data. You
> may want to change the collation to something more intuitive or use
> something like:
> SELECT customerid
> FROM MyTable
> ORDER BY customerid COLLATE Latin1_General_CI_AS
> See http://www.aspfaq.com/etiquette.asp?id=5006 on how to post DDL and
> sample data.
> John
> "Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
> in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
> > Hello
> >
> > I have a customer table created in the mssql server 2000, in this table i
> > am
> > using
> > customerid as "CUST_0001" and so on..
> >
> > When i say order by on customerid column, the IDs are not sorted in a
> > proper
> > way
> >
> > Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
> > order by customerid puts "CUST_0010" in the second row. but it supposed to
> > in the 10thr row.
> >
> > Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting
> > on
> > this
> > column. but nothing helped.
> >
> > Please advise me on this and what way it can be achived. I am not going to
> > change the format of the ID which i am storing. that confirmed. but i need
> > that to be sorted
> > in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are
> > changed.
> >
> > http://support.microsoft.com/default.aspx?scid=kb;en-us;322112
> >
> > the above link where i looked to setting up the COLLATION.
> >
> > Hope to receive your advice as soon. Its urgent.
> > --
> > With Regards,
> > Raghavendra Mudugal
>
>|||If it always starts with CUST_ and it always ends with digits you could
do
order by convert(int,replace(CustomerID,'CUST_",''))
http://sqlservercode.blogspot.com/|||well an annoying cheat kinda way u could do it i suppose is in the slect
statement, sort out the integers with substring (CustomerID, 6,10)-(is that
right? i dont remember the format it was, anyway u get the concept, the
column name then the character it starts and character it ends and all should
be integers) and Cast() the whole thing as INT, and make is AS SortNumber or
something. THen order by SortNumber instead of costomerID
--
Message posted via SQLMonster.com
http://www.sqlmonster.com/Uwe/Forums.aspx/sql-server/200601/1|||Lol well SQL beat me to it but i recommend CAST function over CONVERT because
the books say that CONVERT was only used for backward compatibility and CAST
should perform faster and avoid getting obsolete in later SQL versions
--
Message posted via SQLMonster.com
http://www.sqlmonster.com/Uwe/Forums.aspx/sql-server/200601/1|||Hello,
And thanks for your reply. I am ok with this Idea, but is this the only way
to order the customerid just by taking those four digits and just sorting them
as numerical sort and use it?
Because, presently I have 1.5 to 1.6 lac of customers listed in the database.
And is that code works faster? I had no problems using the string sort in
SQL6.5, and i never used to convert the id to int . in 2000 lots of things are
changed.
Hope to receive your valuabel response as soon.
Thanks for your time.
--
With Regards,
Raghavendra Mudugal
"SQL" wrote:
> If it always starts with CUST_ and it always ends with digits you could
> do
> order by convert(int,replace(CustomerID,'CUST_",''))
> http://sqlservercode.blogspot.com/
>|||Hi
You may want to post DDL and sample that will re-create your problem.
John
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:8ED10297-AFDE-4502-AC78-6C2729BDA1FB@.microsoft.com...
> Hello,
> And thanks for your reply. I am ok with this Idea, but is this the only
> way
> to order the customerid just by taking those four digits and just sorting
> them
> as numerical sort and use it?
> Because, presently I have 1.5 to 1.6 lac of customers listed in the
> database.
> And is that code works faster? I had no problems using the string sort in
> SQL6.5, and i never used to convert the id to int . in 2000 lots of things
> are
> changed.
> Hope to receive your valuabel response as soon.
> Thanks for your time.
> --
> With Regards,
> Raghavendra Mudugal
>
> "SQL" wrote:
>> If it always starts with CUST_ and it always ends with digits you could
>> do
>> order by convert(int,replace(CustomerID,'CUST_",''))
>> http://sqlservercode.blogspot.com/
>>
Help on string sorting
I have a customer table created in the mssql server 2000, in this table i am
using
customerid as "CUST_0001" and so on..
When i say order by on customerid column, the IDs are not sorted in a proper
way
Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
order by customerid puts "CUST_0010" in the second row. but it supposed to
in the 10thr row.
Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting on
this
column. but nothing helped.
Please advise me on this and what way it can be achived. I am not going to
change the format of the ID which i am storing. that confirmed. but i need
that to be sorted
in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are changed.
http://support.microsoft.com/defaul...kb;en-us;322112
the above link where i looked to setting up the COLLATION.
Hope to receive your advice as soon. Its urgent.
--
With Regards,
Raghavendra MudugalPlease post a repro script.
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinpub.com
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
Hello
I have a customer table created in the mssql server 2000, in this table i am
using
customerid as "CUST_0001" and so on..
When i say order by on customerid column, the IDs are not sorted in a proper
way
Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
order by customerid puts "CUST_0010" in the second row. but it supposed to
in the 10thr row.
Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting on
this
column. but nothing helped.
Please advise me on this and what way it can be achived. I am not going to
change the format of the ID which i am storing. that confirmed. but i need
that to be sorted
in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are changed.
http://support.microsoft.com/defaul...kb;en-us;322112
the above link where i looked to setting up the COLLATION.
Hope to receive your advice as soon. Its urgent.
--
With Regards,
Raghavendra Mudugal|||Hi
This does sounds like you have a binary collation and mixed case data. You
may want to change the collation to something more intuitive or use
something like:
SELECT customerid
FROM MyTable
ORDER BY customerid COLLATE Latin1_General_CI_AS
See http://www.aspfaq.com/etiquette.asp?id=5006 on how to post DDL and
sample data.
John
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
> Hello
> I have a customer table created in the mssql server 2000, in this table i
> am
> using
> customerid as "CUST_0001" and so on..
> When i say order by on customerid column, the IDs are not sorted in a
> proper
> way
> Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
> order by customerid puts "CUST_0010" in the second row. but it supposed to
> in the 10thr row.
> Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting
> on
> this
> column. but nothing helped.
> Please advise me on this and what way it can be achived. I am not going to
> change the format of the ID which i am storing. that confirmed. but i need
> that to be sorted
> in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are
> changed.
> http://support.microsoft.com/defaul...kb;en-us;322112
> the above link where i looked to setting up the COLLATION.
> Hope to receive your advice as soon. Its urgent.
> --
> With Regards,
> Raghavendra Mudugal|||Hello John Bell,
Thanks for your reply.
I tried your suggetion,, but its not helping me in any way.
I looked in the "SQL Collation Name" list in SQL books on-line and tried
all names giving with that "customerid" column, but all resulted the same,
no difference at all. and its still showing the "CUST_0010" customer id
in the 2nd place.
please help.
With Regards,
Raghavendra Mudugal
"John Bell" wrote:
> Hi
> This does sounds like you have a binary collation and mixed case data. You
> may want to change the collation to something more intuitive or use
> something like:
> SELECT customerid
> FROM MyTable
> ORDER BY customerid COLLATE Latin1_General_CI_AS
> See http://www.aspfaq.com/etiquette.asp?id=5006 on how to post DDL and
> sample data.
> John
> "Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
> in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
>
>|||If it always starts with CUST_ and it always ends with digits you could
do
order by convert(int,replace(CustomerID,'CUST_",''))
http://sqlservercode.blogspot.com/|||well an annoying cheat kinda way u could do it i suppose is in the slect
statement, sort out the integers with substring (CustomerID, 6,10)-(is that
right? i dont remember the format it was, anyway u get the concept, the
column name then the character it starts and character it ends and all shoul
d
be integers) and Cast() the whole thing as INT, and make is AS SortNumber or
something. THen order by SortNumber instead of costomerID
Message posted via droptable.com
http://www.droptable.com/Uwe/Forum...server/200601/1|||Lol well SQL beat me to it but i recommend CAST function over CONVERT becaus
e
the books say that CONVERT was only used for backward compatibility and CAST
should perform faster and avoid getting obsolete in later SQL versions
Message posted via droptable.com
http://www.droptable.com/Uwe/Forum...server/200601/1|||Hello,
And thanks for your reply. I am ok with this Idea, but is this the only way
to order the customerid just by taking those four digits and just sorting th
em
as numerical sort and use it?
Because, presently I have 1.5 to 1.6 lac of customers listed in the database
.
And is that code works faster? I had no problems using the string sort in
SQL6.5, and i never used to convert the id to int . in 2000 lots of things a
re
changed.
Hope to receive your valuabel response as soon.
Thanks for your time.
--
With Regards,
Raghavendra Mudugal
"SQL" wrote:
> If it always starts with CUST_ and it always ends with digits you could
> do
> order by convert(int,replace(CustomerID,'CUST_",''))
> http://sqlservercode.blogspot.com/
>|||Hi
You may want to post DDL and sample that will re-create your problem.
John
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:8ED10297-AFDE-4502-AC78-6C2729BDA1FB@.microsoft.com...[vbcol=seagreen]
> Hello,
> And thanks for your reply. I am ok with this Idea, but is this the only
> way
> to order the customerid just by taking those four digits and just sorting
> them
> as numerical sort and use it?
> Because, presently I have 1.5 to 1.6 lac of customers listed in the
> database.
> And is that code works faster? I had no problems using the string sort in
> SQL6.5, and i never used to convert the id to int . in 2000 lots of things
> are
> changed.
> Hope to receive your valuabel response as soon.
> Thanks for your time.
> --
> With Regards,
> Raghavendra Mudugal
>
> "SQL" wrote:
>sql
Help on string sorting
I have a customer table created in the mssql server 2000, in this table i am
using
customerid as "CUST_0001" and so on..
When i say order by on customerid column, the IDs are not sorted in a proper
way
Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
order by customerid puts "CUST_0010" in the second row. but it supposed to
in the 10thr row.
Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting on
this
column. but nothing helped.
Please advise me on this and what way it can be achived. I am not going to
change the format of the ID which i am storing. that confirmed. but i need
that to be sorted
in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are changed.
http://support.microsoft.com/default...b;en-us;322112
the above link where i looked to setting up the COLLATION.
Hope to receive your advice as soon. Its urgent.
With Regards,
Raghavendra Mudugal
Please post a repro script.
Tom
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinpub.com
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
Hello
I have a customer table created in the mssql server 2000, in this table i am
using
customerid as "CUST_0001" and so on..
When i say order by on customerid column, the IDs are not sorted in a proper
way
Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
order by customerid puts "CUST_0010" in the second row. but it supposed to
in the 10thr row.
Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting on
this
column. but nothing helped.
Please advise me on this and what way it can be achived. I am not going to
change the format of the ID which i am storing. that confirmed. but i need
that to be sorted
in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are changed.
http://support.microsoft.com/default...b;en-us;322112
the above link where i looked to setting up the COLLATION.
Hope to receive your advice as soon. Its urgent.
With Regards,
Raghavendra Mudugal
|||Hi
This does sounds like you have a binary collation and mixed case data. You
may want to change the collation to something more intuitive or use
something like:
SELECT customerid
FROM MyTable
ORDER BY customerid COLLATE Latin1_General_CI_AS
See http://www.aspfaq.com/etiquette.asp?id=5006 on how to post DDL and
sample data.
John
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
> Hello
> I have a customer table created in the mssql server 2000, in this table i
> am
> using
> customerid as "CUST_0001" and so on..
> When i say order by on customerid column, the IDs are not sorted in a
> proper
> way
> Say for e.g if i have 10 customers list as "CUST_0001" to "CUST_0010" then
> order by customerid puts "CUST_0010" in the second row. but it supposed to
> in the 10thr row.
> Even I tried setting the Collation to 30 and 50 BIN and Latin BIN sorting
> on
> this
> column. but nothing helped.
> Please advise me on this and what way it can be achived. I am not going to
> change the format of the ID which i am storing. that confirmed. but i need
> that to be sorted
> in proper way. But this was fine with SQL 6.5, in SQL 2000 lots are
> changed.
> http://support.microsoft.com/default...b;en-us;322112
> the above link where i looked to setting up the COLLATION.
> Hope to receive your advice as soon. Its urgent.
> --
> With Regards,
> Raghavendra Mudugal
|||Hello John Bell,
Thanks for your reply.
I tried your suggetion,, but its not helping me in any way.
I looked in the "SQL Collation Name" list in SQL books on-line and tried
all names giving with that "customerid" column, but all resulted the same,
no difference at all. and its still showing the "CUST_0010" customer id
in the 2nd place.
please help.
With Regards,
Raghavendra Mudugal
"John Bell" wrote:
> Hi
> This does sounds like you have a binary collation and mixed case data. You
> may want to change the collation to something more intuitive or use
> something like:
> SELECT customerid
> FROM MyTable
> ORDER BY customerid COLLATE Latin1_General_CI_AS
> See http://www.aspfaq.com/etiquette.asp?id=5006 on how to post DDL and
> sample data.
> John
> "Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
> in message news:EF13C28C-FE05-4F89-9181-EE3A649C9627@.microsoft.com...
>
>
|||If it always starts with CUST_ and it always ends with digits you could
do
order by convert(int,replace(CustomerID,'CUST_",''))
http://sqlservercode.blogspot.com/
|||well an annoying cheat kinda way u could do it i suppose is in the slect
statement, sort out the integers with substring (CustomerID, 6,10)-(is that
right? i dont remember the format it was, anyway u get the concept, the
column name then the character it starts and character it ends and all should
be integers) and Cast() the whole thing as INT, and make is AS SortNumber or
something. THen order by SortNumber instead of costomerID
Message posted via droptable.com
http://www.droptable.com/Uwe/Forums...erver/200601/1
|||Lol well SQL beat me to it but i recommend CAST function over CONVERT because
the books say that CONVERT was only used for backward compatibility and CAST
should perform faster and avoid getting obsolete in later SQL versions
Message posted via droptable.com
http://www.droptable.com/Uwe/Forums...erver/200601/1
|||Hello,
And thanks for your reply. I am ok with this Idea, but is this the only way
to order the customerid just by taking those four digits and just sorting them
as numerical sort and use it?
Because, presently I have 1.5 to 1.6 lac of customers listed in the database.
And is that code works faster? I had no problems using the string sort in
SQL6.5, and i never used to convert the id to int . in 2000 lots of things are
changed.
Hope to receive your valuabel response as soon.
Thanks for your time.
With Regards,
Raghavendra Mudugal
"SQL" wrote:
> If it always starts with CUST_ and it always ends with digits you could
> do
> order by convert(int,replace(CustomerID,'CUST_",''))
> http://sqlservercode.blogspot.com/
>
|||Hi
You may want to post DDL and sample that will re-create your problem.
John
"Raghavendra Mudugal" <RaghavendraMudugal@.discussions.microsoft.com> wrote
in message news:8ED10297-AFDE-4502-AC78-6C2729BDA1FB@.microsoft.com...[vbcol=seagreen]
> Hello,
> And thanks for your reply. I am ok with this Idea, but is this the only
> way
> to order the customerid just by taking those four digits and just sorting
> them
> as numerical sort and use it?
> Because, presently I have 1.5 to 1.6 lac of customers listed in the
> database.
> And is that code works faster? I had no problems using the string sort in
> SQL6.5, and i never used to convert the id to int . in 2000 lots of things
> are
> changed.
> Hope to receive your valuabel response as soon.
> Thanks for your time.
> --
> With Regards,
> Raghavendra Mudugal
>
> "SQL" wrote:
Wednesday, March 28, 2012
Help on setting up connection string
I'm using VWD on SQL2005EXPRESS And i keep getting a connection string error
Can someone show me how to put a connection string in the web.config, or which connection string to use to connect to my host database which they're running SQL2000..
Thanks Newbie
Seehttp://www.connectionstrings.com.|||I did went to that site, and i have try some their method and it didn't work. i still get a error
I'd like to see what the web.config file suppose to look like with the connection string written in it
|||<?xml version="1.0" ?><configuration>
<connectionStrings>
<add name="MyConnectionString" connectionString="server=(local)\SQLSERVEREXPRESS_INSTANCENAME;database=MyDatabase;uid=myusername;password=mypassword" />
</connectionStrings>
</configuration>|||
This is my web.config file.Could you please tell me what is the problem with it.
Thanks Newbie
<?xmlversion="1.0"?>
<configurationxmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<system.web>
<customErrorsmode="ON"/>
<compilationdebug="true" />
<tracelocalOnly="false"mostRecent="true"pageOutput="true" />
<roleManagerenabled="true"/>
<authenticationmode="Forms"/>
</system.web>
</configuration>
|||If you compare it to mine, you'll notice you're missing the connectionStrings element as well as a connection string.|||Ok" i have seen the different. But how do i know which elemet and connection string to use . I have seen some many different connection string and element . So how do one detemine which one to use for their website and database.
I'm using SQL 05 EXPRESS and my host is using SQL 2000, so how would i know which string and element to use.? I' m new to this ,so some of the terms and language i dont understand.
|||The connection string I used in an example above will work for SQL Server Express. When using SQL Server Express, you have to name the instance (i.e. (local)\SQLEXPRESS). With SQL Server 2000, you should be fine without naming the instance as long as there are not multiple instances of SQL Server on the box (i.e. (local)).|||
One more thing. I did attemp to do scott configure on changing SQL express to SQL2000 or 2005 and i did settup up vwd to appservicedb.
Is there a way, to see if i'm running SQL express or SQL server 2005 express?
O, k if i'm running SQL EXPRESS i could use the string above and it would work?
Thanks you
|||
Just have question.How do i determine what my instance is?
And in your connection string i 'd put my database name where it stated my database, and for my (local)\SQLEXPRESS). INSTANCE how do i know what to put for the instance?
Friday, March 23, 2012
Help on deviceInfo in rs.Render please...
deviceInfo = String.Format("Margins', Scale')
Thanks,
TrintTrint,
Unfortunately there does not appear to be any way to specify DeviceInfo
with rs.Render. This is an issue for us because we cannot specify the
delimiter to be used for CSV.
Bob
"trint" wrote:
> How can I set my margins and all my page setup with this string please?
> deviceInfo = String.Format("Margins', Scale')
> Thanks,
> Trint
>|||So, I have no way of setting up the way my page is to be rendered?
thanks,
Trint
bobhug wrote:
> Trint,
> Unfortunately there does not appear to be any way to specify
DeviceInfo
> with rs.Render. This is an issue for us because we cannot specify the
> delimiter to be used for CSV.
> Bob
> "trint" wrote:
> > How can I set my margins and all my page setup with this string
please?
> > deviceInfo = String.Format("Margins', Scale')
> > Thanks,
> > Trint
> >
> >|||Sorry, my previous post was a mistake :>(. Please ignore it.
Bob
"bobhug" wrote:
> Trint,
> Unfortunately there does not appear to be any way to specify DeviceInfo
> with rs.Render. This is an issue for us because we cannot specify the
> delimiter to be used for CSV.
> Bob
> "trint" wrote:
> > How can I set my margins and all my page setup with this string please?
> > deviceInfo = String.Format("Margins', Scale')
> > Thanks,
> > Trint
> >
> >|||You use the DeviceInfo parameter. It is an XML string that has the settings
for the rendering extension. The properties supported are documented in
Books Online.
--
Brian Welcker
Group Program Manager
SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"trint" <trinity.smith@.gmail.com> wrote in message
news:1106585573.383643.243230@.c13g2000cwb.googlegroups.com...
> So, I have no way of setting up the way my page is to be rendered?
> thanks,
> Trint
> bobhug wrote:
>> Trint,
>> Unfortunately there does not appear to be any way to specify
> DeviceInfo
>> with rs.Render. This is an issue for us because we cannot specify the
>> delimiter to be used for CSV.
>> Bob
>> "trint" wrote:
>> > How can I set my margins and all my page setup with this string
> please?
>> > deviceInfo = String.Format("Margins', Scale')
>> > Thanks,
>> > Trint
>> >
>> >
>|||I know...but what I want to know is if the problem of 'emf' not
printing the footer of my report, when rendered to an 'emf', can
somehow be overcome by an xml code of some type besides what I have in
there now?:
deviceInfo =String.Format(@."<DeviceInfo>" +
"<OutputFormat>{0}</OutputFormat>" +
"<Toolbar>False</Toolbar>" +
"<PageHeight>55.82cm</PageHeight>" +
"<PageWidth>40.26cm</PageWidth></DeviceInfo>","emf");
thanks,
Trint
Monday, February 27, 2012
help me!
now i got this error. please help me. i think it is the error of IIS.
Server Error in '/' Application.
String or binary data would be truncated.The statement has been terminated.
Description:Anunhandled exception occurred during the execution of the current webrequest. Please review the stack trace for more information about theerror and where it originated in the code.Exception Details:System.Data.SqlClient.SqlException: String or binary data would be truncated.The statement has been terminated.
Source Error:
The source code that generated this unhandled exception can only beshown when compiled in debug mode. To enable this, please follow one ofthe below steps, then request the URL:
1. Add a "Debug=true" directive at the top of the file that generated the error. Example:
<%@. Page Language="C#" Debug="true" %>
or:
2) Add the following section to the configuration file of your application:
<configuration>
<system.web>
<compilation debug="true"/>
</system.web>
</configuration>
Note that this second technique will cause all files within a givenapplication to be compiled in debug mode. The first technique willcause only that particular file to be compiled in debug mode.
Important:Running applications in debug mode does incur a memory/performanceoverhead. You should make sure that an application has debuggingdisabled before deploying into production scenario.Apparently your application is trying to store a value into the database that is larger than the target field, as indicated by the detail:
Exception Details:System.Data.SqlClient.SqlException: String or binary data would be truncated. The statement has been terminated.
Try adding the debug statement to your page to help with tracking down exactly where this is taking place.
regards,