Hi I've been given a project that requires me to produce a users friendly web base administarion menu that creates a new customer for one of our systems.
The problem is this Project it needs to create a database for each user, in SQL server 2000. This has me stumpted, has anybody ever done this before and could they point me in the correct direction! The majority of our administration menu are written in ASP but any help automating this procedure would be useful.
Thanks a lot, EdYou can create a database simply using the T-SQL command
CREATE DATABASE
that can be invoked as any other command from your client.
You can also use it in a Stored Procedure.|||Originally posted by manowar
You can create a database simply using the T-SQL command
CREATE DATABASE
that can be invoked as any other command from your client.
You can also use it in a Stored Procedure.
Excellent, thanks
Showing posts with label creates. Show all posts
Showing posts with label creates. Show all posts
Friday, March 30, 2012
Friday, March 9, 2012
HELP - Storing Full Text Catalog to Different Location
Hi,
I am building a database install aplication that among all other
stuff, creates and populates full-text catalogs for my database.
All this is done in VB.net and SQL Server 2003
My application works fine, here is the come sample:
oSQLServer = CreateObject("SQLDMO.SQLServer")
oSQLServer.connect(strServer, strUserID, strPassword)
' enable full-text indexing for provided database
oSQLServer.Databases(strDBName).EnableFullTextCata logs()
' create full text catalog and add it to the collection
Dim strFullTextCatalogName As String
strFullTextCatalogName = strCatalogPrefix & "_documenttitle"
oFullTextCatalog = CreateObject("SQLDMO.FullTextCatalog")
oFullTextCatalog.Name = strFullTextCatalogName 'name
oFullTextCatalog.RootPath = strCatalogPath 'location
' create full-text catalog on the server and add it to
' the collection of full-text catalogs
oSQLServer.databases(strDBName).fulltextcatalogs.a dd(oFullTextCatalog)
However, I get an System.Runtime.InteropServices.COMException
exception with additional information as:
Additional information:[Microsoft][ODBC SQL Server Driver][SQL
Server]Access is denied to 'C:\Documents and
Settings\username\MyDocuments', or the path is invalid. Full-text
search was not installed properly.
The path to which access is denied is the value of my variable
strCatalogPath that I assign to my full-text catalog RootPath
property. (see code sample above)
How can I fix this error. Please help.
Any help will be appreciated,
_dino_
Dino,
Well, the error message is clear "Access is denied to 'C:\Documents and
Settings\username\MyDocuments', or the path is invalid."
Did you try using sp_fulltext_catalog and create a FT Catalog using the same
path? or perhaps specifically reference 'C:\Program Files\Microsoft SQL
Server\Mssql\Ftdata' enclosed in double quotes? Do the folders "username"
or "MyDocuments" exist?
SQL Server BOL title "sp_fulltext_catalog" for the path states
"[@.path =] 'root_directory'
Is the root directory (not the complete physical path) for a create action.
root_directory is nvarchar(100) and has a default value of NULL, which
indicates the use of the default location specified at setup. This is the
Ftdata subdirectory in the Mssql directory; for example, C:\Program
Files\Microsoft SQL Server\Mssql\Ftdata. The specified root directory must
reside on a drive on the same computer, consist of more than just the drive
letter, and cannot be a relative path. Network drives, removable drives,
floppy disks, and UNC paths are not supported. Full-text catalogs must be
created on a local hard drive associated with an instance of Microsoft SQL
ServerT.
@.path is valid only when action is create. For actions other than create
(stop, rebuild, and so on), @.path must be NULL or omitted."
Hope that helps!
John
SQL Full Text Search Blog
http://spaces.msn.com/members/jtkane/
"Dino Buljubasic" <dino@.noplacelikehome.com> wrote in message
news:fs05f1lapksvfr4i0lgot578hubm1te3gj@.4ax.com...
> Hi,
> I am building a database install aplication that among all other
> stuff, creates and populates full-text catalogs for my database.
> All this is done in VB.net and SQL Server 2003
> My application works fine, here is the come sample:
> oSQLServer = CreateObject("SQLDMO.SQLServer")
> oSQLServer.connect(strServer, strUserID, strPassword)
> ' enable full-text indexing for provided database
> oSQLServer.Databases(strDBName).EnableFullTextCata logs()
> ' create full text catalog and add it to the collection
> Dim strFullTextCatalogName As String
> strFullTextCatalogName = strCatalogPrefix & "_documenttitle"
> oFullTextCatalog = CreateObject("SQLDMO.FullTextCatalog")
> oFullTextCatalog.Name = strFullTextCatalogName 'name
> oFullTextCatalog.RootPath = strCatalogPath 'location
>
> ' create full-text catalog on the server and add it to
> ' the collection of full-text catalogs
> oSQLServer.databases(strDBName).fulltextcatalogs.a dd(oFullTextCatalog)
> However, I get an System.Runtime.InteropServices.COMException
> exception with additional information as:
> Additional information:[Microsoft][ODBC SQL Server Driver][SQL
> Server]Access is denied to 'C:\Documents and
> Settings\username\MyDocuments', or the path is invalid. Full-text
> search was not installed properly.
> The path to which access is denied is the value of my variable
> strCatalogPath that I assign to my full-text catalog RootPath
> property. (see code sample above)
> How can I fix this error. Please help.
> Any help will be appreciated,
> _dino_
|||Are you utilizing MSDE or SQL Server Express? Full-Text is not installed or
supported on either.
"Dino Buljubasic" wrote:
> Hi,
> I am building a database install aplication that among all other
> stuff, creates and populates full-text catalogs for my database.
> All this is done in VB.net and SQL Server 2003
> My application works fine, here is the come sample:
> oSQLServer = CreateObject("SQLDMO.SQLServer")
> oSQLServer.connect(strServer, strUserID, strPassword)
> ' enable full-text indexing for provided database
> oSQLServer.Databases(strDBName).EnableFullTextCata logs()
> ' create full text catalog and add it to the collection
> Dim strFullTextCatalogName As String
> strFullTextCatalogName = strCatalogPrefix & "_documenttitle"
> oFullTextCatalog = CreateObject("SQLDMO.FullTextCatalog")
> oFullTextCatalog.Name = strFullTextCatalogName 'name
> oFullTextCatalog.RootPath = strCatalogPath 'location
>
> ' create full-text catalog on the server and add it to
> ' the collection of full-text catalogs
> oSQLServer.databases(strDBName).fulltextcatalogs.a dd(oFullTextCatalog)
> However, I get an System.Runtime.InteropServices.COMException
> exception with additional information as:
> Additional information:[Microsoft][ODBC SQL Server Driver][SQL
> Server]Access is denied to 'C:\Documents and
> Settings\username\MyDocuments', or the path is invalid. Full-text
> search was not installed properly.
> The path to which access is denied is the value of my variable
> strCatalogPath that I assign to my full-text catalog RootPath
> property. (see code sample above)
> How can I fix this error. Please help.
> Any help will be appreciated,
> _dino_
>
I am building a database install aplication that among all other
stuff, creates and populates full-text catalogs for my database.
All this is done in VB.net and SQL Server 2003
My application works fine, here is the come sample:
oSQLServer = CreateObject("SQLDMO.SQLServer")
oSQLServer.connect(strServer, strUserID, strPassword)
' enable full-text indexing for provided database
oSQLServer.Databases(strDBName).EnableFullTextCata logs()
' create full text catalog and add it to the collection
Dim strFullTextCatalogName As String
strFullTextCatalogName = strCatalogPrefix & "_documenttitle"
oFullTextCatalog = CreateObject("SQLDMO.FullTextCatalog")
oFullTextCatalog.Name = strFullTextCatalogName 'name
oFullTextCatalog.RootPath = strCatalogPath 'location
' create full-text catalog on the server and add it to
' the collection of full-text catalogs
oSQLServer.databases(strDBName).fulltextcatalogs.a dd(oFullTextCatalog)
However, I get an System.Runtime.InteropServices.COMException
exception with additional information as:
Additional information:[Microsoft][ODBC SQL Server Driver][SQL
Server]Access is denied to 'C:\Documents and
Settings\username\MyDocuments', or the path is invalid. Full-text
search was not installed properly.
The path to which access is denied is the value of my variable
strCatalogPath that I assign to my full-text catalog RootPath
property. (see code sample above)
How can I fix this error. Please help.
Any help will be appreciated,
_dino_
Dino,
Well, the error message is clear "Access is denied to 'C:\Documents and
Settings\username\MyDocuments', or the path is invalid."
Did you try using sp_fulltext_catalog and create a FT Catalog using the same
path? or perhaps specifically reference 'C:\Program Files\Microsoft SQL
Server\Mssql\Ftdata' enclosed in double quotes? Do the folders "username"
or "MyDocuments" exist?
SQL Server BOL title "sp_fulltext_catalog" for the path states
"[@.path =] 'root_directory'
Is the root directory (not the complete physical path) for a create action.
root_directory is nvarchar(100) and has a default value of NULL, which
indicates the use of the default location specified at setup. This is the
Ftdata subdirectory in the Mssql directory; for example, C:\Program
Files\Microsoft SQL Server\Mssql\Ftdata. The specified root directory must
reside on a drive on the same computer, consist of more than just the drive
letter, and cannot be a relative path. Network drives, removable drives,
floppy disks, and UNC paths are not supported. Full-text catalogs must be
created on a local hard drive associated with an instance of Microsoft SQL
ServerT.
@.path is valid only when action is create. For actions other than create
(stop, rebuild, and so on), @.path must be NULL or omitted."
Hope that helps!
John
SQL Full Text Search Blog
http://spaces.msn.com/members/jtkane/
"Dino Buljubasic" <dino@.noplacelikehome.com> wrote in message
news:fs05f1lapksvfr4i0lgot578hubm1te3gj@.4ax.com...
> Hi,
> I am building a database install aplication that among all other
> stuff, creates and populates full-text catalogs for my database.
> All this is done in VB.net and SQL Server 2003
> My application works fine, here is the come sample:
> oSQLServer = CreateObject("SQLDMO.SQLServer")
> oSQLServer.connect(strServer, strUserID, strPassword)
> ' enable full-text indexing for provided database
> oSQLServer.Databases(strDBName).EnableFullTextCata logs()
> ' create full text catalog and add it to the collection
> Dim strFullTextCatalogName As String
> strFullTextCatalogName = strCatalogPrefix & "_documenttitle"
> oFullTextCatalog = CreateObject("SQLDMO.FullTextCatalog")
> oFullTextCatalog.Name = strFullTextCatalogName 'name
> oFullTextCatalog.RootPath = strCatalogPath 'location
>
> ' create full-text catalog on the server and add it to
> ' the collection of full-text catalogs
> oSQLServer.databases(strDBName).fulltextcatalogs.a dd(oFullTextCatalog)
> However, I get an System.Runtime.InteropServices.COMException
> exception with additional information as:
> Additional information:[Microsoft][ODBC SQL Server Driver][SQL
> Server]Access is denied to 'C:\Documents and
> Settings\username\MyDocuments', or the path is invalid. Full-text
> search was not installed properly.
> The path to which access is denied is the value of my variable
> strCatalogPath that I assign to my full-text catalog RootPath
> property. (see code sample above)
> How can I fix this error. Please help.
> Any help will be appreciated,
> _dino_
|||Are you utilizing MSDE or SQL Server Express? Full-Text is not installed or
supported on either.
"Dino Buljubasic" wrote:
> Hi,
> I am building a database install aplication that among all other
> stuff, creates and populates full-text catalogs for my database.
> All this is done in VB.net and SQL Server 2003
> My application works fine, here is the come sample:
> oSQLServer = CreateObject("SQLDMO.SQLServer")
> oSQLServer.connect(strServer, strUserID, strPassword)
> ' enable full-text indexing for provided database
> oSQLServer.Databases(strDBName).EnableFullTextCata logs()
> ' create full text catalog and add it to the collection
> Dim strFullTextCatalogName As String
> strFullTextCatalogName = strCatalogPrefix & "_documenttitle"
> oFullTextCatalog = CreateObject("SQLDMO.FullTextCatalog")
> oFullTextCatalog.Name = strFullTextCatalogName 'name
> oFullTextCatalog.RootPath = strCatalogPath 'location
>
> ' create full-text catalog on the server and add it to
> ' the collection of full-text catalogs
> oSQLServer.databases(strDBName).fulltextcatalogs.a dd(oFullTextCatalog)
> However, I get an System.Runtime.InteropServices.COMException
> exception with additional information as:
> Additional information:[Microsoft][ODBC SQL Server Driver][SQL
> Server]Access is denied to 'C:\Documents and
> Settings\username\MyDocuments', or the path is invalid. Full-text
> search was not installed properly.
> The path to which access is denied is the value of my variable
> strCatalogPath that I assign to my full-text catalog RootPath
> property. (see code sample above)
> How can I fix this error. Please help.
> Any help will be appreciated,
> _dino_
>
Subscribe to:
Posts (Atom)