I setup merge, but when it was attempting to connect to the subscriber I
received an error (don't know exact text) about not being able to find
column rowguidcol. I ran:
SELECT name FROM syscolumns
And found lots of entries for rowguidcol, which is odd because I don't
name it that (each rowguid column in my table have unique names specific
to the table).
What command can I type to figure out what tables these rowguidcol's are
in?
Thank
Darin
*** Sent via Developersdex http://www.codecomments.com ***
Darin,
are you doing a nosync initialization? If so, it looks like the schema on
the publisher and subscriber are different. A rowguid column (with the
rowguid attribute) will be added to the replicated articles if it doesn't
already exist, and this should happen automatically.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
|||I am doing a nosync. The rowguid isn't being added (shouldn't be) since
all of my tables have rowguid column, but it is named (some examples),
ccst_rowguid, chst_rowguid, etc. This is what is confusing me.
I would say the schema should be the same because he (the customer) says
he is copying the data from one computer to the other, then I am setting
up replication.
Darin
*** Sent via Developersdex http://www.codecomments.com ***
|||OK - then adding the rowguid property to the table on the publisher and the
subscriber to the identical table should make it ok.
Cheers,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
sql
Showing posts with label text. Show all posts
Showing posts with label text. Show all posts
Wednesday, March 28, 2012
merge error rowguidcol
Merge Different Data Types in Query
I need to merge a numeric field (ID) with the varchar field (description) in
my query. Any idea how I can do this?
ID DESC
22 Text here
20 Text Here
Query Date to be: "(22) Text"
Thanks in advance!!You can use CAST, CONVERT or STR function to do this. For details of these
function, pl. refer to SQL Server Books Online.
SELECT '"' + CAST( id AS VARCHAR ) + SPACE( 3 ) +
desc + '"'
FROM tbl ;
Anith|||Anith,
This is awesome. I am looking into this function as we speak. However, I
ran your suggestion and it does exactly what I want except it has 'Select '
before the data as part of the field. Anyway around this?
Example:
"Select 1999 Short Description" instead of "1999 short description"
"Anith Sen" wrote:
> You can use CAST, CONVERT or STR function to do this. For details of these
> function, pl. refer to SQL Server Books Online.
> SELECT '"' + CAST( id AS VARCHAR ) + SPACE( 3 ) +
> desc + '"'
> FROM tbl ;
> --
> Anith
>
>|||I think you have quotes messed up somewhere. Without a table DDL & sample
data it is hard to point out the issue. Also it may have something to do
with the wrapper code/interface/client programming language you may be
using. Here is an example to check it out in Query Analyzer:
CREATE TABLE tbl ( id_ INT NOT NULL PRIMARY KEY,
descr_ VARCHAR(50) NOT NULL );
INSERT tbl SELECT 1999, 'short description' ;
SELECT '"' + CAST( id_ AS VARCHAR ) + SPACE( 3 ) + descr_ + '"'
FROM tbl ;
Anith|||Here is the Query I'm using in the view:
SELECT DISTINCT
TOP 100 PERCENT dbo.IssueSubType.IssueSubTypeID,
dbo.IssueSubType.IssueSubTypeTitle, dbo.IssueType.IssueTypeID,
'SELECT ' + CAST(dbo.Issue.IssueID AS VarChar) +
SPACE(2) + dbo.Issue.ShortDescription + '' AS Expr1, dbo.Issue.IssueID
FROM dbo.IssueType INNER JOIN
dbo.IssueSubType ON dbo.IssueType.IssueTypeID =
dbo.IssueSubType.IssueTypeID INNER JOIN
dbo.Issue ON dbo.IssueType.IssueTypeID =
dbo.Issue.IssueTypeID AND dbo.IssueSubType.IssueSubTypeID =
dbo.Issue.IssueSubTypeID
WHERE (dbo.IssueType.IssueTypeID = 16)
ORDER BY dbo.IssueSubType.IssueSubTypeID
"Anith Sen" wrote:
> I think you have quotes messed up somewhere. Without a table DDL & sample
> data it is hard to point out the issue. Also it may have something to do
> with the wrapper code/interface/client programming language you may be
> using. Here is an example to check it out in Query Analyzer:
> CREATE TABLE tbl ( id_ INT NOT NULL PRIMARY KEY,
> descr_ VARCHAR(50) NOT NULL );
> INSERT tbl SELECT 1999, 'short description' ;
> SELECT '"' + CAST( id_ AS VARCHAR ) + SPACE( 3 ) + descr_ + '"'
> FROM tbl ;
> --
> Anith
>
>|||Remove the part >> 'SELECT ' + << from your query.
Also, as a suggestion, remove TOP 100 & ORDER BY from the view. It offers
nothing beneficial & could cause optimization issues when used in complex
queries.
If an ordered resultset is the intention, consider using ORDER BY clause in
the query using the view instead.
Anith|||That was it. I tried various combinations of that but never that. Thanks
for your help!!!
"Anith Sen" wrote:
> Remove the part >> 'SELECT ' + << from your query.
> Also, as a suggestion, remove TOP 100 & ORDER BY from the view. It offers
> nothing beneficial & could cause optimization issues when used in complex
> queries.
> If an ordered resultset is the intention, consider using ORDER BY clause i
n
> the query using the view instead.
> --
> Anith
>
>
my query. Any idea how I can do this?
ID DESC
22 Text here
20 Text Here
Query Date to be: "(22) Text"
Thanks in advance!!You can use CAST, CONVERT or STR function to do this. For details of these
function, pl. refer to SQL Server Books Online.
SELECT '"' + CAST( id AS VARCHAR ) + SPACE( 3 ) +
desc + '"'
FROM tbl ;
Anith|||Anith,
This is awesome. I am looking into this function as we speak. However, I
ran your suggestion and it does exactly what I want except it has 'Select '
before the data as part of the field. Anyway around this?
Example:
"Select 1999 Short Description" instead of "1999 short description"
"Anith Sen" wrote:
> You can use CAST, CONVERT or STR function to do this. For details of these
> function, pl. refer to SQL Server Books Online.
> SELECT '"' + CAST( id AS VARCHAR ) + SPACE( 3 ) +
> desc + '"'
> FROM tbl ;
> --
> Anith
>
>|||I think you have quotes messed up somewhere. Without a table DDL & sample
data it is hard to point out the issue. Also it may have something to do
with the wrapper code/interface/client programming language you may be
using. Here is an example to check it out in Query Analyzer:
CREATE TABLE tbl ( id_ INT NOT NULL PRIMARY KEY,
descr_ VARCHAR(50) NOT NULL );
INSERT tbl SELECT 1999, 'short description' ;
SELECT '"' + CAST( id_ AS VARCHAR ) + SPACE( 3 ) + descr_ + '"'
FROM tbl ;
Anith|||Here is the Query I'm using in the view:
SELECT DISTINCT
TOP 100 PERCENT dbo.IssueSubType.IssueSubTypeID,
dbo.IssueSubType.IssueSubTypeTitle, dbo.IssueType.IssueTypeID,
'SELECT ' + CAST(dbo.Issue.IssueID AS VarChar) +
SPACE(2) + dbo.Issue.ShortDescription + '' AS Expr1, dbo.Issue.IssueID
FROM dbo.IssueType INNER JOIN
dbo.IssueSubType ON dbo.IssueType.IssueTypeID =
dbo.IssueSubType.IssueTypeID INNER JOIN
dbo.Issue ON dbo.IssueType.IssueTypeID =
dbo.Issue.IssueTypeID AND dbo.IssueSubType.IssueSubTypeID =
dbo.Issue.IssueSubTypeID
WHERE (dbo.IssueType.IssueTypeID = 16)
ORDER BY dbo.IssueSubType.IssueSubTypeID
"Anith Sen" wrote:
> I think you have quotes messed up somewhere. Without a table DDL & sample
> data it is hard to point out the issue. Also it may have something to do
> with the wrapper code/interface/client programming language you may be
> using. Here is an example to check it out in Query Analyzer:
> CREATE TABLE tbl ( id_ INT NOT NULL PRIMARY KEY,
> descr_ VARCHAR(50) NOT NULL );
> INSERT tbl SELECT 1999, 'short description' ;
> SELECT '"' + CAST( id_ AS VARCHAR ) + SPACE( 3 ) + descr_ + '"'
> FROM tbl ;
> --
> Anith
>
>|||Remove the part >> 'SELECT ' + << from your query.
Also, as a suggestion, remove TOP 100 & ORDER BY from the view. It offers
nothing beneficial & could cause optimization issues when used in complex
queries.
If an ordered resultset is the intention, consider using ORDER BY clause in
the query using the view instead.
Anith|||That was it. I tried various combinations of that but never that. Thanks
for your help!!!
"Anith Sen" wrote:
> Remove the part >> 'SELECT ' + << from your query.
> Also, as a suggestion, remove TOP 100 & ORDER BY from the view. It offers
> nothing beneficial & could cause optimization issues when used in complex
> queries.
> If an ordered resultset is the intention, consider using ORDER BY clause i
n
> the query using the view instead.
> --
> Anith
>
>
Friday, February 24, 2012
Memory optimization
Hi
We are running full text search with 4GB RAM on SQL server 2000. Ihave the
/3G option on in boot.ini. The VM setting is set at 2048 to 4095.
I read it in the manual that the optimal configuration for full text search
is
1. The virtual memory size to at least 3 times the physical memory installed
in the computer.
2. The SQL Server max server memory server configuration option to 1.5 times
the physical memory (half the virtual memory size setting).
Questions:
1. How do I set max sql server memory to 1.5 times physical memory? Max
memory that SQL server allows us to set is 4095 MB? Is this only possible
with AWE?
2. My observation when I made the VM 3X the physical, was that the full text
queries were slower.
What are the right settings and what am I doing wrong?
Matt
Hi
Can any body throw some ideas on this one?
MM
"ISTS" wrote:
> Hi
> We are running full text search with 4GB RAM on SQL server 2000. Ihave the
> /3G option on in boot.ini. The VM setting is set at 2048 to 4095.
> I read it in the manual that the optimal configuration for full text search
> is
> 1. The virtual memory size to at least 3 times the physical memory installed
> in the computer.
> 2. The SQL Server max server memory server configuration option to 1.5 times
> the physical memory (half the virtual memory size setting).
> Questions:
> 1. How do I set max sql server memory to 1.5 times physical memory? Max
> memory that SQL server allows us to set is 4095 MB? Is this only possible
> with AWE?
> 2. My observation when I made the VM 3X the physical, was that the full text
> queries were slower.
> What are the right settings and what am I doing wrong?
> --
> Matt
We are running full text search with 4GB RAM on SQL server 2000. Ihave the
/3G option on in boot.ini. The VM setting is set at 2048 to 4095.
I read it in the manual that the optimal configuration for full text search
is
1. The virtual memory size to at least 3 times the physical memory installed
in the computer.
2. The SQL Server max server memory server configuration option to 1.5 times
the physical memory (half the virtual memory size setting).
Questions:
1. How do I set max sql server memory to 1.5 times physical memory? Max
memory that SQL server allows us to set is 4095 MB? Is this only possible
with AWE?
2. My observation when I made the VM 3X the physical, was that the full text
queries were slower.
What are the right settings and what am I doing wrong?
Matt
Hi
Can any body throw some ideas on this one?
MM
"ISTS" wrote:
> Hi
> We are running full text search with 4GB RAM on SQL server 2000. Ihave the
> /3G option on in boot.ini. The VM setting is set at 2048 to 4095.
> I read it in the manual that the optimal configuration for full text search
> is
> 1. The virtual memory size to at least 3 times the physical memory installed
> in the computer.
> 2. The SQL Server max server memory server configuration option to 1.5 times
> the physical memory (half the virtual memory size setting).
> Questions:
> 1. How do I set max sql server memory to 1.5 times physical memory? Max
> memory that SQL server allows us to set is 4095 MB? Is this only possible
> with AWE?
> 2. My observation when I made the VM 3X the physical, was that the full text
> queries were slower.
> What are the right settings and what am I doing wrong?
> --
> Matt
Subscribe to:
Posts (Atom)