Friday, February 24, 2012
Dash in search string
CONTAINSTABLE function? It's the behavior I see but I cannot find any text in
BOL that specify this.
This gives lots of rows:
SELECT k.KEY, * FROM ContainsTable(Request,*,N'ISSI-2007-0')
This gives no of rows:
SELECT k.KEY, * FROM ContainsTable(Request,*,N'ISSI-2007-00')
But I know that from the first resultset, full-text indexed column include
data that start with 'ISSI-2007-00'...
I would like that someone can confirm this behavior and let me know where I
can find ducomentation on that "-" behavior!
David, MCDBA
For the most part it is throw away. The rules vary from language to language
though. Basically it is broken as ISSI and 2007 and 0 (for ISSI-2007-0), and
ISSI 2007 and 00 for the second one.
I get different results from you.
create table david(pk int identity not null constraint davidpk primary key ,
charcol varchar(20))
GO
create fulltext index on david(charcol) key index davidpk
GO
insert into david(charcol) values('ISSI-2007-0')
insert into david(charcol) values('ISSI-2007-00')
GO
select * from david where contains(*,'ISSI-2007-0')--both found
GO
select * from david where contains(*,'ISSI-2007-00')--only the second is
found
GO
RelevantNoise.com - dedicated to mining blogs for business intelligence.
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"David Parenteau" <DavidParenteau@.discussions.microsoft.com> wrote in
message news:F80F130B-78F1-4942-89AA-589E6419DCB7@.microsoft.com...
> Is it posible that dashes "-" are considering as punctuation when using
> CONTAINSTABLE function? It's the behavior I see but I cannot find any text
> in
> BOL that specify this.
> This gives lots of rows:
> SELECT k.KEY, * FROM ContainsTable(Request,*,N'ISSI-2007-0')
> This gives no of rows:
> SELECT k.KEY, * FROM ContainsTable(Request,*,N'ISSI-2007-00')
> But I know that from the first resultset, full-text indexed column include
> data that start with 'ISSI-2007-00'...
> I would like that someone can confirm this behavior and let me know where
> I
> can find ducomentation on that "-" behavior!
> David, MCDBA
DAO and SQL server
SQL server. All the code is in DAO, are there any known
incompatibilities WRT SQL server and DAO?
Many thanks
SiSd (sd_bradford@.hotmail.com) writes:
> We are considering migrating a large piece of VB code from Access to
> SQL server. All the code is in DAO, are there any known
> incompatibilities WRT SQL server and DAO?
I have never used DAO, but a colleague of mine told me the other day,
that DAO was designed for Access, and is cumbersome to use with SQL Server.
In any case, DAO is old technology, and I would suspect that you don't get
full support for newer features in SQL Server with DAO, but I could be wrong
on that particular point. Nevertheless, I would consider ripping out DAO
in favour of ADO which is more up to date. Admittedly, I find ADO quite
ugly as well, and ADO .Net is a lot more palatable. That would however call
for a migration to VB .Net, which may be an overkill.
--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp|||"Sd" <sd_bradford@.hotmail.com> wrote in message
news:e66eafb3.0412200220.17a18286@.posting.google.c om...
> We are considering migrating a large piece of VB code from Access to
> SQL server. All the code is in DAO, are there any known
> incompatibilities WRT SQL server and DAO?
> Many thanks
> Si
There's stuff you can do with tables and queries which would probably cause
a problem.
You can forget compact and repair operations.
Table search is potentially a problem as you'll minimum have to switch to
(SQL) attached tables.
Hopefully the code and data is already split between two databases?
If you just use a bunch of selects and inserts then they're quite possibly
going to be relatively painless to convert.
If you have to do it anyhow.
I would suggest create corresponding sql tables manually.
Perhaps start off using DTS to load em in and see what you get.
Attach these to a copy of your code database.
Give it a twirl and see what happens.
--
Regards,
Andy O'Neill